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

mmc: sdhci: Update firmware interface API

The device_* calls were added a few years ago to abstract
DT/ACPI/fwnode firmware interfaces. Lets convert the two
sdhci caps fields to use the generic calls rather than the OF
specific ones. This has the side effect of allowing
ACPI based devices to quirk themselves when the caps field
is broken.

Signed-off-by: Jeremy Linton <jeremy.linton@arm.com>
Link: https://lore.kernel.org/r/20201120233831.447365-1-jeremy.linton@arm.com
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>

authored by

Jeremy Linton and committed by
Ulf Hansson
c5b1c6dc 2fd8a078

+4 -4
+4 -4
drivers/mmc/host/sdhci.c
··· 3994 3994 if (host->v4_mode) 3995 3995 sdhci_do_enable_v4_mode(host); 3996 3996 3997 - of_property_read_u64(mmc_dev(host->mmc)->of_node, 3998 - "sdhci-caps-mask", &dt_caps_mask); 3999 - of_property_read_u64(mmc_dev(host->mmc)->of_node, 4000 - "sdhci-caps", &dt_caps); 3997 + device_property_read_u64_array(mmc_dev(host->mmc), 3998 + "sdhci-caps-mask", &dt_caps_mask, 1); 3999 + device_property_read_u64_array(mmc_dev(host->mmc), 4000 + "sdhci-caps", &dt_caps, 1); 4001 4001 4002 4002 v = ver ? *ver : sdhci_readw(host, SDHCI_HOST_VERSION); 4003 4003 host->version = (v & SDHCI_SPEC_VER_MASK) >> SDHCI_SPEC_VER_SHIFT;