android_kernel_sony_sdm845/drivers/mmc/core
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Ulf Hansson c7ed5c02e4 mmc: core: Fix init of SD cards reporting an invalid VDD range
commit 72741084d903e65e121c27bd29494d941729d4a1 upstream.

The OCR register defines the supported range of VDD voltages for SD cards.
However, it has turned out that some SD cards reports an invalid voltage
range, for example having bit7 set.

When a host supports MMC_CAP2_FULL_PWR_CYCLE and some of the voltages from
the invalid VDD range, this triggers the core to run a power cycle of the
card to try to initialize it at the lowest common supported voltage.
Obviously this fails, since the card can't support it.

Let's fix this problem, by clearing invalid bits from the read OCR register
for SD cards, before proceeding with the VDD voltage negotiation.

Cc: stable@vger.kernel.org
Reported-by: Philip Langdale <philipl@overt.org>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Reviewed-by: Philip Langdale <philipl@overt.org>
Tested-by: Philip Langdale <philipl@overt.org>
Tested-by: Manuel Presnitz <mail@mpy.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-09-06 10:19:51 +02:00
..
bus.c mmc: core: Do not leave the block driver in a suspended state 2017-12-05 11:24:33 +01:00
bus.h
core.c mmc: avoid removing non-removable hosts during suspend 2018-03-24 11:00:24 +01:00
core.h
debugfs.c
host.c mmc: core: Use device_property_read instead of of_property_read 2017-08-11 08:49:31 -07:00
host.h
Kconfig
Makefile
mmc.c mmc: core: Use a minimum 1600ms timeout when enabling CACHE ctrl 2018-12-29 13:40:15 +01:00
mmc_ops.c
mmc_ops.h
pwrseq.c
pwrseq.h
pwrseq_emmc.c mmc: core: make pwrseq_emmc (partially) support sleepy GPIO controllers 2019-05-31 06:48:25 -07:00
pwrseq_simple.c mmc: pwrseq: Use kmalloc_array instead of stack VLA 2018-08-03 07:55:24 +02:00
quirks.c
sd.c mmc: core: Fix init of SD cards reporting an invalid VDD range 2019-09-06 10:19:51 +02:00
sd.h
sd_ops.c
sd_ops.h
sdio.c
sdio_bus.c mmc: sdio: fix alignment issue in struct sdio_func 2017-10-08 10:26:08 +02:00
sdio_bus.h
sdio_cis.c
sdio_cis.h
sdio_io.c
sdio_irq.c
sdio_ops.c
sdio_ops.h
slot-gpio.c
slot-gpio.h