USB driver not working on windows 7

P

paramita

Hi,

Please excuse me if this is not the right group for this post.I have a
usb host client driver which works fine on windows Xp as well as
windows vista but it causes an operating system hang on windows 7.The
initial exchange happens correctly, device descriptors, configuration
and interface descriptors are all got from the connected device
without a glitch but as soon as a bulk transfer is initiated the
system crashes.The exact point of the crash is when my driver passes
an Irp for IOCTL_INTERNAL_USB_SUBMIT_URB (bulk / interrupt transfer)
to lower drivers using IoCallDriver.The IoCallDriver function does not
return.

The windbg shows the following debug analysis:
IoBuildDeviceIoControlRequestAssertion failure - code c0000420 (first
chance)
nt!MmBuildMdlForNonPagedPool+0x131:
826aa6f5 cd2c int 2c
0: kd> ! analyze -v
Connected to Windows Longhorn 7000 x86 compatible target, ptr64 FALSE
*** ERROR: Symbol file could not be found. Defaulted to export
symbols for ntkrpamp.exe -
Loading Kernel Symbols
..............................................................................................................................................................................
Loading unloaded module list
......
Loading User Symbols
.....................................

*******************************************************************************
*
*
* Bugcheck
Analysis *
*
*
*******************************************************************************

Unknown bugcheck code (0)
Unknown bugcheck description
Arguments:
Arg1: 00000000
Arg2: 00000000
Arg3: 00000000
Arg4: 00000000

Debugging Details:
------------------

***** Kernel symbols are WRONG. Please fix symbols to do analysis.

*************************************************************************
***
***
***
***
*** Your debugger is not using the correct symbols
***
***
***
*** In order for this command to work properly, your symbol path
***
*** must point to .pdb files that have full type information.
***
***
***
*** Certain .pdb files (such as the public OS symbols) do not
***
*** contain the required information. Contact the group that
***
*** provided you with these symbols if you need this command to
***
*** work.
***
***
***
*** Type referenced: nt!_KPRCB
***
***
***
*************************************************************************

FAULTING_IP:
nt!MmBuildMdlForNonPagedPool+131
826aa6f5 cd2c int 2c

EXCEPTION_RECORD: ffffffff -- (.exr ffffffffffffffff)
ExceptionAddress: 826aa6f5 (nt!MmBuildMdlForNonPagedPool+0x00000131)
ExceptionCode: c0000420 (Assertion failure)
ExceptionFlags: 00000000
NumberParameters: 0

ERROR_CODE: (NTSTATUS) 0xc0000420 - <Unable to get error code text>

DEFAULT_BUCKET_ID: DRIVER_FAULT

BUGCHECK_STR: 0x0

LAST_CONTROL_TRANSFER: from 902319c8 to 826aa6f5

STACK_TEXT:
WARNING: Stack unwind information not available. Following frames may
be wrong.
96171a0c 902319c8 a81df1b8 8a0430e0 905700e0 nt!
MmBuildMdlForNonPagedPool+0x131
96171a48 9023a669 90570028 00000000 8a153c48 USBPORT+0x249c8
96171a70 9021145c 90570028 8a153c48 a9688eb0 USBPORT!DllInitialize
+0x1289
96171a98 826369a6 90570028 905702c4 8a086760 USBPORT+0x445c
96171ab8 94472034 8a153d24 8a153c48 00000000 nt!IofCallDriver+0x7e
96171ad0 94496eef 90572028 8a0866a8 8a153c48 usbhub+0x4034
96171af4 9446fc55 8a0866a8 00000000 8a0866a8 usbhub+0x28eef
96171b0c 826369a6 8a0866a8 8a153c48 a8111d70 usbhub+0x1c55
96171b2c 8c872807 fffffffe 82770b0e 00000000 nt!IofCallDriver+0x7e
96171b60 8c873c49 a8111d70 8a0430e0 0000000a sam_miniusb!
Sodiusb_CallUSBD+0x97 [d:\windows_vista64\framemanager-wince-
vista-1.0.0.7\framemanager-wince-vista-1.0.0.7\usb\sodiusb.c @ 1227]
96171bec 826369a6 a8111d70 8a14e288 00000000 sam_miniusb!
Sodiusb_ProcessIOCTL+0x279 [d:\windows_vista64\framemanager-wince-
vista-1.0.0.7\framemanager-wince-vista-1.0.0.7\usb\sodiusb.c @ 1854]
96171c0c 82b37d44 8a14e288 8a14e388 8a079408 nt!IofCallDriver+0x7e
96171c2c 82b38eda a8111d70 8a079408 00000000 nt!IoReplaceFileObjectName
+0x45c2
96171cc8 82b3f4ea 00000124 8a14e288 00000000 nt!IoReplaceFileObjectName
+0x5758
96171d04 827d0313 00000124 00000000 00000000 nt!NtDeviceIoControlFile
+0x4c
96171d34 775b9a64 badb0d00 03affe88 00000000 nt!
KeReleaseInStackQueuedSpinLockFromDpcLevel+0xc63
03affee0 00421802 00000124 00222058 03afff58 ntdll+0x39a64
005219b8 0000010c ffcbbc5d 00010075 00000000 sam_controller+0x21802


FOLLOWUP_IP:
sam_miniusb!Sodiusb_CallUSBD+97 [d:\windows_vista64\framemanager-wince-
vista-1.0.0.7\framemanager-wince-vista-1.0.0.7\usb\sodiusb.c @ 1227]
8c872807 8945f0 mov [ebp-0x10],eax

SYMBOL_STACK_INDEX: 9

FOLLOWUP_NAME: MachineOwner

SYMBOL_NAME: sam_miniusb!Sodiusb_CallUSBD+97

MODULE_NAME: sam_miniusb

IMAGE_NAME: sam_miniusb.sys

DEBUG_FLR_IMAGE_TIMESTAMP: 499e4d5d

STACK_COMMAND: kb

BUCKET_ID: WRONG_SYMBOLS

Followup: MachineOwner
---------
 
D

Doron Holan [MSFT]

first you need to fix your symbols to get a meaningful stack trace...

d

--

This posting is provided "AS IS" with no warranties, and confers no rights.


paramita said:
Hi,

Please excuse me if this is not the right group for this post.I have a
usb host client driver which works fine on windows Xp as well as
windows vista but it causes an operating system hang on windows 7.The
initial exchange happens correctly, device descriptors, configuration
and interface descriptors are all got from the connected device
without a glitch but as soon as a bulk transfer is initiated the
system crashes.The exact point of the crash is when my driver passes
an Irp for IOCTL_INTERNAL_USB_SUBMIT_URB (bulk / interrupt transfer)
to lower drivers using IoCallDriver.The IoCallDriver function does not
return.

The windbg shows the following debug analysis:
IoBuildDeviceIoControlRequestAssertion failure - code c0000420 (first
chance)
nt!MmBuildMdlForNonPagedPool+0x131:
826aa6f5 cd2c int 2c
0: kd> ! analyze -v
Connected to Windows Longhorn 7000 x86 compatible target, ptr64 FALSE
*** ERROR: Symbol file could not be found. Defaulted to export
symbols for ntkrpamp.exe -
Loading Kernel Symbols
.............................................................................................................................................................................
Loading unloaded module list
.....
Loading User Symbols
....................................

*******************************************************************************
*
*
* Bugcheck
Analysis *
*
*
*******************************************************************************

Unknown bugcheck code (0)
Unknown bugcheck description
Arguments:
Arg1: 00000000
Arg2: 00000000
Arg3: 00000000
Arg4: 00000000

Debugging Details:
------------------

***** Kernel symbols are WRONG. Please fix symbols to do analysis.

*************************************************************************
***
***
***
***
*** Your debugger is not using the correct symbols
***
***
***
*** In order for this command to work properly, your symbol path
***
*** must point to .pdb files that have full type information.
***
***
***
*** Certain .pdb files (such as the public OS symbols) do not
***
*** contain the required information. Contact the group that
***
*** provided you with these symbols if you need this command to
***
*** work.
***
***
***
*** Type referenced: nt!_KPRCB
***
***
***
*************************************************************************

FAULTING_IP:
nt!MmBuildMdlForNonPagedPool+131
826aa6f5 cd2c int 2c

EXCEPTION_RECORD: ffffffff -- (.exr ffffffffffffffff)
ExceptionAddress: 826aa6f5 (nt!MmBuildMdlForNonPagedPool+0x00000131)
ExceptionCode: c0000420 (Assertion failure)
ExceptionFlags: 00000000
NumberParameters: 0

ERROR_CODE: (NTSTATUS) 0xc0000420 - <Unable to get error code text>

DEFAULT_BUCKET_ID: DRIVER_FAULT

BUGCHECK_STR: 0x0

LAST_CONTROL_TRANSFER: from 902319c8 to 826aa6f5

STACK_TEXT:
WARNING: Stack unwind information not available. Following frames may
be wrong.
96171a0c 902319c8 a81df1b8 8a0430e0 905700e0 nt!
MmBuildMdlForNonPagedPool+0x131
96171a48 9023a669 90570028 00000000 8a153c48 USBPORT+0x249c8
96171a70 9021145c 90570028 8a153c48 a9688eb0 USBPORT!DllInitialize
+0x1289
96171a98 826369a6 90570028 905702c4 8a086760 USBPORT+0x445c
96171ab8 94472034 8a153d24 8a153c48 00000000 nt!IofCallDriver+0x7e
96171ad0 94496eef 90572028 8a0866a8 8a153c48 usbhub+0x4034
96171af4 9446fc55 8a0866a8 00000000 8a0866a8 usbhub+0x28eef
96171b0c 826369a6 8a0866a8 8a153c48 a8111d70 usbhub+0x1c55
96171b2c 8c872807 fffffffe 82770b0e 00000000 nt!IofCallDriver+0x7e
96171b60 8c873c49 a8111d70 8a0430e0 0000000a sam_miniusb!
Sodiusb_CallUSBD+0x97 [d:\windows_vista64\framemanager-wince-
vista-1.0.0.7\framemanager-wince-vista-1.0.0.7\usb\sodiusb.c @ 1227]
96171bec 826369a6 a8111d70 8a14e288 00000000 sam_miniusb!
Sodiusb_ProcessIOCTL+0x279 [d:\windows_vista64\framemanager-wince-
vista-1.0.0.7\framemanager-wince-vista-1.0.0.7\usb\sodiusb.c @ 1854]
96171c0c 82b37d44 8a14e288 8a14e388 8a079408 nt!IofCallDriver+0x7e
96171c2c 82b38eda a8111d70 8a079408 00000000 nt!IoReplaceFileObjectName
+0x45c2
96171cc8 82b3f4ea 00000124 8a14e288 00000000 nt!IoReplaceFileObjectName
+0x5758
96171d04 827d0313 00000124 00000000 00000000 nt!NtDeviceIoControlFile
+0x4c
96171d34 775b9a64 badb0d00 03affe88 00000000 nt!
KeReleaseInStackQueuedSpinLockFromDpcLevel+0xc63
03affee0 00421802 00000124 00222058 03afff58 ntdll+0x39a64
005219b8 0000010c ffcbbc5d 00010075 00000000 sam_controller+0x21802


FOLLOWUP_IP:
sam_miniusb!Sodiusb_CallUSBD+97 [d:\windows_vista64\framemanager-wince-
vista-1.0.0.7\framemanager-wince-vista-1.0.0.7\usb\sodiusb.c @ 1227]
8c872807 8945f0 mov [ebp-0x10],eax

SYMBOL_STACK_INDEX: 9

FOLLOWUP_NAME: MachineOwner

SYMBOL_NAME: sam_miniusb!Sodiusb_CallUSBD+97

MODULE_NAME: sam_miniusb

IMAGE_NAME: sam_miniusb.sys

DEBUG_FLR_IMAGE_TIMESTAMP: 499e4d5d

STACK_COMMAND: kb

BUCKET_ID: WRONG_SYMBOLS

Followup: MachineOwner
 
P

paramita

first you need to fix your symbols to get a meaningful stack trace...

d

--

This posting is provided "AS IS" with no warranties, and confers no rights.




Please excuse me if this is not the right group for this post.I have a
usb host client driver which works fine on windows Xp as well as
windows vista but it causes an operating system hang on windows 7.The
initial exchange happens correctly, device descriptors, configuration
and interface descriptors are all got from the connected device
without a glitch but as soon as abulktransferis initiated the
system crashes.The exact point of the crash is when my driver passes
an Irp forIOCTL_INTERNAL_USB_SUBMIT_URB(bulk/interrupttransfer)
to lower drivers using IoCallDriver.The IoCallDriver function does not
return.
The windbg shows the following debug analysis:
IoBuildDeviceIoControlRequestAssertion failure - code c0000420 (first
chance)
nt!MmBuildMdlForNonPagedPool+0x131:
826aa6f5 cd2c             int     2c
0: kd> ! analyze -v
Connected to Windows Longhorn 7000 x86 compatible target, ptr64 FALSE
*** ERROR: Symbol file could not be found.  Defaulted to export
symbols for ntkrpamp.exe -
Loading Kernel Symbols
............................................................................­............................................................................­.......................
Loading unloaded module list
.....
Loading User Symbols
....................................
***************************************************************************­****
*
*
*                        Bugcheck
Analysis                                    *
*
*
***************************************************************************­****
Unknown bugcheck code (0)
Unknown bugcheck description
Arguments:
Arg1: 00000000
Arg2: 00000000
Arg3: 00000000
Arg4: 00000000
Debugging Details:
------------------
***** Kernel symbols are WRONG. Please fix symbols to do analysis.
*************************************************************************
***
***
***
***
***    Your debugger is not using the correct symbols
***
***
***
***    In order for this command to work properly, your symbol path
***
***    must point to .pdb files that have full type information.
***
***
***
***    Certain .pdb files (such as the public OS symbols) do not
***
***    contain the required information.  Contact the group that
***
***    provided you with these symbols if you need this command to
***
***    work.
***
***
***
***    Type referenced: nt!_KPRCB
***
***
***
*************************************************************************
FAULTING_IP:
nt!MmBuildMdlForNonPagedPool+131
826aa6f5 cd2c             int     2c
EXCEPTION_RECORD:  ffffffff -- (.exr ffffffffffffffff)
ExceptionAddress: 826aa6f5 (nt!MmBuildMdlForNonPagedPool+0x00000131)
  ExceptionCode: c0000420 (Assertion failure)
 ExceptionFlags: 00000000
NumberParameters: 0
ERROR_CODE: (NTSTATUS) 0xc0000420 - <Unable to get error code text>
DEFAULT_BUCKET_ID:  DRIVER_FAULT
BUGCHECK_STR:  0x0
LAST_CONTROL_TRANSFER:  from 902319c8 to 826aa6f5
STACK_TEXT:
WARNING: Stack unwind information not available. Following frames may
be wrong.
96171a0c 902319c8 a81df1b8 8a0430e0 905700e0 nt!
MmBuildMdlForNonPagedPool+0x131
96171a48 9023a669 90570028 00000000 8a153c48 USBPORT+0x249c8
96171a70 9021145c 90570028 8a153c48 a9688eb0 USBPORT!DllInitialize
+0x1289
96171a98 826369a6 90570028 905702c4 8a086760 USBPORT+0x445c
96171ab8 94472034 8a153d24 8a153c48 00000000 nt!IofCallDriver+0x7e
96171ad0 94496eef 90572028 8a0866a8 8a153c48 usbhub+0x4034
96171af4 9446fc55 8a0866a8 00000000 8a0866a8 usbhub+0x28eef
96171b0c 826369a6 8a0866a8 8a153c48 a8111d70 usbhub+0x1c55
96171b2c 8c872807 fffffffe 82770b0e 00000000 nt!IofCallDriver+0x7e
96171b60 8c873c49 a8111d70 8a0430e0 0000000a sam_miniusb!
Sodiusb_CallUSBD+0x97 [d:\windows_vista64\framemanager-wince-
vista-1.0.0.7\framemanager-wince-vista-1.0.0.7\usb\sodiusb.c @ 1227]
96171bec 826369a6 a8111d70 8a14e288 00000000 sam_miniusb!
Sodiusb_ProcessIOCTL+0x279 [d:\windows_vista64\framemanager-wince-
vista-1.0.0.7\framemanager-wince-vista-1.0.0.7\usb\sodiusb.c @ 1854]
96171c0c 82b37d44 8a14e288 8a14e388 8a079408 nt!IofCallDriver+0x7e
96171c2c 82b38eda a8111d70 8a079408 00000000 nt!IoReplaceFileObjectName
+0x45c2
96171cc8 82b3f4ea 00000124 8a14e288 00000000 nt!IoReplaceFileObjectName
+0x5758
96171d04 827d0313 00000124 00000000 00000000 nt!NtDeviceIoControlFile
+0x4c
96171d34 775b9a64 badb0d00 03affe88 00000000 nt!
KeReleaseInStackQueuedSpinLockFromDpcLevel+0xc63
03affee0 00421802 00000124 00222058 03afff58 ntdll+0x39a64
005219b8 0000010c ffcbbc5d 00010075 00000000 sam_controller+0x21802
FOLLOWUP_IP:
sam_miniusb!Sodiusb_CallUSBD+97 [d:\windows_vista64\framemanager-wince-
vista-1.0.0.7\framemanager-wince-vista-1.0.0.7\usb\sodiusb.c @ 1227]
8c872807 8945f0           mov     [ebp-0x10],eax
SYMBOL_STACK_INDEX:  9
FOLLOWUP_NAME:  MachineOwner
SYMBOL_NAME:  sam_miniusb!Sodiusb_CallUSBD+97
MODULE_NAME:  sam_miniusb
IMAGE_NAME:  sam_miniusb.sys
DEBUG_FLR_IMAGE_TIMESTAMP:  499e4d5d
STACK_COMMAND:  kb
BUCKET_ID:  WRONG_SYMBOLS
Followup: MachineOwner
---------- Hide quoted text -

- Show quoted text -

Thanks for the reply.Actually I am very new to driver debugging.can
you please tell me how to get these symbols fixed because whatever
settings i try on Windbg i always get this message of wrong
symbols.And any idea why nt!MmBuildMdlForNonPagedPool+0x00000131 might
cause a crash.I suppose it is some code in a lower driver which is
causing the crash.Please do tell me what you think.
Thanks for your help

Regards
confu-sed-cius
 
D

Doron Holan [MSFT]

run
..symfix
..reload /f
!analyze -v
and then send the output

d

--

This posting is provided "AS IS" with no warranties, and confers no rights.


paramita said:
first you need to fix your symbols to get a meaningful stack trace...

d

--

This posting is provided "AS IS" with no warranties, and confers no
rights.




Please excuse me if this is not the right group for this post.I have a
usb host client driver which works fine on windows Xp as well as
windows vista but it causes an operating system hang on windows 7.The
initial exchange happens correctly, device descriptors, configuration
and interface descriptors are all got from the connected device
without a glitch but as soon as abulktransferis initiated the
system crashes.The exact point of the crash is when my driver passes
an Irp forIOCTL_INTERNAL_USB_SUBMIT_URB(bulk/interrupttransfer)
to lower drivers using IoCallDriver.The IoCallDriver function does not
return.
The windbg shows the following debug analysis:
IoBuildDeviceIoControlRequestAssertion failure - code c0000420 (first
chance)
nt!MmBuildMdlForNonPagedPool+0x131:
826aa6f5 cd2c int 2c
0: kd> ! analyze -v
Connected to Windows Longhorn 7000 x86 compatible target, ptr64 FALSE
*** ERROR: Symbol file could not be found. Defaulted to export
symbols for ntkrpamp.exe -
Loading Kernel Symbols
...........................................................................­...........................................................................­.......................
Loading unloaded module list
.....
Loading User Symbols
....................................
***************************************************************************­****
*
*
* Bugcheck
Analysis *
*
*
***************************************************************************­****
Unknown bugcheck code (0)
Unknown bugcheck description
Arguments:
Arg1: 00000000
Arg2: 00000000
Arg3: 00000000
Arg4: 00000000
Debugging Details:
------------------
***** Kernel symbols are WRONG. Please fix symbols to do analysis.
*************************************************************************
***
***
***
***
*** Your debugger is not using the correct symbols
***
***
***
*** In order for this command to work properly, your symbol path
***
*** must point to .pdb files that have full type information.
***
***
***
*** Certain .pdb files (such as the public OS symbols) do not
***
*** contain the required information. Contact the group that
***
*** provided you with these symbols if you need this command to
***
*** work.
***
***
***
*** Type referenced: nt!_KPRCB
***
***
***
*************************************************************************
FAULTING_IP:
nt!MmBuildMdlForNonPagedPool+131
826aa6f5 cd2c int 2c
EXCEPTION_RECORD: ffffffff -- (.exr ffffffffffffffff)
ExceptionAddress: 826aa6f5 (nt!MmBuildMdlForNonPagedPool+0x00000131)
ExceptionCode: c0000420 (Assertion failure)
ExceptionFlags: 00000000
NumberParameters: 0
ERROR_CODE: (NTSTATUS) 0xc0000420 - <Unable to get error code text>
DEFAULT_BUCKET_ID: DRIVER_FAULT
BUGCHECK_STR: 0x0
LAST_CONTROL_TRANSFER: from 902319c8 to 826aa6f5
STACK_TEXT:
WARNING: Stack unwind information not available. Following frames may
be wrong.
96171a0c 902319c8 a81df1b8 8a0430e0 905700e0 nt!
MmBuildMdlForNonPagedPool+0x131
96171a48 9023a669 90570028 00000000 8a153c48 USBPORT+0x249c8
96171a70 9021145c 90570028 8a153c48 a9688eb0 USBPORT!DllInitialize
+0x1289
96171a98 826369a6 90570028 905702c4 8a086760 USBPORT+0x445c
96171ab8 94472034 8a153d24 8a153c48 00000000 nt!IofCallDriver+0x7e
96171ad0 94496eef 90572028 8a0866a8 8a153c48 usbhub+0x4034
96171af4 9446fc55 8a0866a8 00000000 8a0866a8 usbhub+0x28eef
96171b0c 826369a6 8a0866a8 8a153c48 a8111d70 usbhub+0x1c55
96171b2c 8c872807 fffffffe 82770b0e 00000000 nt!IofCallDriver+0x7e
96171b60 8c873c49 a8111d70 8a0430e0 0000000a sam_miniusb!
Sodiusb_CallUSBD+0x97 [d:\windows_vista64\framemanager-wince-
vista-1.0.0.7\framemanager-wince-vista-1.0.0.7\usb\sodiusb.c @ 1227]
96171bec 826369a6 a8111d70 8a14e288 00000000 sam_miniusb!
Sodiusb_ProcessIOCTL+0x279 [d:\windows_vista64\framemanager-wince-
vista-1.0.0.7\framemanager-wince-vista-1.0.0.7\usb\sodiusb.c @ 1854]
96171c0c 82b37d44 8a14e288 8a14e388 8a079408 nt!IofCallDriver+0x7e
96171c2c 82b38eda a8111d70 8a079408 00000000 nt!IoReplaceFileObjectName
+0x45c2
96171cc8 82b3f4ea 00000124 8a14e288 00000000 nt!IoReplaceFileObjectName
+0x5758
96171d04 827d0313 00000124 00000000 00000000 nt!NtDeviceIoControlFile
+0x4c
96171d34 775b9a64 badb0d00 03affe88 00000000 nt!
KeReleaseInStackQueuedSpinLockFromDpcLevel+0xc63
03affee0 00421802 00000124 00222058 03afff58 ntdll+0x39a64
005219b8 0000010c ffcbbc5d 00010075 00000000 sam_controller+0x21802
FOLLOWUP_IP:
sam_miniusb!Sodiusb_CallUSBD+97 [d:\windows_vista64\framemanager-wince-
vista-1.0.0.7\framemanager-wince-vista-1.0.0.7\usb\sodiusb.c @ 1227]
8c872807 8945f0 mov [ebp-0x10],eax
SYMBOL_STACK_INDEX: 9
FOLLOWUP_NAME: MachineOwner
SYMBOL_NAME: sam_miniusb!Sodiusb_CallUSBD+97
MODULE_NAME: sam_miniusb
IMAGE_NAME: sam_miniusb.sys
DEBUG_FLR_IMAGE_TIMESTAMP: 499e4d5d
STACK_COMMAND: kb
BUCKET_ID: WRONG_SYMBOLS
Followup: MachineOwner
---------- Hide quoted text -

- Show quoted text -

Thanks for the reply.Actually I am very new to driver debugging.can
you please tell me how to get these symbols fixed because whatever
settings i try on Windbg i always get this message of wrong
symbols.And any idea why nt!MmBuildMdlForNonPagedPool+0x00000131 might
cause a crash.I suppose it is some code in a lower driver which is
causing the crash.Please do tell me what you think.
Thanks for your help

Regards
confu-sed-cius
 
Top