The branch main has been updated by jhb:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=03d49ffc78a6a9dc764acea44f8c214b8bf4a05b

commit 03d49ffc78a6a9dc764acea44f8c214b8bf4a05b
Author:     John Baldwin <[email protected]>
AuthorDate: 2022-04-13 23:08:20 +0000
Commit:     John Baldwin <[email protected]>
CommitDate: 2022-04-13 23:08:20 +0000

    sdhci_card_task: d is only used in the non-MMCCAM case.
---
 sys/dev/sdhci/sdhci.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/sys/dev/sdhci/sdhci.c b/sys/dev/sdhci/sdhci.c
index 0438e6afc8d9..d8532b132ac5 100644
--- a/sys/dev/sdhci/sdhci.c
+++ b/sys/dev/sdhci/sdhci.c
@@ -683,7 +683,9 @@ static void
 sdhci_card_task(void *arg, int pending __unused)
 {
        struct sdhci_slot *slot = arg;
+#ifndef MMCCAM
        device_t d;
+#endif
 
        SDHCI_LOCK(slot);
        if (SDHCI_GET_CARD_PRESENT(slot->bus, slot)) {
@@ -714,11 +716,11 @@ sdhci_card_task(void *arg, int pending __unused)
                if (slot->card_present == 1) {
 #else
                if (slot->dev != NULL) {
+                       d = slot->dev;
 #endif
                        /* If no card present - detach mmc bus. */
                        if (bootverbose || sdhci_debug)
                                slot_printf(slot, "Card removed\n");
-                       d = slot->dev;
                        slot->dev = NULL;
 #ifdef MMCCAM
                        slot->card_present = 0;

Reply via email to