[wdmaudiodev] Re: Bug in usbaudio.sys (XP SP1 as well as SP2) MIDI support

  • From: Tim Roberts <timr@xxxxxxxxx>
  • To: wdmaudiodev@xxxxxxxxxxxxx
  • Date: Mon, 22 Nov 2004 09:05:42 -0800

BlazeAudio Developer wrote:

We have found a rather significant bug in USBAUDIO.SYS that involves USB MIDI support.

The problem is that if a lower filter is attached (below usbaudio.sys), then sysaudio fails to create the CATEGORY_AUDIO_DEVICE filters. And the reason sysaudio fails is that the pins created by usbaudio for MIDI cannot not provide a proper pin name.

After about three days of debugging, and stepping through a fair amount of usbaudio and sysaudio code, we have found the reason for this.

The reason is that Usbaudio.sys tries to obtain the device description of the PDO that it is working on using IoGetDeviceProperty() with DevicePropertyDeviceDescription.

If there is no lower-filter for usabaudio, then this works fine.

However, if there is a lower-filter present, then usbaudio is actually trying to make this call on the Filter Device Object (FiDO) that it thinks is the PDO.


That's interesting, because there was an almost identical bug in the Win98 Gold version of STREAM.SYS. It tried to open the registry key for the next driver down to read naming information, but it used the FiDO instead of the PDO. The bug made it impossible to use a lower filter with any stream-class driver, including USBAUDIO.SYS.

We actually shipped three drivers which patched STREAM.SYS on the fly for this problem.

--
- 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

URL to WDMAUDIODEV page:
http://www.wdmaudiodev.de/

Other related posts: