matching (and handling) a whole device and those which match an
interface only. This will allow to enforce some rules, eg that
the former don't use interface information for matching or that the
latter don't modify global device state.
The previous way left too much freedom do the drivers which led to
inconsistencies and abuse.
For now, I've not changed locators and submatch rules, this will
happen later.
There should not be any change in behaviour, except in the case of
some drivers which did behave inconsistently:
if_atu, if_axe, uep: matched the configured device in the interface
stage, but did configuration again. I've converted them to match
in the device stage.
ustir, utoppy: matched in the interface stage, but only against
vendor/device information, and used any configuration/interface
without checking. Changed to match in device stage, and added
some simple code to configure and use the first interface.
If you have one of those devices, please test!
Merge from chap-midi branch, after
~month for review
Comments by thorpej@ drochner@ and Alexandre Ratchov
Incorporated: points by thorpej@ drochner@; preliminary support for
a stats-collecting ioctl suggested by martin@ from comments by A.R.
PR kern/32441 kern/32442 kern/32567 kern/32588 kern/32694 kern/33590
kern/33614 and one instance of kern/32651
ok martin@
within the configuration descriptor, not the class specific interface
descriptor. The Edirol UM-1SX now successfully attaches and works as
a standard USB MIDI interface when the "advanced driver" switch is set
to "off".
- add NULL check to UMQ_ISTYPE; sc_quirk is NULL for genuine umidi, but
forgotten to check. Thus, kernel will panic after connect the device.
- fix how to count the number of endpoints in alloc_all_endpoints_genuine().
- add a quirk for the native mode of UM-880.
- I tested only ROLAND UM-1 and YAMAHA UX256.
These are not conforming to USB-MIDI spec, however these are
similar to USB-MIDI.
- Since I've not yet seen the "genuine" USB-MIDI device,
I cannot test such devices although I wrote the codes for it.
TODO:
- clean up the codes.
- umidi(4) manpage.
- /dev/rmidi? is working well, but /dev/music seems not working correctly.