Opening a miniport device from inside a driver

Here’s an interesting one. I have a miniport audio device, which is a wave cyclic device, it’s almost identical to the MSVAD_Simple device in the WDK samples. I need to open this device from inside another driver, and pass an IOCTL (or, let’s say, a command of some sort) into it.

Now, this is a hypothetical scenario, and please predict what will happen.

From the AddDevice() routine in my miniport, I want to create an additional device which isn’t the one being currently added, so I call IoCreateDevice using the DriverObject that was passed in (to my miniport), and I name this device and symbolically link it into the DOS namespace. So, I think, I now have a named device associated with my miniport driver, which is not actually a miniport device (because it hasn’t been registered with PortClass or anything) and it’s just kind of dangling out there in space.

This new (named) device is a PDO. (Is that a true statement?)

Now - from inside another driver, I want to open this device and pass an ioctl into it. What will happen? Will I be able to open the device using the name assigned? And what will happen when I try to send an ioctl to it?

"Th

> Now, this is a hypothetical scenario, and please predict what will happen.

A blue screen - 70%

This new (named) device is a PDO. (Is that a true statement?)
No, this sort of devices are not PDOs. As a consequence they can only have “legacy” names, not interfaces.

Will I be able to open the device using the name assigned?
It’s likely.

And what will happen when I try to send an ioctl to it?
See above :slight_smile:

–pa