I believe somebody passed that around on a list before, but there are other malloc bugs in bt code.
On Tue, Nov 16, 2010 at 2:09 PM, Miod Vallat <[email protected]> wrote: >> http://cvs.openbsd.org/cgi-bin/query-pr-wrapper?full=yes&numbers=6480 >> >> Concerning PR 6480 I need to add: it's caused by the btconfig ubt* up >> commmand, at least on my machine. And it happens on i386, too. > > Please try the following diff. > > Miod > > Index: uhci.c > =================================================================== > RCS file: /cvs/src/sys/dev/usb/uhci.c,v > retrieving revision 1.84 > diff -u -p -r1.84 uhci.c > --- uhci.c 23 Oct 2010 15:42:09 -0000 1.84 > +++ uhci.c 18 Nov 2010 19:10:13 -0000 > @@ -2757,7 +2757,9 @@ uhci_device_setintr(uhci_softc_t *sc, st > > upipe->u.intr.npoll = npoll; > upipe->u.intr.qhs = > - malloc(npoll * sizeof(uhci_soft_qh_t *), M_USBHC, M_WAITOK); > + malloc(npoll * sizeof(uhci_soft_qh_t *), M_USBHC, M_NOWAIT); > + if (upipe->u.intr.qhs == NULL) > + return (USBD_NOMEM); > > /* > * Figure out which offset in the schedule that has most
