Search code examples
visual-studio-2015remote-debuggingdevice-driver

Red box when trying to configure Visual Studio remote debugger


When trying to configure a machine for debugging in Visual Studio 20151, there is a strange red box around the Provision device and choose debugger settings option:

enter image description here

I did not place that red box in the screenshot; it really is there in the Visual Studio 2015 user interface.

My questions are:

  • What is this red box trying to tell me
  • Why am i unable to add a new target device (i.e. Next and Finish are always disabled (no matter what display name i enter, or what radio button i check))
  • How do i remotely debug a device driver?

Background

Setting up kernel mode debugging in Visual Studio is pretty well documented on MSDN:

Setting Up Kernel-Mode Debugging of a Virtual Machine in Visual Studio

There's only two problems:

Configuring the Host Computer

The host computer can be the same physical computer that is running the virtual machine, or it can be a separate computer.
1. On the host computer, in Visual Studio, on the Driver menu, choose Test > Configure Computer.

The first problem is that there is no Configure Computer option in the Driver > Test menu:

enter image description here

The docs are just out of date

Problem 2. We assume the documentation is out of date, and that they actually mean Driver > Test > Configure Devices, that crashes:

enter image description here

This is a well-known regression in Visual Studio 2015 Update 1:

Microsoft Connect: Fails to load Configure Devices (Closed)

1/12/2016 Gabriel [MSFT]

I apologize for the delay in communication. In short, this bug has been fixed recently and changes should be reflected in a future update to Visual Studio 2015.

The issue was closed in January. Four months later Visual Studio 2015 Update 2 has been released, and it is still broken:

2/11/2016
VS2015 Update 2 CTP still breaks with WDK10 10.0.10586.0.

3/25/2016
Still broken.

4/9/2016
VS2015 Update 2 with latest WDK still broken.....

Get to the config UI through another way

While one set of VS folks broke access to the Device Configuration UI through the documented way to reach it; there is still the undocumented way to access the Device Configuration UI. Justin Stenning pointed it out right here on Stackoverflow:

enter image description here

Which i am able to reach: it leads to the screenshot i showed at the top - a dialog that doesn't let me configure a device, and has a red box that's trying to tell me something:

enter image description here

What is this red box trying to tell me?
How do i configure a device for remote debugging?
How do i debug a device driver in Visual Studio 2015 Update 2?1

1 Community Edition


Solution

  • I had the same issue: "red box" and spent a couple of hours searching for the answer online. Then realized that the "red box" is from another Dialog element, as you can see in the official documentation.

    enter image description here

    So the solution is to resize "Device Configuration" Dialog window.