Commit Graph

3257 Commits

Author SHA1 Message Date
haad
543e3d0539 Add HL-340 usb2Serial addapter. 2008-10-22 10:35:50 +00:00
haad
b392ebc9c0 I forgot to commit this after regen. 2008-10-22 10:33:20 +00:00
haad
27418aa546 Regen. 2008-10-22 10:27:28 +00:00
haad
49e162a888 Add product/vendor ID for my USB2serial adapter. 2008-10-22 10:23:51 +00:00
jun
3caafa9653 Add
corega K.K CG-WLUSB2GPX
2008-10-21 12:20:44 +00:00
apb
96230fab84 Use ${TOOL_AWK} instead of ${AWK} or plain "awk" in make commands.
Pass AWK=${TOOL_AWK:Q} to shell scripts that use awk.
2008-10-19 22:05:19 +00:00
joerg
7e64fc36e4 Remove two devices that are handled by ubsa and might need special
handling from u3g until further reports. Move a number of data cards
from ugensa to u3g based on the FreeBSD list.
2008-10-19 11:40:02 +00:00
joerg
5519d99b9a Regen. 2008-10-19 11:37:44 +00:00
joerg
74069cabed Sync list of 3G cards with FreeBSD. 2008-10-19 11:36:11 +00:00
joerg
f48b5b12a3 Make u3g send an eject command to Novatel MC950D devices. Explicitly
attach as device for umass mode on MC950D and the Huawei devices to
supersede the umass quirk.
2008-10-18 09:43:44 +00:00
wrstuden
fc7511b00e Merge wrstuden-revivesa into HEAD. 2008-10-15 06:51:17 +00:00
jmcneill
e2728f33e6 ehci_dump_itd and _sitd are unused 2008-10-14 18:32:53 +00:00
jmcneill
b8aea8193c kern/39727: race condition in ehci isoc abort xfer path
From Jeremy Morse:

  * Serialize access to the ehci intrlist.
  * Change the ehci intrlist to a tailq so xfers are not queued out of order.
  * In ehci_check_itd_intr, don't treat a transfer error as an indication
    that the xfer is no longer active.
2008-10-14 18:12:38 +00:00
is
93d402c342 Load firmware from .../firmware/stuirda, not ../uirda, to avoid confusion. 2008-10-13 10:01:24 +00:00
jmcneill
c93dbbaca8 Revert previous. 2008-10-11 13:56:51 +00:00
jmcneill
55c0ca3b69 ehci_check_itd_intr: correct logic for checking for active itds 2008-10-11 05:17:12 +00:00
jmcneill
5b4aed5dc9 If we're not dealing with an interrupt endpoint, invoke the xfer's
callback after calling the xfer's done method to give the device driver
a change to reschedule the same xfer, from FreeBSD.
2008-10-11 05:07:20 +00:00
jakllsch
c53df256ca regen 2008-10-10 23:53:19 +00:00
jakllsch
aaa79600f5 add Pinnacle Systems, Inc. and their PCTV HD Pro Stick (800e)
ok jmcneill
2008-10-10 23:50:39 +00:00
jmcneill
14f8dc1c88 regen 2008-10-10 22:49:30 +00:00
jmcneill
13371a99c0 Add ATI/AMD TV Wonder 600 and Empia Technology EM2883 product IDs 2008-10-10 22:28:53 +00:00
joerg
db5825abd5 Add u3g(4) driver from FreeBSD. This driver provides better support for
3G datacards than ugensa and will replace the latter for the supported
devices.
2008-10-10 16:37:15 +00:00
joerg
4c43f08c6f Regen. 2008-10-10 16:30:17 +00:00
joerg
fcc58fbfce Add entries for Vodafone Mobile Connect 3G datacard (from FreeBSD)
and for the Novatel 950D.
2008-10-10 16:29:57 +00:00
jmcneill
04fec95922 ehci_free_itd: use LIST_INSERT_HEAD rather than
LIST_INSERT_AFTER(LIST_FIRST(..), ..) when returning itds to the freelist
to prevent a crash when the freelist is empty. Reviewed by Jeremy Morse.
2008-10-06 02:21:50 +00:00
jmcneill
6c26172841 Fix issue where multi-transaction isoc endpoints were forced to single
transactions, from Jeremy Morse.
2008-10-05 21:31:39 +00:00
wiz
188468ada8 regen. 2008-09-28 15:41:50 +00:00
wiz
e5e4b9c58a Add Zippy Technology Corporation (from www.linux-usb.org/usb.ids). 2008-09-28 15:41:29 +00:00
jmcneill
2941ba2cb6 De-USB_* pseye(4) 2008-09-27 02:47:56 +00:00
ws
0f3b6c479f If you want to test option INET, make sure that it is in sight. 2008-09-24 07:19:18 +00:00
jmcneill
c3641af740 Register with pmf 2008-09-21 19:26:36 +00:00
jmcneill
402497db0a Guard against short bHeaderLength when processing video payload 2008-09-21 19:22:21 +00:00
freza
8f5a2d0c69 Make it compile with DPRINTFs disabled. 2008-09-21 18:20:03 +00:00
jmcneill
614d391b35 Discard frames with header lengths larger than we expect them to be.
Use USBD_NO_COPY and no timeout with the bulk transfer. uvideo(4)
works on EeePC now.
2008-09-21 17:58:05 +00:00
jmcneill
30ecaca828 UVC bulk endpoint support, from myself, mjf, and a bottle of vodka. Mostly
works, doesn't handle stream errors properly yet.
2008-09-21 14:13:24 +00:00
freza
e7607938e4 Use M_80211_NODE for 'zyd_node' allocation instead of M_DEVBUF. 2008-09-21 09:38:27 +00:00
jmcneill
d911baed67 Fix reversed test in uvideo_init_control, from Patrick Mahoney 2008-09-20 21:05:58 +00:00
jmcneill
47d8270f89 Add UYVY support. 2008-09-20 18:17:56 +00:00
jmcneill
205dac9d2c Use probe/GET_MAX to determine wCompQuality value during negotiation 2008-09-20 15:55:38 +00:00
jmcneill
d9c8a20dcc Print uDWord types with %u instead of %d 2008-09-20 14:01:27 +00:00
jmcneill
e8af03099d uvideo_set_format: perform a probe/SET, probe/GET before commit/SET instead
of relying on the information in probe/GET to be already valid.
2008-09-19 12:14:53 +00:00
jmcneill
4a1f40c8ab Remove qcm driver definition that slipped in accidentally on the previous
commit, pointed out by cegger
2008-09-19 11:29:35 +00:00
jmcneill
db5b771d07 Add pixel format selection support. 2008-09-19 00:05:02 +00:00
jmcneill
b11aea36cc Add support for video mode selection, and protect isoc xfer shutdown
with splusb
2008-09-18 23:20:52 +00:00
jmcneill
ee916aba93 Fix kmod support. 2008-09-18 21:52:41 +00:00
jmcneill
f93a860daa Properly calculate nframes for isoc xfers, and skip uvc payloads with
a length of 0, from Matthias Drochner.
2008-09-18 17:47:09 +00:00
jmcneill
7174577ba3 defflag UVIDEO_DEBUG 2008-09-18 16:40:37 +00:00
jmcneill
f1fc481694 For now, select default format in uvideo_open. Makes ekiga happy. 2008-09-18 13:34:56 +00:00
jmcneill
bd78ec5c6b * Use determined default format based on descriptors rather than relying on
GET_DEF, as this is probably not what is wanted.
* Don't select an alternate interface with max packet size > 1024
2008-09-18 04:37:06 +00:00
jmcneill
f2b05f5e15 Uncomment code accidentally commented out in the last commit. 2008-09-18 02:57:07 +00:00
jmcneill
88913084de Allow for multiple simultaneous isoc xfers to be in progress at a time,
to reduce the chance of data loss.
2008-09-18 02:49:00 +00:00
jmcneill
548abe3d13 Note where the magic register information came from in this driver. No
functional change.
2008-09-17 03:57:19 +00:00
martin
6b8ff81d70 Remove hardcoded vendor/product ID based lookup for HX type chips and
decide based on the device descriptor instead. Simplifies things a
lot and fixes PR 39457.
2008-09-16 20:00:17 +00:00
mjf
0074b883b4 Fix pseye_start_transfer() to return the return value of kthread_create()
instead of always returning 0.
2008-09-13 18:51:10 +00:00
jmcneill
9397047d32 QuickCam Messenger: Set UQ_BAD_ADC quirk so uaudio will attach. The device
reports bcdADC == 0x200, but the microphone otherwise works fine.
2008-09-10 20:34:40 +00:00
jmcneill
f196dae5e9 regen 2008-09-10 20:07:46 +00:00
jmcneill
0470da95e3 Logitech QuickCam Messenger 2008-09-10 20:04:56 +00:00
cegger
41812eebff update TODO list: we have isoc support 2008-09-10 06:08:27 +00:00
hubertf
07d9131246 Sign over copyright of Jeremy Morse's code to TNF, OK'd by Jeremy Morse
(still mention Jeremy as contributor)
2008-09-09 21:51:32 +00:00
jmcneill
426e852b45 register with pmf 2008-09-09 17:40:40 +00:00
cegger
9153a46c8f make this build w/o UVIDEO_DEBUG 2008-09-09 05:44:08 +00:00
jmcneill
c08044b7db USB Video Class capture device driver, part of Patrick Mahoney's Google
Summer of Code 2008 project.
2008-09-09 01:13:42 +00:00
jmcneill
78974094d6 Clarify the message printed by the kernel when a low or full speed
device with isochronous endpoints is attached to a hi-speed hub. Also
silence a printf in ehci_device_isoc_close
2008-09-09 00:46:45 +00:00
jmcneill
51d385aeea No need for videoio.h in hw driver 2008-09-09 00:19:10 +00:00
jmcneill
6ea027b866 Run pseye_transfer_thread at a higher priority to ensure that we don't
receive partial frames in our bulk xfer.
2008-09-08 22:28:53 +00:00
jmcneill
dd848685c1 Implement try_format 2008-09-08 22:13:26 +00:00
jmcneill
94e5d88f48 Implement enum_format callback. 2008-09-07 17:12:21 +00:00
rmind
913f159e82 Regen. 2008-09-06 21:53:32 +00:00
rmind
aa93fc3fa8 PR/37948: Yojiro UO: Support for Sony GPS GPS-CS1 devices. Check the support
of UR_BBB_GET_MAX_LUN, and disable the logic, if needed.
2008-09-06 21:49:00 +00:00
rmind
3f36b1dd77 PR/38202: Jeff McMahill: Support for Sealevel SeaPORT+4 USB to Serial adaptor. 2008-09-06 21:42:05 +00:00
rmind
0474b30708 PR/39303: Izaac: Support for Novatel Wireless Ovation U727. 2008-09-06 21:38:44 +00:00
rmind
5c8acba58c PR/39147: Jasper Wallace: Support Metageek Wispy 2.4x as ugen device. 2008-09-06 21:34:49 +00:00
jmcneill
6902ca74cd Add driver for the Sony PLAYSTATION(R) Eye USB webcam. 2008-09-06 19:37:21 +00:00
matt
15f84f36ad Regen. 2008-08-30 03:29:56 +00:00
matt
3358bb85e1 Add some more usb devices that the updated if_axe.c supports. 2008-08-30 03:27:48 +00:00
drochner
6ea9cc30bf add a "break" so that the isoc setup code doesn't access uninitialized
data if the frames allocated by a client driver don't use up all the
microframes within a frame
2008-08-28 23:08:00 +00:00
jmcneill
fc513621ad Ignore HID and audio interfaces on iPhone, iPod Touch, and iPhone 3G. Maybe
we'll have better luck driving it with ugen(4)..
2008-08-28 21:43:11 +00:00
jmcneill
d722f149b1 Regen. 2008-08-28 21:41:51 +00:00
jmcneill
42ecdc8c24 Add iPhone, iPod Touch, and iPhone 3G product IDs. 2008-08-28 21:41:19 +00:00
matt
b10d12581a Regen. 2008-08-22 03:23:30 +00:00
matt
0793292db9 Add APPLE ETHERNET 2008-08-22 03:22:25 +00:00
drochner
8991542aa2 use M_NOWAIT in an early allocation for consistency, from Kevin Lo 2008-08-21 12:25:03 +00:00
kent
fb5a41ad3a Implement uhub_rescan(). After this change, "modload uaudio.kmod"
configures an audio device correctly for a device which is already
plugged.

* usb_subr.c
 Add locators parameter to usbd_attachinterfaces()
 Add usbd_reatach_device()

* usbdivar.h
 Export usbd_reatach_device()
2008-08-18 18:03:21 +00:00
cegger
6746e5563f regen. 2008-08-18 11:49:34 +00:00
cegger
64fb7cf189 add Cherry 6000 keyboard 2008-08-18 11:48:23 +00:00
drochner
d564f76750 fix my last commit: add missing "break"s, from Marcus Glocker 2008-08-16 15:41:37 +00:00
drochner
fdb6ecdb00 free memory on detach, fixes memory leak, from Andreas Jacobs per
PR kern/39322
2008-08-13 09:43:56 +00:00
drochner
a1d4089483 fix an off-by-one in isochronous interval check, and streamline some
frame / microframe calculation, avoiding overestimation of frames needed,
reviewed by Jared D. McNeill
2008-08-12 16:35:06 +00:00
drochner
95effdc79e fix an inconsistency in a check for invalid configuration index vs. value;
noticed by Frank Wille in PR kern/39211, but unrelated to the problem
described (The check can practically never be hit.)
2008-08-12 16:30:42 +00:00
cegger
6223c57814 make i386 ALL kernel compile 2008-08-03 07:05:22 +00:00
jmcneill
cd4f8360bb High speed isochronous transfer support, from Jeremy Morse as part of
Google Summer of Code 2008.
2008-08-02 23:14:34 +00:00
jmcneill
c4b944ba64 Update copyright. 2008-08-02 22:57:36 +00:00
jmcneill
4e6a458107 High speed isochronous support, from Jeremy Morse as part of Google
Summer of Code 2008.
2008-08-02 22:23:18 +00:00
drochner
551e75d811 -ubsa needs to be attached as whole device on USB, because it sets
the configuration. The match/attach code was assuming whole-device
 attach args all the time.
-Use the first (ie index 0) configuration for ubsa -- it makes the
 code work in at least one case (PR kern/39211 by Frank Wille), and
 there is no indication that an alternative configuration would
 be needed. (I've admittedly never seen a usb device with more than
 one configuration.)
This fixes mistakes when uhmodem support was added, and the changes were
not tested with a Huawei device yet. So please test if you can.
2008-07-31 22:01:15 +00:00
drochner
6a47db887e -in usbd_probe_and_attach(), split out the code for per-device and
per-interface attachment into individual functions, to ease
 maintainance and allow easier plugin of new attachment functions
-keep a counter of USB interfaces in use on a device, and try to
 keep track of interfaces claimed by drivers behind the framework's
 back
2008-07-28 15:22:01 +00:00
drochner
3126a6b09b Don't pmf_device_deregister() if it was not registered, which happens
if attach() encountered an error before.
In contrast, such a protection should not be needed for the register()
call, so remove it there.
2008-07-28 14:19:26 +00:00
plunky
86cf58d587 remove comment that is no longer true 2008-07-26 20:16:10 +00:00
tonnerre
232e862b92 Don't ignore poor retarded ubt(4) devices which have vendor and product id
== 0. Discovered by mballmer@obsd, ok'd by plucky@.
2008-07-16 08:43:01 +00:00
gmcgarry
bdd7de96c7 Constify most umidi-quirk data. Addresses PR#39017. 2008-07-08 11:34:43 +00:00
uebayasi
83bda9894d Regen. 2008-07-08 08:55:22 +00:00
uebayasi
42185747e6 WILLCOM Advanced W-ZERO3[es] device IDs. From Ryo Shimizu. 2008-07-08 08:47:32 +00:00
uebayasi
36662bbc30 Add a device ID seen in Kojinsha notebook. From Ryo Shimizu. 2008-07-08 08:44:55 +00:00
bouyer
efe8b350b3 Add appropriate bus_dmamap_sync() calls to uhci(4), ohci(4) and ehci(4),
as proposed on tech-kern@.
While all DMA memory used in the USB framework is mapped BUS_DMAMAP_COHERENT
(including data memory, which is memcpy'd from/to USB-private buffers),
the CPU can reorder loads or stores from/to main memory, causing the
controller to have an incoherent view of the DMA descriptors lists for a
short time. bus_dmamap_sync() should contain memory barriers that prevents
the CPU from reordering load/store. Note that BUS_DMAMAP_COHERENT is
still required for the DMA descriptor lists - these can't work properly
with software cache coherency.
This fixes "host controller process error/host controller halted" errors
I'm occasionally seeing with a umodem device on uhci on x86.
Thanks to Michael Lorenz for testing it on his O2, and Izumi Tsutsui on
his Cobalt Qube 2700.
2008-06-28 17:42:53 +00:00
kent
eadd4f5dcf Make uaudio compilable as a kmod.
XXX:
"modload uaudio.kmod" doesn't attach the uaudio driver to
plugged USB devices for now because uhub_rescan() is not
implemented yet.  We need to re-plug USB devices after modload.
2008-06-28 09:14:56 +00:00
kent
b46d745a05 We don't need to include opt_usbverbose.h here. 2008-06-28 09:06:20 +00:00
drochner
04fc7d252f kill some abuse of __strong_alias which is not compatible with
split device/softc, this might fix crashes on umodem disconnect
reported by some people (eg PR kern/39050 from Matthias Pfaller)
2008-06-27 16:05:59 +00:00
jmcneill
8ac9fcb0d7 PR 39023: usbd_new_device: do not set address early, from FreeBSD. 2008-06-22 21:31:51 +00:00
jmcneill
b0ef7c658c Regen for Sony PLAYSTATION(R) Eye 2008-06-22 17:46:01 +00:00
jmcneill
64c6729ddb Add entry for Sony PLAYSTATION(R) Eye 2008-06-22 17:45:45 +00:00
jmcneill
065296bfe0 USB video class definitions, from Patrick Mahoney for GSoC 2008. 2008-06-18 14:20:31 +00:00
drochner
dd989679ec -plug a minimal memory leak on attach/detach
-avoid unnecessary tree walks and port status requests:
 -acknowledge hub status change notifications (but do nothing)
 -clear cached port status change bits earlier (but not on ehci, due
  to an ehci driver bug)
-do the ehci check on attach rather than a string comparision at runtime
2008-06-16 10:37:54 +00:00
drochner
94d328c85c fix selective port resume signaling (not used in normal operation,
just for correctness)
2008-06-16 10:29:41 +00:00
drochner
ad077b5aaa oops, forgot to pass locators when I simplified the autoconf code 2008-06-06 17:52:02 +00:00
jmcneill
06fd33749e uhci_device_intr_done: when re-queueing, pass pipe direction to
uhci_alloc_std_chain instead of always 1 (read). ok drochner
2008-06-06 11:21:16 +00:00
nonaka
0591571b21 Added missing splx() at ohci_resume(). 2008-06-04 12:38:58 +00:00
bouyer
17471e2294 Fix probable cut-n-paste error: make the virtual QH link match the physical
one. The effect of this was just that the virtual list missed the
chsqh entry, it only shows up when looking at debug outputs.
2008-06-02 20:53:29 +00:00
jmcneill
e09ade91de Set sc_suspend properly so we can avoid a potential HCH on resume. 2008-06-02 01:02:21 +00:00
jmcneill
5e10ee6416 PR kern/38774: cosmetic typo in umidireg.h: SubType/Subtype, from
Patrick Mahoney
2008-05-28 12:59:30 +00:00
drochner
0936812690 kill USB_DO_ATTACH 2008-05-27 20:46:16 +00:00
drochner
1f3341612f minor unifdef and cleanup, no functional change 2008-05-27 20:44:28 +00:00
drochner
a87b5494b4 Fix a dereference if a softc pointer which can legally be zero, leading
to a crash reported by Christoph Egger in a followup to PR kern/38528.
For consistency, keep track of the device_t pointer to child devices
rather than the softc. We really shouldn't mess with child's softc data.
2008-05-26 19:01:51 +00:00
drochner
736f4fcd27 some cleanup:
-unifdef
-since the roothub attach doesn't use locators, don't call
 config_stdsubmatch() -- it is a no-op in that case
-ifsubmatch has configuration and interface always set to useful values,
 remove unnecessary checks
-remove now unused locator definitions from shared header
2008-05-26 18:00:33 +00:00
jmcneill
07b705df60 Cleanup, use pmf, and ensure that we keep the device active in the
non-pearl case where power is sufficient.
2008-05-26 03:20:56 +00:00
jmcneill
b14ecf8e05 Don't match uberry to a device in dual mode, let umass pick it up instead. 2008-05-26 03:03:50 +00:00
christos
2b96eb7243 Add uberry, a stub driver for RIM BlackBerry devices that can only be used
to charge a BlackBerry on a USB port.
2008-05-26 00:23:05 +00:00
drochner
f8b26260d9 -make the list of USB child devices a (possibly sparse) array rather
than a zero-terminated list; this makes the code simpler and also
 hopefully fixes the recent "childdet" botch, see PR kern/38528
-handle the root hub specially a bit earlier, this allows to kick out
 the "submatch" functions completely which needed to second-guess
 from the port number (where "0" meant root hub")
 (we could handle the root hub specially even earlier, but as done
 now big parts of the hub emulation code are exercised regularely,
 this would bitrot otherwise)
2008-05-25 21:41:35 +00:00
cegger
09d5e20c11 make this build with USSCANNER_DEBUG 2008-05-25 07:04:10 +00:00
cube
400ce55d62 Use ether_nonstatic_aton() when appropriate. 2008-05-24 17:35:37 +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
dyoung
0089c8a0c9 Cosmetic: good-bye, excessive #ifdef'age. 2008-05-22 01:21:18 +00:00
drochner
26a4d5b843 fix argument to usb_setup_reserve() (called from USB host adapter drivers)
to be device_t consistently, from Quentin Garnier
2008-05-21 17:19:44 +00:00
ghen
41f841e610 Add support for the Colemak keyboard layout variant, see http://colemak.com 2008-05-21 07:39:24 +00:00
cegger
31dfb0cf52 regen. 2008-05-11 06:44:16 +00:00
cegger
6cc82eadea add Garmin Forerunner 305, GPS clock device 2008-05-11 06:42:47 +00:00
mlelstv
8944a89578 Use NODOORLOCK quirk to make iBead MP3 players work.
Fixes PR kern/23875.
2008-05-11 05:20:33 +00:00
jmcneill
729313d52c Use 2-clause license. 2008-05-05 00:12:49 +00:00
martin
ce099b4099 Remove clause 3 and 4 from TNF licenses 2008-04-28 20:22:51 +00:00
ad
992544b3e9 Fix build error. 2008-04-27 22:34:49 +00:00
nakayama
fbdd1b7ea8 Fix typo.
s/amrr_min_success_threshold/amrr_max_success_threshold/ in second line.
2008-04-27 09:32:08 +00:00
ad
6d70f903e6 Network protocol interrupts can now block on locks, so merge the globals
proclist_mutex and proclist_lock into a single adaptive mutex (proc_lock).
Implications:

- Inspecting process state requires thread context, so signals can no longer
  be sent from a hardware interrupt handler. Signal activity must be
  deferred to a soft interrupt or kthread.

- As the proc state locking is simplified, it's now safe to take exit()
  and wait() out from under kernel_lock.

- The system spends less time at IPL_SCHED, and there is less lock activity.
2008-04-24 15:35:27 +00:00
jmcneill
de45d1c96b Cleanup uhub autoconfiguration messages. 2008-04-21 23:31:18 +00:00
cegger
a76bb1857c regen. 2008-04-21 21:18:59 +00:00
cegger
a9cad030a2 Phison Electronics, vendor of my USB Stick 2008-04-21 21:17:51 +00:00
cegger
86537ae77c sprintf -> snprintf 2008-04-10 19:49:14 +00:00
cegger
395c8c3fd3 use aprint_*_dev and device_xname 2008-04-05 16:35:35 +00:00
drochner
42de29841b restore error handling in usbopen() (accidentally removed in a recent
commit), should fix a crash reported by Arto Huusko
2008-04-03 14:07:01 +00:00
xtraeme
e3c537a961 Fix previous commit, this Guillemot model was supported already
by rum(4).
2008-04-01 15:26:11 +00:00
xtraeme
1da8284de3 Match another Guillemot model, reported by J. Vicente Carrasco
in private email.
2008-03-30 16:19:55 +00:00
ad
3e4bd28ac8 Defer USB configuration until interrupts are enabled. 2008-03-30 15:37:49 +00:00
nakayama
136678d875 Fix ohci brokenness in previous commit. 2008-03-29 02:20:41 +00:00
drochner
fd0ded75ed split device/softc for USB host controllers and the usb (control)
device,
this is hairy stuff, and I've only tested with uhci/ehci at pci,
please test the rest and report problems
2008-03-28 17:14:45 +00:00
drochner
8e182b07db remove FreeBSD/OpenBSD sections, cross-platform support hasn't been
maintained for a while
2008-03-28 17:10:30 +00:00
ichiro
9aa0df1bf3 add device 'E620'on Vodafone.
It was tested on Vodafone by Mihai Chelaru <kefren@NetBSD.org>
and works perfectly.
2008-03-27 04:13:23 +00:00
cube
b1be269fbd Split device_t and softc for atapibus(4). 2008-03-24 14:44:26 +00:00
elric
d670789a3d Moved USB_PRODUCT_NOVATEL2_MERLINV620 into the UNTESTED section as the
man page indicated that it is untested.  Fixed some whitespace issues.
2008-03-17 02:43:56 +00:00
elric
4b299d47e7 Made a number of modifications, including:
1.  fixed a bug where the last bulk in/out was chosen rather
	    than the first.  This got my Sierra AC 595 working,

	2.  reworked some of the match logic to include flags for the
	    matches,

	3.  defined a flag UNTESTED which causes a warning to be output,

	4.  added product/vendor IDs from other OSes (OpenBSD, FreeBSD,
	    Linux) but marked them UNTESTED.
2008-03-17 02:40:04 +00:00
elric
394d344d7a Add a number of products which will be supported in ugensa(4).
Most of these are experimental and the product/vendor IDs are
snarfed from OpenBSD, FreeBSD and Linux.
2008-03-17 02:37:51 +00:00
ws
27973cf78e Don't leak information from kernel to userland.
(Well, the first 2 changes wouldn't really be neccessary,
however, IMHO this makes it clearer why we don't leak.)
2008-03-08 18:46:18 +00:00
dyoung
9a0e417e90 Use device_t and accessors. Setup power management in the PCI
front-end (XXX needs to look more alike the Cardbus front-end).
Establish the shutdown hook using PMF.
2008-03-07 22:32:52 +00:00
dyoung
347c1a2644 Use device_t and accessors.
In ohci_{pci,cardbus}_attach, do not get the device_t by casting
the softc to void *, but use `self' instead.
2008-03-07 21:48:46 +00:00
dyoung
2e3b67d337 Register the shutdown hook using pmf_device_register1(). 2008-03-07 21:36:51 +00:00
rmind
c6186face4 Welcome to 4.99.55:
- Add a lot of missing selinit() and seldestroy() calls.

- Merge selwakeup() and selnotify() calls into a single selnotify().

- Add an additional 'events' argument to selnotify() call.  It will
  indicate which event (POLL_IN, POLL_OUT, etc) happen.  If unknown,
  zero may be used.

Note: please pass appropriate value of 'events' where possible.
Proposed on: <tech-kern>
2008-03-01 14:16:49 +00:00
rafal
ba7873b58d Add TRIPPLITE2 UPS into the list of devices ignored by uhid(4) -- the UPS
software apparently wants to drive it as a ugen(4) instead.
2008-02-24 20:25:13 +00:00
rafal
570306d6b7 Regen for addition of TRIPPLITE2 UPS. 2008-02-24 20:23:38 +00:00
rafal
c99a7eb6d3 Add another vendor ID for Tripp Lite and product entry for their USB UPS
interface (it appears to be a generic product ID, rather than per-model).
2008-02-24 20:22:06 +00:00
dyoung
cd44c43b28 Add a method to detach child.
Cosmetic: use device_t and accessors.  Use aprint_*_dev().  Use
PMF_FN_{ARGS,CALL,PROTO}.
2008-02-22 23:04:52 +00:00
dyoung
1fa24f5705 Add method to detach children.
Temporary: use PMF_FN_PROTO, PMF_FN_ARGS.
2008-02-22 22:22:27 +00:00
rafal
976dbbc142 Make this work on a new TrippLite USB->Serial Converter Model U209-000-R.
At least rev 3.00 of the device needs the HX hack(s).
2008-02-21 04:38:43 +00:00
mlelstv
f99dbc5c80 fix typo 2008-02-20 15:55:38 +00:00
drochner
33e22165c1 recognize Shantou ADM8515 2008-02-19 10:52:44 +00:00
drochner
52851a2776 regen 2008-02-19 10:51:56 +00:00
drochner
0e9e9e8505 add the Shantou ADM8515 ethernet chip which is in some
"Wintech LanCard" adapter I just got
(USB 2.0 on the label but just full-speed - what a crap)
2008-02-19 10:51:07 +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
smb
585d42043e Patch from Jared McNeill to prevent USB interrupt storms on resume on
Thinkpad T61.  (Note: to prevent a very similar-seeming problem, T61
users should also install firmware 2.06 or later, according to thinkwiki.)
2008-02-13 00:52:44 +00:00
mlelstv
20eb004e2e Add some initialization magic from FreeBSD. This makes it work with
the more recent PL2303 revision 4.
2008-02-12 22:29:54 +00:00
drochner
b399335799 add NULL power handler, so that this device doesn't block suspension 2008-02-12 19:37:51 +00:00
ichiro
bb98e5cd32 regen. 2008-02-11 02:23:32 +00:00
ichiro
f5c8edbfe7 add new device support to uhmodem driver
PR/37985 from Yojiro UO
2008-02-11 02:23:09 +00:00
dyoung
2ccede0a9c Start patching up the kernel so that a network driver always has
the opportunity to handle an ioctl before generic ifioctl handling
occurs.  This will ease extending the kernel and sharing of code
between drivers.

First steps:  Make the signature of ifioctl_common() match struct
ifinet->if_ioctl.  Convert SIOCSIFCAP and SIOCSIFMTU to the new
ifioctl() regime, throughout the kernel.
2008-02-07 01:21:52 +00:00
drochner
d9459c5f21 share some code for USB root hub emulation which is common in the 3
host controller implementations, start with two little functions
which fake up string descriptors (which were inconststent, language
table fetching didn't interoperate with other code in the tree)
2008-02-03 10:57:11 +00:00
tron
ce82b598ec Add support for function keys F16 to F19 as present on e.g. the new
Apple aluminum keyboard.

Patch contributed by Michael Piotrowski in PR kern/37788, reviewed
by Matthias Drochner.
2008-01-29 20:54:32 +00:00
jmcneill
ef5ded9b39 No need to operate in polling mode in ehci_resume. 2008-01-28 20:58:23 +00:00
jmcneill
05b25a6836 Ensure that we don't clear the EHCI_PS_CLEAR bits by writing 1s to them
when modifying port state in ehci_suspend and ehci_resume.
2008-01-28 01:52:31 +00:00
jmcneill
e4e10d4f97 Release port ownership on detach, so devices will be routed to companion
controllers. This allows 'drvctl -d ehci0' to disable USB 2.0 mode.
2008-01-28 00:47:05 +00:00
jmcneill
b6294fbf32 Add some USB EHCI Legacy Support Extended CSR bit definitions. 2008-01-27 20:06:48 +00:00
ad
632e64ed4e lockmgr() not used here, remove ref to it. 2008-01-25 20:39:28 +00:00
jmcneill
a06bac7d44 Speed up uhub attachment considerably. Rather than powering up each port
individually then waiting for it to become stable, power them up all
at once and then delay. Don't even bother delaying if we are a root hub,
as this is handled separately in the event thread. From OpenBSD.
2008-01-25 00:29:12 +00:00
ichiro
2e9fa9fff0 make compile 2008-01-21 12:16:31 +00:00
ichiro
c6061e7174 change umass quirks logic in USB_MATCH()
PR/37687 from Yojiro UO
2008-01-21 12:11:21 +00:00
ichiro
817e003a02 add full support device driver for Huawei E220 wireless modem
PR/37692 from Yojiro UO
---
uhmodem: device driver for huawei 3G wireless modem

* what it is?

A device driver for huawei 3G wireless modem, E220 and its valiations.

The devices are very simuler to ubsa device, but they need special care
to use as modem device.
This patch introduce "uhmodem (USB Huawei modem)" for the devices.
A uhmodem device has two com devices and one USB mass strage device.
The driver enable to use all of them.

* dmesg:
uhmodem0 at uhub0 port 1 configuration 1 interface 0
uhmodem0: HUAWEI Technologies HUAWEI Mobile, rev 1.10/0.00, addr 2
uhmodem0: mass storage only mode, reattach to enable modem
uhmodem0: at uhub0 port 1 (addr 2) disconnected
uhmodem0 detached
uhmodem0 at uhub0 port 1 configuration 1 interface 0
uhmodem0: HUAWEI Technologies HUAWEI Mobile, rev 1.10/0.00, addr 2
ucom0 at uhmodem0 portno 0: modem
ucom1 at uhmodem0 portno 1: monitor
umass0 at uhub0 port 1 configuration 1 interface 2
umass0: HUAWEI Technologies HUAWEI Mobile, rev 1.10/0.00, addr 2
umass0: using SCSI over Bulk-Only
scsibus0 at umass0: 2 targets, 1 lun per target
cd0 at scsibus0 target 0 lun 0: <HUAWEI, Mass Storage, 2.31> cdrom removable
2008-01-21 11:36:46 +00:00
dyoung
b480b62270 Make many ethernet drivers share the common code for MII media
handling, ether_mediastatus() and ether_mediachange().  Check for
a non-ENXIO error return from mii_mediachg().  (ENXIO indicates
that a PHY is suspended.)

This patch shrinks the source code size by 979 lines.  There was
a 5100-byte savings on the NetBSD/i386 kernel configuration, ALL.

I have made a few miscellaneous changes, too:

gem(4): use LIST_EMPTY(), LIST_FOREACH().
mtd(4): handle media ioctls, for a change!
axe(4): do not track link status in sc->axe_link any longer
nfe(4), aue(4), axe(4), udav(4), url(4): do not reset all PHYs
        on a change of media

Except for the change to mtd(4), no functional changes are intended.

XXX This patch affects more architectures than I can feasibly
XXX compile and run.  I have compiled macppc, sparc64, i386.  I
XXX have run the patches on i386 boxen with bnx(4) and sip(4).
XXX Compiling and running on evbmips (MERAKI, ADM5120) is in
XXX progress.
2008-01-19 22:10:14 +00:00
is
257a88e757 Move from workqueue to an explicit kthread for setting the multicast
filter, as suggested by cube@. Actual code review by cube@.
This way, a backport of the fix to netbsd-4 is possible.
2008-01-16 12:33:54 +00:00
cube
55f21981d9 workqueue(9) has the non-evident limitation that the caller cannot reuse
the same struct work before workqueue(9) has internally started to work on
the task.

So to make sure that doesn't happen, provide a semaphore not to run the
workqueue multiple times.  It might be clearer just skip using workqueue(9)
and use a thread for about everything, but oh well, I leave that to
someone else.

Now is@ can yank his USB-to-Ethernet adapter while the interface is up.
2008-01-12 22:32:51 +00:00
gdt
1424adf410 Support FIONBIO.
Support non-blocking reads from USB printers.  With this, escputil can
query the printer model, and I can print a test page with gutenprint
5.1 and cups.   Add many comments explaining why the support is not
quite right.  (This change is quite a bit less invasive than a
"correct" fix, and thus more reasonable to pull up to netbsd-4.)

Rototill debugging, so that all DPRINTFN have a level, and so that the
message is printed if the debug level is >= the number in the source
code.  Document debug level plan.

Fix bug where only one status change would be printed (by inspection,
not tested).

Document scheme for reading/discarding data when ulpt(4) is opened for
write only.

Delete dead code.

Plan and patch posted on tech-kern without objections.
2008-01-08 00:58:09 +00:00
ad
0664a0459b Start detangling lock.h from intr.h. This is likely to cause short term
breakage, but the mess of dependencies has been regularly breaking the
build recently anyhow.
2008-01-04 21:17:40 +00:00
smb
0cb6d977ab Add calls to pmf_deregister on detach. 2008-01-04 03:56:47 +00:00
smb
1d2e422408 Add pmf register/deregister to ucom and ugensa. (Addtionally, let a
Sierra wireless card be recognized as a ugensa.)
2007-12-30 21:49:47 +00:00
perry
b6a2ef7569 Convert many of the uses of __attribute__ to equivalent
__packed, __unused and __dead macros from cdefs.h
2007-12-25 18:33:32 +00:00
smb
34da33dfe3 Add missing call to pmf_deregister() in the USB_DETACH routine. 2007-12-24 14:41:19 +00:00
dyoung
6f3852fab4 Constify struct ifnet->if_sadl and every use throughout the tree.
Add if_set_sadl() that both sets the link-layer address length and
replaces the current link-layer address with a new one, and use it
throughout the tree.
2007-12-20 21:08:17 +00:00
christos
f54e064ee9 add null pmf handlers. 2007-12-16 19:01:35 +00:00
mjf
e3aec4fc22 Regen. 2007-12-15 12:51:59 +00:00
mjf
cd86b0a3cf Add the vendor eMPIA Technology and add the built-in USB camera that is
found on the EEEpc.
2007-12-15 12:50:12 +00:00
lukem
456279df8f use __KERNEL_RCSID() 2007-12-11 12:29:11 +00:00
lukem
961afe5035 use __KERNEL_RCSID() instead of __RCSID() 2007-12-11 12:16:34 +00:00
jmcneill
8eeb638b73 Register with pmf 2007-12-11 03:45:57 +00:00
smb
9428ee68f7 Add Sierra 5725 miniPCI wireless card (CDMA EVDO) 2007-12-09 21:26:47 +00:00
smb
8167a34333 Correct error in 5725 commit 2007-12-09 21:24:30 +00:00
smb
38fba18e22 Add Sierra 5725 mini-PCI card 2007-12-09 21:21:21 +00:00
jmcneill
4c1d81b2b5 Merge jmcneill-pm branch. 2007-12-09 20:27:42 +00:00
pooka
4e38160d4d Do not "return 1" from kqfilter for errors. That value is passed
directly to the userland caller and results in a mysterious EPERM.
Instead, return EINVAL or something else sensible depending on the
case.
2007-12-05 17:19:46 +00:00
ad
6874e511b7 lockmgr -> mutex 2007-12-05 07:58:29 +00:00
ad
5a24480bf8 lockmgr -> mutex 2007-12-05 07:15:53 +00:00
jmcneill
490542edae aprintify, on behalf of xtraeme 2007-12-01 23:40:28 +00:00
jmcneill
a0d3b0d7a8 aprintify 2007-12-01 14:35:51 +00:00
jmcneill
4fbe23fdd0 aprintify 2007-12-01 04:50:50 +00:00
xtraeme
f59c58fb50 regen 2007-11-29 21:08:19 +00:00
xtraeme
0970ce7295 Typo in previous s/HDSPA/HSDPA/ 2007-11-29 21:07:59 +00:00
xtraeme
0976f2f104 regen 2007-11-29 18:38:43 +00:00
xtraeme
88696b51e4 Add support for Novatel Wireless HSDPA Modem to ugensa(4), patch
from Marcin Michal Jessa... thanks.
2007-11-29 18:38:22 +00:00
plunky
736a9db087 Clean up the way that bluetooth drivers attach to the bluetooth stack,
to remove the frobbing that drivers must do in the hci_unit structure.

- driver provides a static const interface descriptor
- hci_unit is allocated by hci_attach() rather than part of softc
- statistics are compiled by driver and provided on request
- driver provides output methods and is responsible for output queue
- stack provides input methods and is responsible for input queue
- mutex is used to arbitrate device queue access
2007-11-28 20:16:11 +00:00
kiyohara
3bf7c476ac + Add COREGA CG-WLUSB2GL and ABOCOM WUG2700.
+ make sure ni->ni_txrate is always initialized to a meaningful value by
  redefining ic->ic_newassoc.
  this should prevent "bogus xmit rate" panics when operating in HostAP
  mode.
+ s/RT2573_[TR]X_LIST_COUNT/RUM_[TR]X_LIST_COUNT/
+ Restore the workaround for rate==0 bug.
+ http://www.ralinktech.com/ domain name is for sale.
  use official url instead: http://www.ralinktech.com.tw/
2007-11-25 09:30:10 +00:00
kiyohara
e18f7bdc36 Regen. 2007-11-25 09:17:56 +00:00
kiyohara
b18c0cc551 Add COREGA CG-WLUSB2GL. 2007-11-25 09:16:49 +00:00
sborrill
12e455f905 Some manufacturers use the same vendor and product id for different devices.
We need to sanity check the DeviceClass in this case.

Currently known guilty products:
0x050d/0x0121 Belkin Bluetooth and USB2LAN

If this turns out to be more common, we could use a quirk table.
2007-11-20 10:43:01 +00:00
ad
dc26833bb6 - Factor out too many copies of the same bit of tty code.
- Fix another tty signalling/wakeup problem.
2007-11-19 18:51:36 +00:00
gson
944c1349c7 Set sc_dying on attach failure so that a subsequent open won't cause a
crash.  Fixes kern/36476.
2007-11-16 15:21:42 +00:00
ad
9bf7522dd1 Call ttwakeup() with tty_lock held. 2007-11-12 14:20:40 +00:00
plunky
7cca9485cc convert device printf() usages to aprint_xxxx() 2007-11-11 12:59:02 +00:00
plunky
0b799668fb use more device_t and device_xxx() accessors
make bluetooth stack keep device_t instead of softc pointer as
device is not necessarily part of softc, and pass device_t to
driver callbacks. hci_devname is no longer required.
2007-11-10 23:12:22 +00:00
ad
0f8b0df960 Call ttyflush() with tty_lock held. 2007-11-10 18:29:36 +00:00
plunky
ed67784932 remove #include <usbhid.h> as its not needed 2007-10-25 19:32:15 +00:00
degroote
0e9691e3e3 Fix a number of driver which doesn't check wep flag in *_tx_mgt.
It is incorrect because we need to encrypt some management frame in case of
shared authentification.
2007-10-21 17:03:37 +00:00
ad
a2a3828545 machine/{bus,cpu,intr}.h -> sys/{bus,cpu,intr}.h 2007-10-19 11:59:34 +00:00
xtraeme
ee740853d7 regen 2007-10-14 01:09:00 +00:00
xtraeme
fe47e4a5cf umidi(4) entries plus quirks for Roland UA25, UA4FX and SonicCell.
Submitted by DHOYASHIKI Shinichi via PR kern/36834.
2007-10-14 01:08:35 +00:00
ad
46ed8f7d77 Use the softint API. 2007-10-08 16:18:02 +00:00
veego
d7415fbd43 Add support to ignore hid attachments for some devices, right now MGE and
APC UPS devices.
No objections on tech-kern at the end of June 2007
Patch is from PR kern/31884
2007-10-03 15:01:28 +00:00
plunky
2e43d32311 fix typo : -> ; 2007-10-02 05:53:47 +00:00
plunky
0327efae31 clean up activate function 2007-10-02 05:38:06 +00:00
mlelstv
33b1e31ca5 Regen 2007-09-22 08:37:33 +00:00
mlelstv
40f327bf0a Add different models of the i-Bead Musicstick 2007-09-22 08:37:01 +00:00
mlelstv
1d76013c7f Regen. 2007-09-22 07:42:12 +00:00
mlelstv
7842ee46ad Another UMTS device from Option N.V. 2007-09-22 07:41:29 +00:00
mlelstv
43bf615b6b Add config information for uslsa(4) to the list 2007-09-22 07:40:19 +00:00
mlelstv
50c43c7f9f Regen. 2007-09-16 10:53:28 +00:00
mlelstv
3d9a003a8b add product code for Huawei E220 HSDPA USB Modem 2007-09-16 10:51:14 +00:00
riz
ed3a102d07 Remove a comment that is no longer true - this driver does, in fact,
support multiple serial ports.
2007-09-13 21:01:48 +00:00
gson
a74fd1b8dc Fix typo in comment 2007-09-09 16:35:13 +00:00
plunky
086f1f09f5 fix misleading comment 2007-09-08 07:46:13 +00:00