Calling the host per-driver isn’t meaningful since you can have multiple drivers loaded on a device.
Prior to UMDF 1.11 (Windows 8) each device node got its own host. Your driver would regularly be split across hosts. We’ve received few complaints about this from anyone who wasn’t looking at memory usage of UMDF devices.
Starting with Windows 8 we pool devices into a single host by default. This is to reduce footprint as we get more user-mode drivers on smaller systems. Because this means a bad driver can take down more devices, we have a process for isolating a crashing device off into its own host that involves splitting the pool up and then coalescing it again over time (as hosts naturally restart).
When debugging and/or deploying through VS, our default behavior is to run the drivers being deployed in their own host so as to avoid noise, and to keep you from losing stable drivers when your driver under test crashes.
So the common case in Windows 8 is that every instance of your driver will load in a single host. But there are cases where it won’t, so relying on that is poor form.
You can override the default pooling behavior if you must. See http://msdn.microsoft.com/en-us/library/windows/hardware/hh463993(v=vs.85).aspx. This means that you’ll be increasing the memory utilization for the system, which may upset your customers if they’re running on, or selling, low-spec devices.
-p
-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of Maxim S. Shatskih
Sent: Wednesday, December 3, 2014 12:01 PM
To: Windows System Software Devs Interest List
Subject: Re:[ntdev] One instance of UMDF device
But now I *am* starting to wonder. So, in UMDF 2, if I call
WdfDriverCreate and specify a context
In other words: is the running WUDFHost instance per-driver? or per-device?
–
Maxim S. Shatskih
Microsoft MVP on File System And Storage xxxxx@storagecraft.com http://www.storagecraft.com
NTDEV is sponsored by OSR
Visit the list at: http://www.osronline.com/showlists.cfm?list=ntdev
OSR is HIRING!! See http://www.osr.com/careers
For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars
To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer