WSL2-Linux-Kernel/drivers/mmc/host
Paul Walmsley 75b53aee2f mmc: omap: fix broken PIO mode
After commit 26b88520b8 ("mmc:
omap_hsmmc: remove private DMA API implementation"), the Nokia N800
here stopped booting:

[    2.086181] Waiting for root device /dev/mmcblk0p1...
[    2.324066] Unhandled fault: imprecise external abort (0x406) at 0x00000000
[    2.331451] Internal error: : 406 [#1] ARM
[    2.335784] Modules linked in:
[    2.339050] CPU: 0    Not tainted  (3.6.0-rc3 #60)
[    2.344146] PC is at default_idle+0x28/0x30
[    2.348602] LR is at trace_hardirqs_on_caller+0x15c/0x1b0

...

This turned out to be due to memory corruption caused by long-broken
PIO code in drivers/mmc/host/omap.c.  (Previously, this driver had
been using DMA; but the above commit caused the MMC driver to fall
back to PIO mode with an unmodified Kconfig.)

The PIO code, added with the rest of the driver in commit
730c9b7e66 ("[MMC] Add OMAP MMC host
driver"), confused bytes with 16-bit words.  This bug caused memory
located after the PIO transfer buffer to be corrupted with transfers
larger than 32 bytes.  The driver also did not increment the buffer
pointer after the transfer occurred.  This bug resulted in data
corruption during any transfer larger than 64 bytes.

Signed-off-by: Paul Walmsley <paul@pwsan.com>
Reviewed-by: Felipe Balbi <balbi@ti.com>
Tested-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
2012-09-04 13:58:11 -04:00
..
Kconfig mmc: at91-mci: this driver is now deprecated 2012-05-17 14:33:48 -04:00
Makefile mmc: remove imxmmc driver 2012-04-22 11:17:25 -04:00
at91_mci.c ARM: at91: code removal of CAP9 SoC 2012-02-03 13:33:05 +01:00
at91_mci.h mmc: at91_mci: move register header from include/ to drivers/ 2011-07-21 10:35:08 -04:00
atmel-mci-regs.h mmc: atmel-mci: fix burst/chunk size modification 2012-06-06 08:52:12 -04:00
atmel-mci.c mmc: atmel-mci: not busy flag has also to be used for read operations 2012-09-04 13:58:07 -04:00
au1xmmc.c MIPS: Alchemy: Au1300 SoC support 2011-12-07 22:02:05 +00:00
bfin_sdh.c mmc: bfin_sdh: fix dma_desc_array build error 2012-09-04 13:58:04 -04:00
cb710-mmc.c mmc: convert drivers/mmc/host/* to use module_platform_driver() 2012-01-11 23:58:42 -05:00
cb710-mmc.h
davinci_mmc.c mmc: davinci_mmc: set MODULE_ALIAS to allow autoloading 2012-04-22 11:16:58 -04:00
dw_mmc-pci.c mmc: Support of PCI mode in the dw_mmc driver 2012-03-25 19:33:44 -04:00
dw_mmc-pltfm.c mmc: Support of PCI mode in the dw_mmc driver 2012-03-25 19:33:44 -04:00
dw_mmc.c mmc: dw_mmc: Disable low power mode if SDIO interrupts are used 2012-09-04 13:58:10 -04:00
dw_mmc.h mmc: Support of PCI mode in the dw_mmc driver 2012-03-25 19:33:44 -04:00
jz4740_mmc.c mmc: convert drivers/mmc/host/* to use module_platform_driver() 2012-01-11 23:58:42 -05:00
mmc_spi.c mmc: Remove redundant spi driver bus initialization 2012-01-11 23:58:42 -05:00
mmci.c ARM: 7427/1: mmc: mmci: Defer probe() in case of yet uninitialized GPIOs 2012-06-17 22:24:36 +01:00
mmci.h ARM: 7280/1: mmc: mmci: Cache MMCICLOCK and MMCIPOWER register 2012-02-02 17:02:15 +00:00
msm_sdcc.c mmc: remove the second argument of k[un]map_atomic() 2012-01-11 23:58:42 -05:00
msm_sdcc.h mmc: msm_sdcc: Use MCI_INT_MASK0 for PIO interrupts 2011-10-26 15:43:37 -04:00
mvsdio.c ARM: Orion: fix driver probe error handling with respect to clk 2012-07-25 17:06:21 +02:00
mvsdio.h
mxcmmc.c mmc mxcmmc: do not depend on grouped clocks 2012-04-25 17:03:38 +02:00
mxs-mmc.c mmc: mxs-mmc: fix deadlock caused by recursion loop 2012-09-04 13:58:06 -04:00
of_mmc_spi.c mmc: of_mmc_spi: fix little endian support 2012-02-13 20:38:58 -05:00
omap.c mmc: omap: fix broken PIO mode 2012-09-04 13:58:11 -04:00
omap_hsmmc.c Merge branch 'dmaengine' of git://git.linaro.org/people/rmk/linux-arm 2012-08-01 16:41:07 -07:00
pxamci.c mmc: convert drivers/mmc/host/* to use module_platform_driver() 2012-01-11 23:58:42 -05:00
pxamci.h
s3cmci.c mmc: s3cmci: Convert s3cmci driver to gpiolib API 2012-07-22 15:25:44 -04:00
s3cmci.h
sdhci-cns3xxx.c mmc: convert drivers/mmc/host/* to use module_platform_driver() 2012-01-11 23:58:42 -05:00
sdhci-dove.c mmc: sdhci-dove: Prepare for common clock framework 2012-07-22 16:42:48 -04:00
sdhci-esdhc-imx.c mmc: esdhc: Fix DMA_MASK to not break mx25 DMA access 2012-07-22 16:42:30 -04:00
sdhci-esdhc.h mmc: sdhci-esdhc: break out early if clock is 0 2012-09-04 13:58:06 -04:00
sdhci-of-esdhc.c mmc: esdhc: Workaround for data crc error on p1010rdb 2012-03-25 19:33:45 -04:00
sdhci-of-hlwd.c mmc: convert drivers/mmc/host/* to use module_platform_driver() 2012-01-11 23:58:42 -05:00
sdhci-pci-data.c mmc: sdhci-pci: add platform data 2012-01-11 23:58:47 -05:00
sdhci-pci.c mmc: sdhci-pci: CaFe has broken card detection 2012-07-22 15:25:46 -04:00
sdhci-pltfm.c mmc: dt: Consolidate DT bindings 2012-05-15 13:29:42 +02:00
sdhci-pltfm.h mmc: sdhci: remove "state" argument from sdhci_suspend_host 2011-12-19 15:50:11 -08:00
sdhci-pxav2.c mmc: sdhci-pxa: Add device tree support 2012-07-21 00:01:47 -04:00
sdhci-pxav3.c mmc: sdhci-pxa: Add device tree support 2012-07-21 00:01:47 -04:00
sdhci-s3c.c mmc: sdhci-s3c: pass IRQF ONESHOT to request threaded irq 2012-06-06 09:53:22 -04:00
sdhci-spear.c Viresh has moved 2012-06-20 14:39:36 -07:00
sdhci-tegra.c Merge branch 'for-3.6/common-clk' of git://git.kernel.org/pub/scm/linux/kernel/git/swarren/linux-tegra into next/clk 2012-07-06 22:21:23 +02:00
sdhci.c mmc: sd: Fix sd current limit setting 2012-07-22 15:25:52 -04:00
sdhci.h mmc: sdhci: if MAX_CURRENT is 0, try getting current from regulator 2012-07-21 00:02:22 -04:00
sdricoh_cs.c mmc: Add module.h to drivers/mmc users assuming implicit presence. 2011-10-26 16:32:19 -04:00
sh_mmcif.c Merge branch 'next' of git://git.infradead.org/users/vkoul/slave-dma 2012-07-24 17:12:54 -07:00
sh_mobile_sdhi.c Merge branch 'next' of git://git.infradead.org/users/vkoul/slave-dma 2012-07-24 17:12:54 -07:00
tifm_sd.c Autogenerated GPG tag for Rusty D1ADB8F1: 15EE 8D6C AB0E 7F0C F999 BFCB D920 0E6C D1AD B8F1 2012-01-14 12:32:16 -08:00
tmio_mmc.c mmc: convert drivers/mmc/host/* to use module_platform_driver() 2012-01-11 23:58:42 -05:00
tmio_mmc.h mmc: tmio_mmc: remove unused sdio_irq_enabled flag 2012-03-27 12:20:17 -04:00
tmio_mmc_dma.c Merge branch 'next' of git://git.infradead.org/users/vkoul/slave-dma 2012-03-29 15:34:57 -07:00
tmio_mmc_pio.c mmc: tmio: use generic GPIO CD and WP handlers 2012-07-21 00:02:20 -04:00
ushc.c USB: convert some miscellanies drivers to use module_usb_driver() 2011-11-18 09:52:10 -08:00
via-sdmmc.c mmc: replace printk with appropriate display macro 2011-10-26 16:32:22 -04:00
vub300.c module_param: make bool parameters really bool (drivers & misc) 2012-01-13 09:32:20 +10:30
wbsd.c mmc: replace printk with appropriate display macro 2011-10-26 16:32:22 -04:00
wbsd.h