DragonFly BSD
DragonFly bugs List (threaded) for 2011-11
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

[DragonFlyBSD - Bug #2244] usb - system hangs during boot when USB mass storage device/stick is connected - 2.13.0.357.gcdb8af


From: Alan K via Redmine <bugtracker-admin@xxxxxxxxxxxxxxxxxxxxx>
Date: Wed, 23 Nov 2011 05:40:57 -0800

Issue #2244 has been updated by Alan K.


I got abit further with the kprintf's though not sure if its helpful!

"usb_delay_ms(&sc->sc_bus, USB_BUS_RESET_DELAY);" is in /usr/src/sys/bus/usb/usb_subr.c

usb_delay_ms() calls "delay((ms+1) * 1000);" with value 101000 (ms is 100).

delay() is defined as DELAY in /usr/src/sys/bus/usb/usb_subr.c

"DELAY(int n)" is in /usr/src/sys/platform/pc64/isa/clock.c

DELAY() calls "DODELAY(n, 0);" which is in /usr/src/sys/platform/pc64/isa/clock.c

while loop is entered: "while "(ticks_left > 0)"

Lots of "cpu_pause()"'s are done. Finally one of these calls does not return.

The last line printed on screen is:
"AK: calling cpu_pause. ticks_left: 1151353"


################

The while loop from "DODELAY(int n, int doswitch)" in /usr/src/sys/platform/pc64/isa/clock.c :

        /*
         * Loop until done.
         */
        kprintf("AK: DODELAY: Loop until done.\n");
        while (ticks_left > 0) {
                tick = sys_cputimer->count();
#ifdef DELAYDEBUG
                ++getit_calls;
#endif
                delta = tick - prev_tick;
                prev_tick = tick;
                if (delta < 0)
                        delta = 0;
                ticks_left -= delta;
                if (doswitch && ticks_left > 0) {
                        kprintf("AK: calling lwkt_switch\n");
                        lwkt_switch();
                }

                kprintf("AK: calling cpu_pause. ticks_left: %d\n", ticks_left);

                cpu_pause();

                kprintf("AK: just after cpu_pause. ticks_left: %d\n", ticks_left);
        }

        kprintf("AK: just finished while loop\n");


----------------------------------------
Bug #2244: usb - system hangs during boot when USB mass storage device/stick is connected - 2.13.0.357.gcdb8af
http://bugs.dragonflybsd.org/issues/2244

Author: Alan K
Status: New
Priority: Normal
Assignee: 
Category: 
Target version: 


Versions:

Workstation: Lenovo Thinkcentre M58p 
DragonFlyBSD: v2.13.0.357.gcdb8af-DEVELOPMENT X86_64_GENERIC x86_64

################

Problem Description:

My system hangs during boot if a USB mass storage device/stick is connected.
By hang I mean no more output is shown and I cannot turn off/on num lock key on keyboard.
A hard reset is needed at this stage.

This prevents me from installing DragonFlyBSD from a USB stick.

I first noticed the problem when trying to boot via USB using the 2011 Nov 17th "DragonFly-x86_64-LATEST-IMG.img".
I haven't tried older versions.

I can connect and use the USB mass storage device/stick after boot without problem, and shutdown while attached without problem.

################

I recompiled kernel with "options USB_DEBUG" and booted with verbose logging option.
The last lines shown are:

uhci1: <UHCI (generic) USB controller> [tentative] port 0x1860-0x187f irq 17 at device 26.1 on pci0
uhci1: Reserved 0x20 bytes for rid 0x20 type 4 at 0x1860
uhci1: LegSup = 0x0010

################



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]