NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
re: port-macppc/54331: macppc MP kernels fail to boot successfully in -current (8.99.49)
The following reply was made to PR port-macppc/54331; it has been noted by GNATS.
From: matthew green <mrg%eterna.com.au@localhost>
To: gnats-bugs%netbsd.org@localhost
Cc: port-macppc-maintainer%netbsd.org@localhost, gnats-admin%netbsd.org@localhost,
netbsd-bugs%netbsd.org@localhost, david%gutteridge.ca@localhost
Subject: re: port-macppc/54331: macppc MP kernels fail to boot successfully in -current (8.99.49)
Date: Thu, 01 Aug 2019 17:26:53 +1000
> panic: kernel diagnostic assertion "mutex_owned(&sc->sc_lock)" failed: =
file "/home/disciple/netbsd-8/src/sys/dev/usb/ohci.c", line 590
i think i see the problem here.
> Stopped in pid 0.1 (system) at netbsd:vpanic+0x140: addi r4, =
r0, 0x0
> 0x00c56a90: at kern_assert+0x68
> 0x00c56ad0: at ohci_reset_std_chain+0x518
> 0x00c56b30: at ohci_device_intr_start+0xd8
ohci_device_intr_start() only takes the lock when not polling, so
this assert needs to be adjusted for that.
can you try this patch? it probably won't fix the original hang,
but it should fix this issue. it's against netbsd-8 though i
am fairly sure that the code is the same in -current.
.mrg.
Index: ohci.c
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
RCS file: /cvsroot/src/sys/dev/usb/ohci.c,v
retrieving revision 1.273.6.4
diff -p -u -r1.273.6.4 ohci.c
--- ohci.c 27 Sep 2018 14:52:26 -0000 1.273.6.4
+++ ohci.c 1 Aug 2019 07:25:46 -0000
@@ -587,7 +587,7 @@ ohci_reset_std_chain(ohci_softc_t *sc, s
OHCIHIST_FUNC(); OHCIHIST_CALLED();
DPRINTF("start len=3D%jd", alen, 0, 0, 0);
=
- KASSERT(mutex_owned(&sc->sc_lock));
+ KASSERT(sc->sc_bus.ub_usepolling || mutex_owned(&sc->sc_lock));
=
DPRINTFN(8, "addr=3D%jd endpt=3D%jd len=3D%jd speed=3D%jd",
xfer->ux_pipe->up_dev->ud_addr,
@@ -1675,7 +1675,7 @@ ohci_device_bulk_done(struct usbd_xfer *
int isread =3D
(UE_GET_DIR(xfer->ux_pipe->up_endpoint->ue_edesc->bEndpointAddress) =
=3D=3D UE_DIR_IN);
=
- KASSERT(mutex_owned(&sc->sc_lock));
+ KASSERT(sc->sc_bus.ub_usepolling || mutex_owned(&sc->sc_lock));
=
OHCIHIST_FUNC(); OHCIHIST_CALLED();
DPRINTFN(10, "xfer=3D%#jx, actlen=3D%jd", (uintptr_t)xfer, xfer->ux_actl=
en,
Home |
Main Index |
Thread Index |
Old Index