linux/drivers/mmc/core
Ulf Hansson c784f92769 mmc: core: Read the SD function extension registers for power management
In the SD spec v4.0 the CMD48/49 and CMD58/59 were introduced as optional
commands. In the SD spec v4.1 the SD function extension registers were
introduced, which requires support for CMD48/49/58/59 to be read/written
from/to.

Moreover, a specific function extension register were added to let the card
announce support for optional features in regards to power management. The
features that were added are "Power Off Notification", "Power Down Mode"
and "Power Sustenance".

As a first step to support this, let's read and parse the register for
power management during the SD card initialization and store the
information about the supported features in the struct mmc_card. In this
way, we prepare for subsequent changes to implement the complete support
for the new features.

Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Reviewed-by: Shawn Lin <shawn.lin@rock-chips.com>
Acked-by: Avri Altman <avri.altman@wdc.com>
Link: https://lore.kernel.org/r/20210504161222.101536-10-ulf.hansson@linaro.org
2021-06-14 13:57:36 +02:00
..
block.c mmc: block: Issue a cache flush only when it's enabled 2021-04-26 11:37:23 +02:00
block.h mmc: block: Remove code no longer needed after the switch to blk-mq 2017-12-11 13:02:22 +01:00
bus.c mmc: cqhci: Fix random crash when remove mmc module/card 2021-03-09 10:00:52 +01:00
bus.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
card.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 194 2019-05-30 11:29:22 -07:00
core.c mmc: core: Extend re-use of __mmc_poll_for_busy() 2021-06-14 13:57:35 +02:00
core.h mmc: block: Issue a cache flush only when it's enabled 2021-04-26 11:37:23 +02:00
crypto.c mmc: core: Add basic support for inline encryption 2021-02-01 12:02:33 +01:00
crypto.h mmc: core: Add basic support for inline encryption 2021-02-01 12:02:33 +01:00
debugfs.c mmc: core: Use DEFINE_DEBUGFS_ATTRIBUTE instead of DEFINE_SIMPLE_ATTRIBUTE 2020-05-28 11:21:01 +02:00
host.c mmc: core: Convert mmc_of_parse_voltage() to use device property API 2021-04-23 09:29:49 +02:00
host.h mmc: core: Initial support for SD express card/host 2020-11-16 11:59:28 +01:00
Kconfig mmc: core: Add basic support for inline encryption 2021-02-01 12:02:33 +01:00
Makefile mmc: core: Add basic support for inline encryption 2021-02-01 12:02:33 +01:00
mmc_ops.c mmc: core: Prepare mmc_send_cxd_data() to be re-used for additional cmds 2021-06-14 13:57:36 +02:00
mmc_ops.h mmc: core: Prepare mmc_send_cxd_data() to be re-used for additional cmds 2021-06-14 13:57:36 +02:00
mmc_test.c mmc: mmc_test: use erase_arg for mmc_erase command 2021-02-12 12:07:03 +01:00
mmc.c mmc: core: Enable eMMC sleep commands to use HW busy polling 2021-06-14 13:57:36 +02:00
pwrseq_emmc.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 194 2019-05-30 11:29:22 -07:00
pwrseq_sd8787.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 157 2019-05-30 11:26:37 -07:00
pwrseq_simple.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 194 2019-05-30 11:29:22 -07:00
pwrseq.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 194 2019-05-30 11:29:22 -07:00
pwrseq.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 194 2019-05-30 11:29:22 -07:00
queue.c mmc: core: Remove mq->use_cqe from the struct mmc_queue 2021-03-30 11:42:02 +02:00
queue.h mmc: core: Remove mq->use_cqe from the struct mmc_queue 2021-03-30 11:42:02 +02:00
quirks.h mmc: core: Mark fixups as __maybe_unused 2020-07-13 12:18:25 +02:00
regulator.c mmc: core: Add missing documetation for 'mmc' and 'ios' 2020-07-13 12:18:25 +02:00
sd_ops.c mmc: core: Drop open coding in mmc_sd_switch() 2021-06-14 13:57:36 +02:00
sd_ops.h mmc: core: Initial support for SD express card/host 2020-11-16 11:59:28 +01:00
sd.c mmc: core: Read the SD function extension registers for power management 2021-06-14 13:57:36 +02:00
sd.h mmc: core: remove unused host parameter of mmc_sd_get_csd() 2021-02-01 11:54:48 +01:00
sdio_bus.c mmc: sdio: Export SDIO revision and info strings to userspace 2020-09-07 09:11:29 +02:00
sdio_bus.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
sdio_cis.c mmc: core: Limit retries when analyse of SDIO tuples fails 2021-02-01 11:13:06 +01:00
sdio_cis.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
sdio_io.c mmc: core: Provide description for sdio_set_host_pm_flags()'s 'flag' arg 2020-07-13 12:18:25 +02:00
sdio_irq.c sched,mmc: Convert to sched_set_fifo*() 2020-06-15 14:10:22 +02:00
sdio_ops.c mmc: sdio: Use mmc_pre_req() / mmc_post_req() 2020-09-07 08:57:44 +02:00
sdio_ops.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
sdio_uart.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 152 2019-05-30 11:26:32 -07:00
sdio.c mmc: core: Fix hanging on I/O during system suspend for removable cards 2021-03-30 11:42:03 +02:00
slot-gpio.c mmc: core: Remove mmc_gpiod_request_*(invert_gpio) 2019-12-18 13:37:07 +01:00
slot-gpio.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 194 2019-05-30 11:29:22 -07:00