[ros-dev] livecd crash in serial.sys on real hw

Royce Mitchell III royce3 at ev1.net
Wed Apr 6 00:59:28 CEST 2005


essentially, I've tracked down the problem to SerialPnpStartDevice() 
being called with ResourceList == NULL.

Here's the details, if ya want 'em:

serial.sys
exception not handled
stop 1e ( c0000005, 9d2f9019, 0, 0 )
serial.sys address 9d2f9019 base 9d2f6000
page fault 14(0)
cs:eip 8:9d2f9019 <serial.sys: 3019> pnp.c:168
cr2 0 cr3 27000 proc: 8084ad00 Pid: 4 <System> Thrd: 8084b828 Tid: 0
DS,ES,GS=10 FS=30
eax 808a7660
ebx 0
ecx 808a7580
edx 808a7828
ebp 800bc9b4
esi 808a77b8
esp 800be808
edi 0
eflags 00210292
kesp 800be808
kernel stack base 800bd000
frames:
<serial.sys: 352b> pnp.c:341, SerialPnP() calling SerialPnpStartDevice()
<ntoskrnl.exe: 329c5> io/irp.c:212, IofCallDriver() calling indirect
<ntoskrnl.exe: 329e1> io/irp.c:226, IoCallDriver() calling IofCallDriver()
<ntoskrnl.exe: 34975> io/pnpmgr.c:665, IopInitiatePnpIrp() calling 
IoCallDriver()
<ntoskrnl.exe: 2d151> io/device.c:78, IopInitializeDevice() calling 
IopInitiatePnpIrp()
<ntoskrnl.exe: 2fa9d> io/driver.c:1890, NtLoadDriver() calling 
IopInitializeDevice()
<ntoskrnl.exe: 318b> ke/i386/syscall.S:178
<ntoskrnl.exe: 2536d> ex/zw.S:771, ZwLoadDriver()
<ntoskrnl.exe: 2efa1> io/driver.c:1378, IopInitializeSystemDrivers() 
calling IopLoadDriver()
<8007cc61> ??? only possibility is: IoInit3() calling 
IopInitializeSystemDrivers()
<8007d7ac> ??? only possibility is: ExpInitializeExecutive() calling 
IoInit3()
<ntoskrnl.exe: d04c> ke/main.c:104, KiSystemStartup() calling 
ExpInitializeExecutive()
<80079290> ke/main.c:283, _main() calling KiSystemStartup();
<ntoskrnl.exe: 104b> ke/i386/main.S:51

now, serial.sym:
   13019:    8b 07                    mov    (%edi),%eax

C:\cvs\reactos\drivers\dd\serial>addr2line -e serial.nostrip.sys 13019
C:/cvs/reactos/drivers/dd/serial/pnp.c:168

C:/cvs/reactos/drivers/dd/serial/pnp.c:168:
    for (i = 0; i < ResourceList->Count; i++)

notice edi is NULL, which is holding the value of ResourceList, which 
traces it's origin back to:
    
IoGetCurrentIrpStackLocation(Irp)->Parameters.StartDevice.AllocatedResources
which in turn comes from:
    DeviceNode->BootResources at ntoskrnl/io/device.c:68 in 
IopInitializeDevice()
there's a FIXME on the line above:
      /* FIXME: Should be DeviceNode->ResourceList */

hpoussin, or anybody else? should serial.sys handle a NULL ResourceList 
gracefully ( imho it should probably have some SEH in there ), or is it 
a bug for it to be getting a NULL ResourceList?




More information about the Ros-dev mailing list