git: 4c1ecf5502e1 - main - Consider the broken card detect flag that comes from 'broken-cd; ' dts property.
Ruslan Bukin
br at FreeBSD.org
Tue Apr 27 11:21:18 UTC 2021
The branch main has been updated by br:
URL: https://cgit.FreeBSD.org/src/commit/?id=4c1ecf5502e1b4b20553a2f996b73794cc7e6454
commit 4c1ecf5502e1b4b20553a2f996b73794cc7e6454
Author: Ruslan Bukin <br at FreeBSD.org>
AuthorDate: 2021-04-27 11:19:05 +0000
Commit: Ruslan Bukin <br at FreeBSD.org>
CommitDate: 2021-04-27 11:19:05 +0000
Consider the broken card detect flag that comes from 'broken-cd;'
dts property.
This fixes operation on Intel Stratix 10 devices.
Tested on Terasic DE10-Pro.
Reviewed by: manu
Sponsored by: UKRI
Differential revision: https://reviews.freebsd.org/D29999
---
sys/dev/mmc/host/dwmmc.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/sys/dev/mmc/host/dwmmc.c b/sys/dev/mmc/host/dwmmc.c
index b31bb0d4e68b..bf494027551a 100644
--- a/sys/dev/mmc/host/dwmmc.c
+++ b/sys/dev/mmc/host/dwmmc.c
@@ -480,7 +480,8 @@ dwmmc_card_task(void *arg, int pending __unused)
#else
DWMMC_LOCK(sc);
- if (READ4(sc, SDMMC_CDETECT) == 0) {
+ if (READ4(sc, SDMMC_CDETECT) == 0 ||
+ (sc->mmc_helper.props & MMC_PROP_BROKEN_CD)) {
if (sc->child == NULL) {
if (bootverbose)
device_printf(sc->dev, "Card inserted\n");
More information about the dev-commits-src-main
mailing list