Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mmc: core: Set default power mode in mmc_alloc_host()

Set the default power mode, MMC_POWER_UNDEFINED, in mmc_alloc_host() rather
than in mmc_start_host(). This enables host drivers to make use of the
initial state during ->probe().

Signed-off-by: Veerabhadrarao Badiganti <vbadigan@codeaurora.org> Link:
https://lore.kernel.org/r/1592919288-1020-3-git-send-email-vbadigan@codeaurora.org
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>

authored by

Veerabhadrarao Badiganti and committed by
Ulf Hansson
ed54ef98 0fcb031e

+1 -1
-1
drivers/mmc/core/core.c
··· 2303 2303 { 2304 2304 host->f_init = max(min(freqs[0], host->f_max), host->f_min); 2305 2305 host->rescan_disable = 0; 2306 - host->ios.power_mode = MMC_POWER_UNDEFINED; 2307 2306 2308 2307 if (!(host->caps2 & MMC_CAP2_NO_PRESCAN_POWERUP)) { 2309 2308 mmc_claim_host(host);
+1
drivers/mmc/core/host.c
··· 434 434 435 435 host->fixed_drv_type = -EINVAL; 436 436 host->ios.power_delay_ms = 10; 437 + host->ios.power_mode = MMC_POWER_UNDEFINED; 437 438 438 439 return host; 439 440 }