Tech Support > Microsoft Windows > Drivers > UsbSamp used with Device Simulation Framework causes BSOD
UsbSamp used with Device Simulation Framework causes BSOD
Posted by Andre on February 22nd, 2008


Hi!

I get a BSOD when running the Simulated Loopback Device sample of the Device
Simulation Framework together with the WDK 6001.18000 sample device driver
src\kmdf\usbsamp (checked version). The BSOD occurs directly after the
simulated device got unplugged by the VB script. The kernel debugger
indicates that a assertion fails:

UsbSamp: EvtDeviceReleaseHardware - begins

*** Assertion failed: NT_SUCCESS(status)
*** Source File: c:\projects\usbsamp\sys\device.c, line 351

The status code, which is returned from call to
WdfUsbTargetDeviceSelectConfig, is STATUS_DEVICE_NOT_CONNECTED
((NTSTATUS)0xC000009DL).

Should the EvtDeviceReleaseHardware callback in usbsamp handle the case that
the device is no longer connected?

Is this maybe a bug in the Device Simulation Framework, which removes the
device too early?

Corresponds the Unplug method of the simulated hub to a surprise removal of
the device which is not handled correctly by the usbsamp driver?

Any ideas?
Thanks and best regards,
Andre







Posted by Andre on February 22nd, 2008


Hi,
I just found the answer to this question on the OSR ntdev forum.

http://www.osronline.com/showThread.cfm?link=119374

So it seems to be a bug in the usbsamp example.

Regards,
Andre


"Andre" wrote:

Posted by Doron Holan [MSFT] on February 22nd, 2008


you only get a BSOD if you run a chk driver w/out a debugger attached. if
you are doing driver development, do it right and attach a kernel debugger

d

--
Please do not send e-mail directly to this alias. this alias is for
newsgroup purposes only.
This posting is provided "AS IS" with no warranties, and confers no rights.


"Andre" <Andre@discussions.microsoft.com> wrote in message
newsA3EDBA8-AE6D-4E18-8FDA-58AC396D0022@microsoft.com...