- On the target computer, open a Command Prompt window as Administrator, and enter these commands:
TargetName can be any name like
dbgmachine
bcdedit /debug on
bcdedit /bootdebug on // <-- Optional. Only required to debug boot related issues.
bcdedit /dbgsettings usb targetname:TargetName
- If you have more than one USB host controller on the target computer, enter this command:
bcdedit /set "{dbgsettings}" busparams b.d.f
-
Example: bcdedit /set "{dbgsettings}" busparams 48.0.0
-
On the host computer, open WinDbg. Chose USB Debug option and enter the TargetName specified above and connect. Or use below command
windbg /k usb:targetname=TargetName
- The target system USB 3.0 port should be Debug Capable so it can be used for Windows Kernel Debugging. This can be checked using some utility like USBView
- Kernel Debug Mask to allow all messages to be dumped to console
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Debug Print Filter]
"DEFAULT"=dword:ffffffff
- Enable Loader Flags (Show Loader Snaps?)
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager]
"GlobalFlag"=dword:00000002
lm m echo* v
!lmi echo
!dh echo
ed nt!Kd_DEFAULT_MASK 0xFFFFFFFF
.symfix
.srcpath+ C:\DriverSamples\KMDF_Echo_Sample\driver\AutoSync
.sympath+ C:\DriverSamples\KMDF_Echo_Sample\driver\AutoSync
.reload /f
.reboot <-- reboot target machine
.restart <-- re-establish target connection