From 8d332bd43105a6f8b48cac8c06338ea453426709 Mon Sep 17 00:00:00 2001 From: Mark Kettenis Date: Thu, 9 Jun 2022 14:43:29 +0000 Subject: Handle "broken-cd" as "non-removable" like we do in dwmmc(4). Needed on the StarFive VisionFive board. ok patrick@ --- sys/dev/fdt/dwmmc.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/dev/fdt/dwmmc.c b/sys/dev/fdt/dwmmc.c index 0760e22f67d..9c5860fdef8 100644 --- a/sys/dev/fdt/dwmmc.c +++ b/sys/dev/fdt/dwmmc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dwmmc.c,v 1.26 2022/01/09 05:42:37 jsg Exp $ */ +/* $OpenBSD: dwmmc.c,v 1.27 2022/06/09 14:43:28 kettenis Exp $ */ /* * Copyright (c) 2017 Mark Kettenis * @@ -602,7 +602,9 @@ dwmmc_card_detect(sdmmc_chipset_handle_t sch) struct dwmmc_softc *sc = sch; uint32_t cdetect; - if (OF_getproplen(sc->sc_node, "non-removable") == 0) + /* XXX treat broken-cd as non-removable */ + if (OF_getproplen(sc->sc_node, "non-removable") == 0 || + OF_getproplen(sc->sc_node, "broken-cd") == 0) return 1; if (sc->sc_gpio[0]) { -- cgit v1.2.3