Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/arm/broadcom RPi4 UEFI firmware 1.1 reports the wro...
details: https://anonhg.NetBSD.org/src/rev/2adcb758ca23
branches: trunk
changeset: 745103:2adcb758ca23
user: jmcneill <jmcneill%NetBSD.org@localhost>
date: Sat Feb 22 22:09:07 2020 +0000
description:
RPi4 UEFI firmware 1.1 reports the wrong IRQ for the VC mailbox. Use
polling mode for now until this is sorted out.
diffstat:
sys/arch/arm/broadcom/bcm2835_mbox.c | 11 ++++++-----
sys/arch/arm/broadcom/bcm2835_mbox_acpi.c | 6 ++++--
2 files changed, 10 insertions(+), 7 deletions(-)
diffs (72 lines):
diff -r 46d06594e07c -r 2adcb758ca23 sys/arch/arm/broadcom/bcm2835_mbox.c
--- a/sys/arch/arm/broadcom/bcm2835_mbox.c Sat Feb 22 22:02:46 2020 +0000
+++ b/sys/arch/arm/broadcom/bcm2835_mbox.c Sat Feb 22 22:09:07 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm2835_mbox.c,v 1.14 2019/12/30 18:43:38 jmcneill Exp $ */
+/* $NetBSD: bcm2835_mbox.c,v 1.15 2020/02/22 22:09:07 jmcneill Exp $ */
/*-
* Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_mbox.c,v 1.14 2019/12/30 18:43:38 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_mbox.c,v 1.15 2020/02/22 22:09:07 jmcneill Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -97,8 +97,9 @@
cv_init(&sc->sc_chan[i], "bcmmbox");
/* enable mbox interrupt */
- bus_space_write_4(sc->sc_iot, sc->sc_ioh, BCM2835_MBOX_CFG,
- BCM2835_MBOX_CFG_DATAIRQEN);
+ if (sc->sc_intrh != NULL)
+ bus_space_write_4(sc->sc_iot, sc->sc_ioh, BCM2835_MBOX_CFG,
+ BCM2835_MBOX_CFG_DATAIRQEN);
baa.baa_dmat = sc->sc_dmat;
sc->sc_platdev = config_found_ia(sc->sc_dev, "bcmmboxbus", &baa, NULL);
@@ -130,7 +131,7 @@
mutex_enter(&sc->sc_intr_lock);
while (BCM2835_MBOX_CHAN(sc->sc_mbox[chan]) == 0) {
- if (cold)
+ if (cold || sc->sc_intrh == NULL)
bcmmbox_intr1(sc, 0);
else
cv_wait(&sc->sc_chan[chan], &sc->sc_intr_lock);
diff -r 46d06594e07c -r 2adcb758ca23 sys/arch/arm/broadcom/bcm2835_mbox_acpi.c
--- a/sys/arch/arm/broadcom/bcm2835_mbox_acpi.c Sat Feb 22 22:02:46 2020 +0000
+++ b/sys/arch/arm/broadcom/bcm2835_mbox_acpi.c Sat Feb 22 22:09:07 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm2835_mbox_acpi.c,v 1.1 2019/12/30 18:43:38 jmcneill Exp $ */
+/* $NetBSD: bcm2835_mbox_acpi.c,v 1.2 2020/02/22 22:09:07 jmcneill Exp $ */
/*-
* Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: bcm2835_mbox_acpi.c,v 1.1 2019/12/30 18:43:38 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: bcm2835_mbox_acpi.c,v 1.2 2020/02/22 22:09:07 jmcneill Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -103,12 +103,14 @@
return;
}
+#if notyet
sc->sc_intrh = acpi_intr_establish(self, (uint64_t)aa->aa_node->ad_handle,
IPL_VM, false, bcmmbox_intr, sc, device_xname(self));
if (sc->sc_intrh == NULL) {
aprint_error_dev(self, "failed to establish interrupt\n");
return;
}
+#endif
bcmmbox_attach(sc);
}
Home |
Main Index |
Thread Index |
Old Index