I'm getting no debug information when debugging en_windows_7_checked_build_dvd_x86_398742. I can't see even my own trace info (ATLTRACE). In opposite, Windows XP Checked works like a charm. I get "Bad QueryIdType:5" msg on debug session start with Windows 7. Kernel debug is set up properly obviously. Please help...
On the host computer, open WinDbg and establish a kernel-mode debugging session with the target computer. In WinDbg, choose Contents from the Help menu. This opens the debugger documentation CHM file. The debugger documentation is also available on line in Debugging Tools for Windows.
WinDbg is a kernel-mode and user-mode debugger that is included in Debugging Tools for Windows. Here we provide hands-on exercises that will help you get started using WinDbg as a user-mode debugger. For information about how to get Debugging Tools for Windows, see Debugging Tools for Windows (WinDbg, KD, CDB, NTSD).
The Windows Debugger (WinDbg) can be used to debug kernel-mode and user-mode code, analyze crash dumps, and examine the CPU registers while the code executes. To get started with Windows debugging, see Getting Started with Windows Debugging.
I was able to fix it from within windbg, on windows 7 32 bit:
ed Kd_DEFAULT_Mask 8
According to the msdn article, you can also use the registry, but you must reboot for it to take effect. Create a DWORD key under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Debug Print Filter
called DEFAULT
with a value of 8
.
The up to date microsoft documentation is available here: http://msdn.microsoft.com/en-us/library/windows/hardware/ff551519(v=vs.85).aspx
OK, i found the solution here. It may help people:
The problem: Your DbgPrint or KdPrint messages don't appear in WinDbg (or KD) when you run your driver on Windows Vista.
The reason? Vista automatically maps DbgPrint and friends to DbgPrintEx. Now, you may recall that DbgPrintEx allows you to control the conditions under which messages will be sent to the kernel debugger by filtering messages via a component name and level in the function call and an associated filter mask in either the registry or in memory.
In Vista, DbgPrint and KdPrint are mapped to component "DPFLTR_DEFAULT_ID" and level "DPFLTR_INFO_LEVEL". Of course, in Vista, xxx_INFO_LEVEL output is disabled by default. So, by default, your DbgPrint/KdPrint doesn't get sent to the kernel debugger.
How to fix it? Two choices:
Enable output of DbgPrint/KdPrint messages by default --Open the key
HKLM\SYSTEM\CurrentControlSet\Session Manager\Debug Print Filter
. Under this key, create a value with the nameDEFAULT
Set the value of this key equal to the DWORD value 8 to enable xxx_INFO_LEVEL output as well asxxx_ERROR_LEVEL
output. Or try setting the mask to 0xF so you get all output. You must reboot for these changes to take effect.Specifically change the component filter mast for
DPFLTR
. In early releases of Vista/LH you changed the default printout mask by specifying a mask value for the DWORD atKd_DPFLTR_MASK
("ed Kd_DPFLTR_MASK"). In build 5308 (the February CTP of Vista), it seems that the mask variable has changed and you need to set the mask value for the DWORD atKd_DEFAULT_MASK
("ed Kd_DEFAULT_MASK). In either case, specify 8 to enableDPFLTR_INFO_LEVEL
output in addition toDPFLTR_ERROR_LEVEL
output, or 0xF to get all levels of output.See the WDK documentation for Reading and Filtering Debugging Messages (follow the path: Driver Development Tools\Tools for Debugging Drivers\Using Debugging Code in a Driver\Debugging Code Overview) for the complete details on the use of DbgPrintEx/KdPrintEx. Or look at the Debugging Tools For Windows documentation (Appendix A) on DbgPrintEx.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With