[Kernel Debugger] VS15 Kernel Driver

Ask your beginner questions here.
Post Reply
User avatar
Artur1338
Posts: 1
Joined: Sun Aug 07, 2016 10:18 pm

Sun Aug 14, 2016 1:37 pm

Hey,

i have a question and i am pretty new in kernel. So i settet up a VM with Serial and a Pipe so i can start the debugger of visualstudio and deploy my driver on the machine.
So for some reason my breakpoints made in visualstudio are not hit, only KdBreakPoints compiled in the driver source are hittet.
The point is i checked the log and it looks like the kernel debugger only connect to the vm, if i press on pause in visualstudio so i can look at the disassembly.
Here is a log :

Code: Select all

-----------------------------------------------------------------------
                  Starting New Debugger Session         
-----------------------------------------------------------------------
-----------------------------------------------------------------------

Microsoft (R) Windows Debugger Version 10.0.10586.567 AMD64
Copyright (c) Microsoft Corporation. All rights reserved.

DESKTOP-R0C2MN0\Asrock X99 (npipe WinIDE_01D1F63024582921) connected at Sun Aug 14 15:31:20 2016

Microsoft (R) Windows Debugger Version 10.0.10586.567 AMD64
Copyright (c) Microsoft Corporation. All rights reserved.

Opened \\.\pipe\debug
Waiting to reconnect... <<<------ dont connects 
[15:31:20:831]: Remove Existing Remote Package
[15:31:20:837]: Task "Remove Existing Remote Package" completed successfully
[15:31:20:858]: Copy Driver Package
[15:31:21:006]: Task "Copy Driver Package" completed successfully
[15:31:21:037]: Driver Removal
[15:31:21:038]: Removing any existing files from test execution folder.
[15:31:21:065]: Copying required files for "Driver Removal".

$KitRoot$\Testing\Runtimes\TAEF\te.exe "%SystemDrive%\DriverTest\Run\DriverTestTasks.dll" /select:"@Name='DriverTestTasks::_DriverRemoval'" /p:"InfFile=BoostFabrikDrv.inf" /p:"Debug=1" /p:"ImportDriver=1" /p:"RemoveDriver=1" /p:"CertificateFile=BoostFabrikDrv.cer" /p:"PackageGuid=x64" /rebootStateFile:%SystemDrive%\DriverTest\Run\DriverTestReboot.xml /enableWttLogging /wttDeviceString:$LogFile:file="%SystemDrive%\DriverTest\Run\Driver_Removal_00132.wtl",writemode=append,encoding=unicode,nofscache=true,EnableLvl="WexStartTest|WexEndTest|WexXml|WexProperty|WexCreateContext|WexCloseContext|*" /runas:Elevated
[15:31:42:600]: Result Summary: Total=1, Passed=1, Failed=0, Blocked=0, Warned=0, Skipped=0
[15:31:42:602]: Task "Driver Removal" completed successfully
[15:31:43:067]: Driver Preparation
[15:31:43:068]: Removing any existing files from test execution folder.
[15:31:43:089]: Copying required files for "Driver Preparation".

$KitRoot$\Testing\Runtimes\TAEF\te.exe "%SystemDrive%\DriverTest\Run\DriverTestTasks.dll" /select:"@Name='DriverTestTasks::_DriverPreparation'" /p:"InfFile=BoostFabrikDrv.inf" /p:"Debug=1" /p:"ImportDriver=1" /p:"RemoveDriver=1" /p:"CertificateFile=BoostFabrikDrv.cer" /p:"PackageGuid=x64" /rebootStateFile:%SystemDrive%\DriverTest\Run\DriverTestReboot.xml /enableWttLogging /wttDeviceString:$LogFile:file="%SystemDrive%\DriverTest\Run\Driver_Preparation_00132.wtl",writemode=append,encoding=unicode,nofscache=true,EnableLvl="WexStartTest|WexEndTest|WexXml|WexProperty|WexCreateContext|WexCloseContext|*" /runas:Elevated
[15:31:49:638]: Result Summary: Total=1, Passed=1, Failed=0, Blocked=0, Warned=0, Skipped=0
[15:31:49:641]: Task "Driver Preparation" completed successfully
[15:31:50:075]: Driver Post Install Actions
[15:31:50:076]: Removing any existing files from test execution folder.
[15:31:50:094]: Copying required files for "Driver Post Install Actions".

$KitRoot$\Testing\Runtimes\TAEF\te.exe "%SystemDrive%\DriverTest\Run\DriverTestTasks.dll" /select:"@Name='DriverTestTasks::_DriverPostInstall'" /rebootStateFile:%SystemDrive%\DriverTest\Run\DriverTestReboot.xml /enableWttLogging /wttDeviceString:$LogFile:file="%SystemDrive%\DriverTest\Run\Driver_Post_Install_Actions_00132.wtl",writemode=append,encoding=unicode,nofscache=true,EnableLvl="WexStartTest|WexEndTest|WexXml|WexProperty|WexCreateContext|WexCloseContext|*" /runas:Elevated
[15:31:53:588]: Result Summary: Total=1, Passed=1, Failed=0, Blocked=0, Warned=0, Skipped=0
[15:31:53:590]: Task "Driver Post Install Actions" completed successfully
The Pipe and the Machine should be setup properly. The only thing i dont made is

Code: Select all

bcdedit /debug on 
because then my vm hang on startup although i attached the kernel debugger from vs and it connected to it.
This is my config of the vm / vs.
Image

Maybe u guys have a idea why this is happining.

Regards Artur and sorry for my english
Post Reply