From: mpefareo on
Hello,

I'm just starting learning Windows Drivers Development.
I tried to see any KdPrint messages in WinDbg but can't see any.
I have started WinDbg in Local Kernel mode. It seems to be ok. This is the
output from Windbg:

Connected to Windows XP 2600 x86 compatible target at (Sun Apr 4
14:23:10.250 2010 (GMT+1)), ptr64 FALSE
Symbol search path is:
D:\Archive\Jobs\WDK\toaster\exe\notify\objchk_wxp_x86\i386;C:\WINDOWS\Symbols;D:\Archive\Jobs\WDK\tracedrv\tracedrv\objchk_wxp_x86\i386;D:\Archive\Jobs\WDK\tracedrv\tracectl\objchk_wxp_x86\i386
Executable search path is:
D:\Archive\Jobs\WDK\tracedrv\tracedrv\objchk_wxp_x86\i386
Windows XP Kernel Version 2600 (Service Pack 3) MP (4 procs) Free x86
compatible
Product: WinNt, suite: TerminalServer SingleUserTS
Built by: 2600.xpsp.080413-2111
Machine Name:
Kernel base = 0x804d7000 PsLoadedModuleList = 0x805634c0
Debug session time: Sun Apr 4 14:23:10.609 2010 (GMT+1)
System Uptime: 0 days 0:44:56.551

After compiling the toaster simple function driver in checked build I did
"devcon install ...." this works as well I can see the driver in the driver
list. I can also uninstall it sucessfully. As I understand when I install the
driver the system calls DriverEntry function which has got KdPrint statement,
but I can't see any messages in WinDbg command window. How can I see any
KdPrint in WinDbg. Is the command windows the right place to look for them.
Or may be the limitation is "Local Kernel mode"? I even tried to run a sample
application which opens the driver and close the driver Ok, but still no
messages in WinDbg.
From: Don Burn on
It is a limitation of local kernel debugging. Basically you need two
machines or virtual systems to develop drivers.


Don Burn (MVP, Windows DKD)
Windows Filesystem and Driver Consulting
Website: http://www.windrvr.com
Blog: http://msmvps.com/blogs/WinDrvr




> -----Original Message-----
> From: mpefareo [mailto:mpefareo(a)discussions.microsoft.com]
> Posted At: Sunday, April 04, 2010 9:37 AM
> Posted To: microsoft.public.development.device.drivers
> Conversation: How to see KdPrint in WinDbg
> Subject: How to see KdPrint in WinDbg
>
> Hello,
>
> I'm just starting learning Windows Drivers Development.
> I tried to see any KdPrint messages in WinDbg but can't see any.
> I have started WinDbg in Local Kernel mode. It seems to be ok. This is
> the
> output from Windbg:
>
> Connected to Windows XP 2600 x86 compatible target at (Sun Apr 4
> 14:23:10.250
> 2010 (GMT+1)), ptr64 FALSE Symbol search path is:
> D:\Archive\Jobs\WDK\toaster\exe\notify\objchk_wxp_x86\i386;C:\WINDOWS\Symbols;
> D:\Archive\Jobs\WDK\tracedrv\tracedrv\objchk_wxp_x86\i386;D:\Archive\Jobs\WDK\
> tracedrv\tracectl\objchk_wxp_x86\i386
> Executable search path is:
> D:\Archive\Jobs\WDK\tracedrv\tracedrv\objchk_wxp_x86\i386
> Windows XP Kernel Version 2600 (Service Pack 3) MP (4 procs) Free x86
> compatible
> Product: WinNt, suite: TerminalServer SingleUserTS Built by:
> 2600.xpsp.080413-
> 2111 Machine Name:
> Kernel base = 0x804d7000 PsLoadedModuleList = 0x805634c0 Debug session
> time:
> Sun Apr 4 14:23:10.609 2010 (GMT+1) System Uptime: 0 days 0:44:56.551
>
> After compiling the toaster simple function driver in checked build I
> did
> "devcon install ...." this works as well I can see the driver in the
> driver
> list. I can also uninstall it sucessfully. As I understand when I
> install the
> driver the system calls DriverEntry function which has got KdPrint
> statement,
> but I can't see any messages in WinDbg command window. How can I see any
> KdPrint in WinDbg. Is the command windows the right place to look for
> them.
> Or may be the limitation is "Local Kernel mode"? I even tried to run a
> sample
> application which opens the driver and close the driver Ok, but still no
> messages in WinDbg.
>
>
> __________ Information from ESET Smart Security, version of virus
> signature
> database 4998 (20100404) __________
>
> The message was checked by ESET Smart Security.
>
> http://www.eset.com
>

From: mpefareo on
Thank you for your answer. I installed VirtualBox, and used it as a test
target. I can see debug outputs now.

"Don Burn" wrote:

> It is a limitation of local kernel debugging. Basically you need two
> machines or virtual systems to develop drivers.
>
>
> Don Burn (MVP, Windows DKD)
> Windows Filesystem and Driver Consulting
> Website: http://www.windrvr.com
> Blog: http://msmvps.com/blogs/WinDrvr
>
>
>
>
> > -----Original Message-----
> > From: mpefareo [mailto:mpefareo(a)discussions.microsoft.com]
> > Posted At: Sunday, April 04, 2010 9:37 AM
> > Posted To: microsoft.public.development.device.drivers
> > Conversation: How to see KdPrint in WinDbg
> > Subject: How to see KdPrint in WinDbg
> >
> > Hello,
> >
> > I'm just starting learning Windows Drivers Development.
> > I tried to see any KdPrint messages in WinDbg but can't see any.
> > I have started WinDbg in Local Kernel mode. It seems to be ok. This is
> > the
> > output from Windbg:
> >
> > Connected to Windows XP 2600 x86 compatible target at (Sun Apr 4
> > 14:23:10.250
> > 2010 (GMT+1)), ptr64 FALSE Symbol search path is:
> > D:\Archive\Jobs\WDK\toaster\exe\notify\objchk_wxp_x86\i386;C:\WINDOWS\Symbols;
> > D:\Archive\Jobs\WDK\tracedrv\tracedrv\objchk_wxp_x86\i386;D:\Archive\Jobs\WDK\
> > tracedrv\tracectl\objchk_wxp_x86\i386
> > Executable search path is:
> > D:\Archive\Jobs\WDK\tracedrv\tracedrv\objchk_wxp_x86\i386
> > Windows XP Kernel Version 2600 (Service Pack 3) MP (4 procs) Free x86
> > compatible
> > Product: WinNt, suite: TerminalServer SingleUserTS Built by:
> > 2600.xpsp.080413-
> > 2111 Machine Name:
> > Kernel base = 0x804d7000 PsLoadedModuleList = 0x805634c0 Debug session
> > time:
> > Sun Apr 4 14:23:10.609 2010 (GMT+1) System Uptime: 0 days 0:44:56.551
> >
> > After compiling the toaster simple function driver in checked build I
> > did
> > "devcon install ...." this works as well I can see the driver in the
> > driver
> > list. I can also uninstall it sucessfully. As I understand when I
> > install the
> > driver the system calls DriverEntry function which has got KdPrint
> > statement,
> > but I can't see any messages in WinDbg command window. How can I see any
> > KdPrint in WinDbg. Is the command windows the right place to look for
> > them.
> > Or may be the limitation is "Local Kernel mode"? I even tried to run a
> > sample
> > application which opens the driver and close the driver Ok, but still no
> > messages in WinDbg.
> >
> >
> > __________ Information from ESET Smart Security, version of virus
> > signature
> > database 4998 (20100404) __________
> >
> > The message was checked by ESET Smart Security.
> >
> > http://www.eset.com
> >
>
> .
>