diff options
author | Marcin Wojtas <mw@FreeBSD.org> | 2021-05-04 22:57:50 +0000 |
---|---|---|
committer | Marcin Wojtas <mw@FreeBSD.org> | 2022-03-07 15:59:50 +0000 |
commit | 55e7f40ce3a54e1119ba3c2ef72701cc785ee69b (patch) | |
tree | dcb74d4ff4f12139e6c109cde4d70e1306f32015 | |
parent | 4a80132dcd48d6dc8802ead5b38a52ab24f72785 (diff) | |
download | src-55e7f40ce3a54e1119ba3c2ef72701cc785ee69b.tar.gz src-55e7f40ce3a54e1119ba3c2ef72701cc785ee69b.zip |
sdhci: allow setting MMC capabilities before sdhci_init_slot
With this change the host controller drivers can set the MMC capabilities
(e.g. using mmc_fdt_parse() helper) before calling sdhci_init_slot().
This way the configuration dump (eg. in bootverbose) can include the
possible additional information.
Reviewed by: manu
Obtained from: Semihalf
Sponsored by: Marvell
Differential Revision: https://reviews.freebsd.org/D30561
MFC after: 2 weeks
(cherry picked from commit 5652be30a322f2543bc1e3bcc135abc56b3eb268)
-rw-r--r-- | sys/dev/sdhci/sdhci.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/dev/sdhci/sdhci.c b/sys/dev/sdhci/sdhci.c index 33a34b28b44d..39053229abb1 100644 --- a/sys/dev/sdhci/sdhci.c +++ b/sys/dev/sdhci/sdhci.c @@ -890,7 +890,8 @@ sdhci_init_slot(device_t dev, struct sdhci_slot *slot, int num) "support voltages.\n"); } - host_caps = MMC_CAP_4_BIT_DATA; + host_caps = slot->host.caps; + host_caps |= MMC_CAP_4_BIT_DATA; if (caps & SDHCI_CAN_DO_8BITBUS) host_caps |= MMC_CAP_8_BIT_DATA; if (caps & SDHCI_CAN_DO_HISPD) |