Welcome to MSDN Blogs Sign in | Join | Help

August 2006 - Posts

Debugging a failed device install or disable can be tough. The error could be hidden in the depths of the system and it might take awhile to figure it out. The error code on the device might be of some help, but it is not always clear. For instance, you Read More...
It is not like I go read the WDK docs in my spare time, but one day I did and I came across IoCreateUnprotectedSymbolicLink . Huh? An unprotected symbolic link? I knew about IoCreateSymbolicLink (which by induction would be a protected symlink), but I Read More...
One of the first things I do when I get a new desktop machine or install a new build of Windows is to map the Sleep button on my keyboard to hibernate instead of suspend. Hibernate makes more sense for these machines because they will never run on batteries Read More...
When you call KeWaitForSingleObject or KeWaitForMultipleObjects you can provide a pointer to a timeout value. What value you pass for the pointer value makes a huge difference. This subtle distinction is something that first time driver writers do not Read More...
In my last post I showed how you can distinguish between to different device interfaces being opened on the same device object. While device interfaces are the Microsoft party line for how to expose a PnP device object which can be opened, I realize that Read More...
Let's say your device supports two interfaces and you want to expose both of them on the same device object. Furthermore, let's say that the I/O interface to each device interface is different. For instance, let's say that one interface allows only one Read More...
When an I/O is issued on behalf of a system service call (for example NtReadFile, NtWriteFile, etc), the I/O manager creates a threaded IRP and then issues the I/O. I previously wrote about this. Today, Paul has returned as a guest writer and will talk Read More...
In KMDF, the WDFIOTARGET object provides an abstraction for sending I/O to another PDEVICE_OBJECT and tracking all pending I/O. The WDFIOTARGET also provides formatting for specific types of I/O: read, write, IOCTL, and internal IOCTL. The WDFUSBDEVICE Read More...
I was interviewed for channel 9 a couple of weeks ago, you see the interview here . We talked about KMDF, the state machines and the future of driver development. I had a great time doing the interview, hopefully you like it as well. Please let me know Read More...
Yesterday I introduced the dl command and demonstrated some of its limitations. Today I will talk about !list . Let's take yesterday's data structure, MY_DATA. What if the LIST_ENTRY is at the end of the structure or there is more data in your structure Read More...
The use of the LIST_ENTRY structure in WDM is quite pervasive. It is used for nearly all list keeping tasks. I have used it extensively in the past and KMDF uses it quite a bit as well. There are two debugger commands that help in viewing the contents Read More...
Yesterday I wrote about the evolution of work items. Work items evolved because there was a need to have a reference on the device object until the work item's callback routine returned. As I illustrated yesterday, there is a small piece of assembly in Read More...
Have you ever looked at the work item APIs and wondered why there are two different types of work items? Or for that matter, why are there so many work item APIs? As Paul wrote last week, the work item API set has grown for Vista. Today I will try to Read More...
When debugging a failed device install, one of the first things you should do is look at the %windir%\setup*.log files (yes files, there are a few of them and the names changed in Vista). But what if the logs do not have enough information for you to Read More...
While writing the threaded and non-threaded PIRP entry, I had the I/O manager developers review what I wrote to make sure I was giving out correct information. After the review, the I/O manager folks wanted to know if they could write some guest entries Read More...
Your KMDF driver log can also be available in a mini-dump under certain circumstances. If you have a full kernel dump or a full memory dump, the log will be always present (barring any memory corruption or problems writing out the dump file). KMDF will Read More...
Yesterday I talked about the KMDF log. The KMDF log is a great tool to debug why a DDI call has failed or diagnose the cause of a bugcheck in your driver. You can customize different attributes of the log so that you can better debug your driver. The Read More...
 
Page view tracker