Unix Technical Forum

USB/ohci looping message at boot patch

This is a discussion on USB/ohci looping message at boot patch within the mailing.openbsd.tech forums, part of the OpenBSD category; --> On some systems, booting with USB devices attached causes the kernel to "hang" with repeating "ohci_intr: ignored interrupt while ...


Go Back   Unix Technical Forum > Unix Operating Systems > OpenBSD > mailing.openbsd.tech

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-18-2008, 07:59 AM
Hakan Olsson
 
Posts: n/a
Default USB/ohci looping message at boot patch

On some systems, booting with USB devices attached causes the kernel to
"hang" with repeating "ohci_intr: ignored interrupt while polling"
messages. The following diff should fix that. Please test and report.

/H

Index: sys/dev/usb/ohci.c
================================================== =================
RCS file: /cvs/src/sys/dev/usb/ohci.c,v
retrieving revision 1.38
diff -u -u -r1.38 ohci.c
--- sys/dev/usb/ohci.c 4 May 2004 16:59:32 -0000 1.38
+++ sys/dev/usb/ohci.c 4 Jun 2004 11:19:50 -0000
@@ -1084,14 +1084,22 @@
ohci_intr(void *p)
{
ohci_softc_t *sc = p;
+ u_int32_t intrs;
+#ifdef DIAGNOSTIC
+ static struct timeval ohci_intr_tv;
+#endif

if (sc == NULL || sc->sc_dying)
return (0);

- /* If we get an interrupt while polling, then just ignore it. */
- if (sc->sc_bus.use_polling) {
+ /* Ignore some interrupts. */
+ if (!cold && sc->sc_bus.use_polling) {
+ intrs = OREAD4(sc, OHCI_INTERRUPT_STATUS);
+ intrs &= ~OHCI_MIE;
+ OWRITE4(sc, OHCI_INTERRUPT_STATUS, intrs); /* Ack */
#ifdef DIAGNOSTIC
- printf("ohci_intr: ignored interrupt while polling\n");
+ if ((intrs & sc->sc_eintrs) && usbd_ratecheck(&ohci_intr_tv))
+ printf("ohci_intr: ignored interrupt while polling\n");
#endif
return (0);
}

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 09:24 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
www.UnixAdminTalk.com