Commit Graph

63 Commits

Author SHA1 Message Date
cegger 8c2b3a39bc make this compile 2009-01-11 10:58:26 +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
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
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
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
gson a74fd1b8dc Fix typo in comment 2007-09-09 16:35:13 +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 53524e44ef Kill caddr_t; there will be some MI fallout, but it will be fixed shortly. 2007-03-04 05:59:00 +00:00
christos 168cd830d2 __unused removal on arguments; approved by core. 2006-11-16 01:32:37 +00:00
christos 4d595fd7b1 - sprinkle __unused on function decls.
- fix a couple of unused bugs
- no more -Wno-unused for i386
2006-10-12 01:30:41 +00:00
christos ad4f70a8e8 add missing initializer. 2006-09-03 21:30:24 +00:00
thorpej 39cd836ee1 Use device_unit(). 2006-03-28 17:38:24 +00:00
christos 95e1ffb156 merge ktrace-lwp. 2005-12-11 12:16:03 +00:00
ws 9d78e0cf36 PR-30566: Poll must not return <sys/errno.h> values.
Start with those places I can easily test.
2005-06-21 14:01:11 +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
perry f31bd063e9 nuke trailing whitespace 2005-02-27 00:26:58 +00:00
itojun 300aa0dcd5 use bounded string ops (snprintf, strl*) 2004-04-23 17:25:25 +00:00
augustss 92bc86cdb6 Add Epson Perfection 1670 scanner 2004-03-15 11:09:23 +00:00
augustss 5f31dab3df Add more scanners. 2004-01-05 13:29:49 +00:00
augustss 7686442d28 Add more scanners. From FreeBSD. 2003-11-23 19:07:10 +00:00
fvdl d5aece61d6 Back out the lwp/ktrace changes. They contained a lot of colateral damage,
and need to be examined and discussed more.
2003-06-29 22:28:00 +00:00
darrenr 960df3c8d1 Pass lwp pointers throughtout the kernel, as required, so that the lwpid can
be inserted into ktrace records.  The general change has been to replace
"struct proc *" with "struct lwp *" in various function prototypes, pass
the lwp through and use l_proc to get the process pointer when needed.

Bump the kernel rev up to 1.6V
2003-06-28 14:20:43 +00:00
wiz 902dd8b54d Undo last (not supposed to be committed). 2003-01-27 00:32:44 +00:00
wiz b091df0ed2 regen (CANOSCAN N670U). 2003-01-27 00:31:01 +00:00
augustss 61f5ebcc50 Add Epson Perfection 2400. From kern/19856, Rob Quinn. 2003-01-15 13:35:55 +00:00
tron a7bc8e6057 Add support for Epson Perfection 1260. 2003-01-13 21:51:30 +00:00
augustss 7d481b8bc1 Add Epson 1660. From kerm/19767, Neil Short. 2003-01-10 11:06:58 +00:00
christos 514f7047e4 si_ -> sel_ 2002-11-26 18:49:40 +00:00
jdolecek e0cc03a09b merge kqueue branch into -current
kqueue provides a stateful and efficient event notification framework
currently supported events include socket, file, directory, fifo,
pipe, tty and device changes, and monitoring of processes and signals

kqueue is supported by all writable filesystems in NetBSD tree
(with exception of Coda) and all device drivers supporting poll(2)

based on work done by Jonathan Lemon for FreeBSD
initial NetBSD port done by Luke Mewburn and Jason Thorpe
2002-10-23 09:10:23 +00:00
simonb 4e3613273b Remove breaks after returns, unreachable returns and returns after
returns(!).
2002-09-23 05:51:10 +00:00
gehenna 77a6b82b27 Merge the gehenna-devsw branch into the trunk.
This merge changes the device switch tables from static array to
dynamically generated by config(8).

- All device switches is defined as a constant structure in device drivers.

- The new grammer ``device-major'' is introduced to ``files''.

	device-major <prefix> char <num> [block <num>] [<rules>]

- All device major numbers must be listed up in port dependent majors.<arch>
  by using this grammer.

- Added the new naming convention.
  The name of the device switch must be <prefix>_[bc]devsw for auto-generation
  of device switch tables.

- The backward compatibility of loading block/character device
  switch by LKM framework is broken. This is necessary to convert
  from block/character device major to device name in runtime and vice versa.

- The restriction to assign device major by LKM is completely removed.
  We don't need to reserve LKM entries for dynamic loading of device switch.

- In compile time, device major numbers list is packed into the kernel and
  the LKM framework will refer it to assign device major number dynamically.
2002-09-06 13:18:43 +00:00
augustss 92826242e2 Add a scanner (from OpenBSD). 2002-07-14 20:53:21 +00:00
augustss 86650920c9 Get rid of trailing white space. 2002-07-11 21:14:24 +00:00
augustss 81779a3b41 Add another scanner. 2002-06-18 00:32:30 +00:00
simonb 819efe9017 Recognise the HP ScanJet 2200c as a scanner, tested with xsane. 2002-05-12 08:04:41 +00:00
augustss f1274a71dc Some minor fixes from FreeBSD. 2002-02-11 10:09:14 +00:00
augustss 152efb1a0e Make a typedef for struct proc to make portingeasier. 2001-12-31 12:15:21 +00:00
augustss dd4b4280f7 Add new scanners to the table.
(The scanners don't actually have to work to be in the uscanner table,
this is how Linux does it and uscanner is just there because Linux has it.)
2001-12-30 11:13:22 +00:00
gehenna 7a22165e1c fix product ID 2001-12-30 05:12:36 +00:00
augustss 0a4d7b9de3 Add a scanner quirk for keeping the pipes open between device opening.
Idea from Enami.
2001-12-12 15:48:18 +00:00
augustss 02aa2a59bc Handle vendor/product lookup with a common routine. 2001-12-03 01:47:12 +00:00
enami e69c410de5 Shorten wmesg so that they can be distinguished in ps/top output. 2001-12-01 09:42:39 +00:00
enami 71651851a4 Match against EPSON GT-9700F. 2001-11-23 10:31:54 +00:00
lukem 667807e40c add RCSIDs 2001-11-13 06:24:53 +00:00
augustss 9ec0bc09c1 Add Epson 1650. 2001-10-11 12:05:10 +00:00
augustss cafdfc900c Add Epson 640U. From Chris Baird <cjb@brushtail.apana.org.au> 2001-10-07 22:30:33 +00:00
thorpej a5aff000fc Match the UMAX Astra 3400. 2001-10-05 00:31:06 +00:00
augustss 72a04bd497 Add HP 3400. 2001-04-19 00:47:49 +00:00
augustss f994193bf7 Add Epson 1240. 2001-04-01 14:50:58 +00:00