summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2011-08-01 11:21:47 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2011-08-01 11:21:47 -0700
commit8cb4c7c14e758ea1e1a2209d45a7444a13752f62 (patch)
tree37118d465b0e43cc38a6777232d3432e45e92c83
parent00e0a3941a3a807de3c7ef5235ae5a9d45bc2fb2 (diff)
downloadstable-queue-8cb4c7c14e758ea1e1a2209d45a7444a13752f62.tar.gz
3.0 patches
-rw-r--r--queue-3.0/mmc-added-quirks-for-ricoh-1180-e823-lower-base-clock.patch62
-rw-r--r--queue-3.0/mmc-sdhci-esdhc-imx-sdhci_card_present-does-not-get.patch34
-rw-r--r--queue-3.0/series2
3 files changed, 98 insertions, 0 deletions
diff --git a/queue-3.0/mmc-added-quirks-for-ricoh-1180-e823-lower-base-clock.patch b/queue-3.0/mmc-added-quirks-for-ricoh-1180-e823-lower-base-clock.patch
new file mode 100644
index 0000000000..ad70986b04
--- /dev/null
+++ b/queue-3.0/mmc-added-quirks-for-ricoh-1180-e823-lower-base-clock.patch
@@ -0,0 +1,62 @@
+From 15bed0f2fa8e1d7db201692532c210a7823d2d21 Mon Sep 17 00:00:00 2001
+From: Manoj Iyer <manoj.iyer@canonical.com>
+Date: Mon, 11 Jul 2011 16:28:35 -0500
+Subject: mmc: Added quirks for Ricoh 1180:e823 lower base clock
+ frequency
+
+From: Manoj Iyer <manoj.iyer@canonical.com>
+
+commit 15bed0f2fa8e1d7db201692532c210a7823d2d21 upstream.
+
+Ricoh 1180:e823 does not recognize certain types of SD/MMC cards,
+as reported at http://launchpad.net/bugs/773524. Lowering the SD
+base clock frequency from 200Mhz to 50Mhz fixes this issue. This
+solution was suggest by Koji Matsumuro, Ricoh Company, Ltd.
+
+This change has no negative performance effect on standard SD
+cards, though it's quite possible that there will be one on
+UHS-1 cards.
+
+Signed-off-by: Manoj Iyer <manoj.iyer@canonical.com>
+Tested-by: Daniel Manrique <daniel.manrique@canonical.com>
+Cc: Koji Matsumuro <matsumur@nts.ricoh.co.jp>
+Acked-by: Jesse Barnes <jbarnes@virtuousgeek.org>
+Signed-off-by: Chris Ball <cjb@laptop.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/pci/quirks.c | 23 +++++++++++++++++++++++
+ 1 file changed, 23 insertions(+)
+
+--- a/drivers/pci/quirks.c
++++ b/drivers/pci/quirks.c
+@@ -2758,6 +2758,29 @@ static void ricoh_mmc_fixup_r5c832(struc
+
+ dev_notice(&dev->dev, "proprietary Ricoh MMC controller disabled (via firewire function)\n");
+ dev_notice(&dev->dev, "MMC cards are now supported by standard SDHCI controller\n");
++
++ /*
++ * RICOH 0xe823 SD/MMC card reader fails to recognize
++ * certain types of SD/MMC cards. Lowering the SD base
++ * clock frequency from 200Mhz to 50Mhz fixes this issue.
++ *
++ * 0x150 - SD2.0 mode enable for changing base clock
++ * frequency to 50Mhz
++ * 0xe1 - Base clock frequency
++ * 0x32 - 50Mhz new clock frequency
++ * 0xf9 - Key register for 0x150
++ * 0xfc - key register for 0xe1
++ */
++ if (dev->device == PCI_DEVICE_ID_RICOH_R5CE823) {
++ pci_write_config_byte(dev, 0xf9, 0xfc);
++ pci_write_config_byte(dev, 0x150, 0x10);
++ pci_write_config_byte(dev, 0xf9, 0x00);
++ pci_write_config_byte(dev, 0xfc, 0x01);
++ pci_write_config_byte(dev, 0xe1, 0x32);
++ pci_write_config_byte(dev, 0xfc, 0x00);
++
++ dev_notice(&dev->dev, "MMC controller base frequency changed to 50Mhz.\n");
++ }
+ }
+ DECLARE_PCI_FIXUP_EARLY(PCI_VENDOR_ID_RICOH, PCI_DEVICE_ID_RICOH_R5C832, ricoh_mmc_fixup_r5c832);
+ DECLARE_PCI_FIXUP_RESUME_EARLY(PCI_VENDOR_ID_RICOH, PCI_DEVICE_ID_RICOH_R5C832, ricoh_mmc_fixup_r5c832);
diff --git a/queue-3.0/mmc-sdhci-esdhc-imx-sdhci_card_present-does-not-get.patch b/queue-3.0/mmc-sdhci-esdhc-imx-sdhci_card_present-does-not-get.patch
new file mode 100644
index 0000000000..986721b7c0
--- /dev/null
+++ b/queue-3.0/mmc-sdhci-esdhc-imx-sdhci_card_present-does-not-get.patch
@@ -0,0 +1,34 @@
+From 803862a6f7de4939e0a557214e5e4b37e36f87ff Mon Sep 17 00:00:00 2001
+From: Shawn Guo <shawn.guo@linaro.org>
+Date: Tue, 21 Jun 2011 22:41:49 +0800
+Subject: mmc: sdhci-esdhc-imx: SDHCI_CARD_PRESENT does not get
+ cleared
+
+From: Shawn Guo <shawn.guo@linaro.org>
+
+commit 803862a6f7de4939e0a557214e5e4b37e36f87ff upstream.
+
+The function esdhc_readl_le intends to clear bit SDHCI_CARD_PRESENT,
+when the card detect gpio tells there is no card. But it does not
+clear the bit actually. The patch gives a fix on that.
+
+Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
+Acked-by: Wolfram Sang <w.sang@pengutronix.de>
+Signed-off-by: Chris Ball <cjb@laptop.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/mmc/host/sdhci-esdhc-imx.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/drivers/mmc/host/sdhci-esdhc-imx.c
++++ b/drivers/mmc/host/sdhci-esdhc-imx.c
+@@ -74,7 +74,7 @@ static u32 esdhc_readl_le(struct sdhci_h
+ if (boarddata && gpio_is_valid(boarddata->cd_gpio)
+ && gpio_get_value(boarddata->cd_gpio))
+ /* no card, if a valid gpio says so... */
+- val &= SDHCI_CARD_PRESENT;
++ val &= ~SDHCI_CARD_PRESENT;
+ else
+ /* ... in all other cases assume card is present */
+ val |= SDHCI_CARD_PRESENT;
diff --git a/queue-3.0/series b/queue-3.0/series
index 844f7d94dd..8e54453a0d 100644
--- a/queue-3.0/series
+++ b/queue-3.0/series
@@ -1 +1,3 @@
usb-serial-add-ids-for-winchiphead-usb-rs232-adapter.patch
+mmc-added-quirks-for-ricoh-1180-e823-lower-base-clock.patch
+mmc-sdhci-esdhc-imx-sdhci_card_present-does-not-get.patch