Questions tagged [wdf]

Windows Driver Foundation (WDF) is a set of Microsoft tools that aid in the creation of device drivers for Windows 2000 and later versions of Windows

The Windows Driver Frameworks (WDF) is a:

  1. Software Model to create Windows drivers
  2. Runtime Environment that manages WDF-based Windows drivers

It consists of KMDF and UMDF for drivers to run in kernel and user mode respectively.

111 questions
2
votes
1 answer

WDF UMDF driver install problem in windows 7 32 bit

I have a simple user mode usb driver that is installing and working fine in Windows XP 32 bit and Windows 7 64 bit, but for some reason fails to install correctly in Windows 7 32 bit. Do I need 2 separate drivers for XP 32bit and win7 32bit? I was…
Marinara54uc3
  • 73
  • 1
  • 7
2
votes
1 answer

Calling WDF driver from c++

I've been trying to call a sample driver. I have written DriverEntry method, where I initialize both the driver name and symbolic ling pointing to the driver. // UNICODE_STRING DriverName, SymbolName; // Driver registry paths ... // Driver…
Lone Wanderer
  • 160
  • 4
  • 15
2
votes
0 answers

Linker error when compiling windows kernel mode driver x64

I'm trying to compile the sysvad audio driver example found here: https://github.com/Microsoft/Windows-driver-samples/tree/master/audio/sysvad Getting a linker error when compiling windows kernel mode driver x64 error LNK2019: unresolved external…
Nick
  • 2,735
  • 1
  • 29
  • 36
2
votes
1 answer

Windows sample driver builds properly but will not install,

I don't know if this is the right place to ask, since its technically not a programming question, but it conecerns driver development so anyway: For a school assignment I have to take a look at the code of a WDF sample driver. (And change it a…
Omnomnomnom
  • 153
  • 1
  • 8
2
votes
1 answer

WinDBG: How to get the underlying FILE_OBJECT from a WDFFILEOBJECT handle?

I'm having a WDFFILEOBJECT handle(0x0000057fedd9b8b8), and I want to know its underlying FILE_OBJECT address, so that I can use !object xxxx to query the FILE_OBJECT's .PointerCount and .HandleCount. What windbg command can I use? !wdfkd.wdfhandle…
Jimm Chen
  • 3,411
  • 3
  • 35
  • 59
2
votes
1 answer

WDF EvtIoDeviceControl buffer lengths

When handling DeviceIoControl requests in a WDF driver what is the correct way to get the size of the input/output buffer. It seems to be both passed as a parameter: VOID EvtIoDeviceControl(IN WDFQUEUE Queue, IN WDFREQUEST Request, …
Freddie Witherden
  • 2,369
  • 1
  • 26
  • 41
2
votes
0 answers

How does HidD_GetAttributes retrieve the attributes from a Device Object?

I'm working on creating a virtual HID device in Windows 10. To prepare myself for writing the drivers, I've been analyzing the sample provided here: https://github.com/Microsoft/Windows-driver-samples/tree/master/hid/vhidmini2. In the file…
bacowan
  • 165
  • 2
  • 12
2
votes
1 answer

Two Spinlocks on same processor?

Can two CPUs hold two "different" spin locks simultaneously at same time? So...does this mean: a sigle(uniprocessor) CPU cannot hold two "different" spinlocks at the same time? So...does this mean: the number of spinlocks on a single CPU cannot be…
bakra
  • 387
  • 4
  • 15
2
votes
1 answer

How to modify Mouse Input WDF Filter Driver (Moufiltr) to work for USB mice?

This filter driver example works well for PS2 devices, but I couldn't figure out how to make it work for USB mice on x64. Any ideas? Is this an INF file question? Or will code changes be necessary, too?
maf-soft
  • 2,335
  • 3
  • 26
  • 49
2
votes
0 answers

How to uniquely identify user processes which have opened handle to my kmdf driver?

In my KMDF driver, i want to uniquely identify which process has opened a handle to the driver using CreateFile. Is there a way to do this using any WdfXXX() call?
Nishanth
  • 43
  • 6
2
votes
0 answers

windows driver load dependencies in INF file

My UMDF driver (myUMDF.dll) has dependency on one KMDF driver (someKMDF.sys) which is installed through separate INF file. In my INF file, I want to set dependencies that myUMDF.dll will ONLY be installed once someKMDF.sys driver is already…
2
votes
1 answer

Force USB High Speed EHCI 2.0 hub to enumerate as Full Speed UHCI/OHCI device

In Windows XP SP3 is there a registry key or some setting, maybe even at the device level in the registry, that an EHCI USB 2.0 High Speed hub can be enumerated as a UHCI or OHCI full speed device at the host level? I am seeing an issue where a USB…
Preston
  • 2,543
  • 1
  • 17
  • 26
2
votes
2 answers

Waiting for vertical blank in kernel mode?

I'm writing a driver that needs synchronization with vertical blank interrupt to send some data down the USB pipe. In user-mode there are Direct X functions available for this like IDXGIOutput::WaitForVBlank and few older ones. I am not able to use…
kurczak
  • 1,521
  • 1
  • 10
  • 18
2
votes
1 answer

CreateFile doesn't prevents other processes from opening my device

I'm using CreateFile to open a connection to my USB hardware. If I have two (or more) hardwares connected to the PC I would like to prevent several instances (different PIDs) of my PC-application to connect to the very same hardware. I thought this…
user872661
  • 251
  • 2
  • 13
1
vote
0 answers

KMDF Driver INF file error KMDF: 1280 and 1212

This is my current Code: [Version] Signature="$WINDOWS NT$" Class=%ClassName% ClassGuid={78A1C341-4539-11d3-B88D-00C04FAD5171} Provider=%ProviderName% CatalogFile=hidriver.cat DriverVer=01/07/2018 PnpLockdown =…
VodkaFree
  • 11
  • 1