Commit Graph

17 Commits

Author SHA1 Message Date
dyoung
8d5198657e Simplify activation hooks. (sc_dying must die!) 2009-11-12 19:51:44 +00:00
plunky
5fab894c54 fix up USB drivers printing of autoconf information
1. expand the USB_ATTACH_SETUP macro (requested by jmcneill)

2. reorder the attach function so that the first thing it does is print
   newlines.

3. after this, we can call usbd_devinfo_alloc(), which polls the device
   allowing a context switch, and aprint_normal() the device information.

this avoids problems where autoconf messages are getting mixed up.
2009-09-23 19:07:19 +00:00
cube
3624455eba Split device_t and softc for all USB device drivers, and related cosmetic
changes.

Matthias Drochner kindly reviewed this patch, and tested ums, ubt, uaudio
and ral.  I tested umass myself.
2008-05-24 16:40:58 +00:00
martin
ce099b4099 Remove clause 3 and 4 from TNF licenses 2008-04-28 20:22:51 +00:00
dyoung
0b1dce29ae Use device_t and its accessor functions.
Register _childdetached methods with drivers that attach children.
Wait to set child references to NULL there, instead of doing that
in the detach method.

Replace many uses of USB_DECLARE_DRIVER() with CFATTACH_DECL2().
2008-02-18 05:24:24 +00:00
drochner
8258b792b7 Introduce different autoconf interface attributes for USB drivers
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!
2007-03-13 13:51:53 +00:00
christos
95e1ffb156 merge ktrace-lwp. 2005-12-11 12:16:03 +00:00
augustss
834327c847 Don't keep the devinfo string on the stack, instead use malloc/free.
This should cure some rare stack overflows.
2005-05-11 10:02:28 +00:00
yamt
18f717bb90 constify audio_hw_if, midi_hw_if, and radio_hw_if. 2004-10-29 12:57:15 +00:00
itojun
300aa0dcd5 use bounded string ops (snprintf, strl*) 2004-04-23 17:25:25 +00:00
augustss
86650920c9 Get rid of trailing white space. 2002-07-11 21:14:24 +00:00
tron
f1a2d1c420 Remove obsolete prototype for "udsbr_search". 2002-02-12 10:51:49 +00:00
augustss
6f566032d7 Whitespace changes. 2002-02-11 11:42:16 +00:00
augustss
501071c88f Correct the frequency calculation. 2002-01-03 21:52:26 +00:00
augustss
71dd2d73a6 Fix typos. 2002-01-02 03:47:35 +00:00
augustss
1d26d9e5fd Move debug define.
Remove some cruft.
Update with some stuff from Warner Losh's driver.
2002-01-02 03:44:56 +00:00
augustss
f63f2e4dfe Add udsbr(4), a D-Link DSB-R100 FM radio (untested). 2002-01-02 03:21:36 +00:00