[wdmaudiodev] Re: audio driver questions

  • From: Tim Roberts <timr@xxxxxxxxx>
  • To: wdmaudiodev@xxxxxxxxxxxxx
  • Date: Wed, 26 Aug 2009 17:28:00 -0700

Tim Newsham wrote:
> Either I'm not understanding your answer or you're not understanding
> my question.  Let me try to rephrase:  If I want to have two devices,
> one acting as a master and one as a slave such that the master acts as
> a bus driver and causes new slaves to appear in the system, how can I
> connect these two driver objects together such that they can share
> data structures and call into each others private functions?  If the
> two are separately loaded drivers would I be limited to communicating
> between them with standard channels such as by using device iocontrol
> messages?

You are correct  -- I did not interpret your question this way.

Once the child device is loaded, it can send a private ioctl down that
returns whatever you want.  For example, you could return a shared data
structure and an array of pointers, like a C++ pure virtual object (a
pseudo-COM interface).  There's a PnP minor IRP that is defined for this
purpose, but you can do whatever you want in an internal ioctl.

If both drivers live in the same binary, then they can certainly call
the same functions, although you'd need to be careful about tracking
which device object was which.

Tim Roberts, timr@xxxxxxxxx
Providenza & Boekelheide, Inc.


WDMAUDIODEV addresses:
Post message: mailto:wdmaudiodev@xxxxxxxxxxxxx
Subscribe:    mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=subscribe
Unsubscribe:  mailto:wdmaudiodev-request@xxxxxxxxxxxxx?subject=unsubscribe
Moderator:    mailto:wdmaudiodev-moderators@xxxxxxxxxxxxx


Other related posts: