Commit Graph

85 Commits

Author SHA1 Message Date
augustss
287c3adc4d Update URLs for the HID spec.
(Committed at 36000 feet above the Atlantic on board LH418 using
a broadband satellite connection.)
2003-03-11 16:44:00 +00:00
augustss
9487fc5b8b Make sure we are at splusb() while polling. 2002-10-09 01:02:26 +00:00
simonb
4e3613273b Remove breaks after returns, unreachable returns and returns after
returns(!).
2002-09-23 05:51:10 +00:00
augustss
86650920c9 Get rid of trailing white space. 2002-07-11 21:14:24 +00:00
atatat
31144d9976 Convert ioctl code to use EPASSTHROUGH instead of -1 or ENOTTY for
indicating an unhandled "command".  ERESTART is -1, which can lead to
confusion.  ERESTART has been moved to -3 and EPASSTHROUGH has been
placed at -4.  No ioctl code should now return -1 anywhere.  The
ioctl() system call is now properly restartable.
2002-03-17 19:40:26 +00:00
augustss
152efb1a0e Make a typedef for struct proc to make portingeasier. 2001-12-31 12:15:21 +00:00
augustss
776b0e7851 A little more debug. 2001-12-30 19:37:43 +00:00
augustss
70dea46276 Fix typo. 2001-12-30 19:22:28 +00:00
augustss
3850573d96 Remove garbage. 2001-12-29 18:57:16 +00:00
augustss
750a5959b8 Add some missing scan code translations. Docs from Microsoft via Perry Metzger. 2001-12-29 02:53:41 +00:00
augustss
935b0481a9 Introduce an extra driver level for HID devices, uhidev. This uhidev driver
attaches to the hub, and HID drivers (ums, ukbd, and uhid) attach to
uhidev.  The reason for this change is that some HID devices report multiple
components (like a keyboard and a mouse) using the same interface, but with
different report identifiers.  The report identifier can be specified with
a locator for the HID drivers.
Furthermore, change the ukbd driver to handle other formats than the boot
protocol.
2001-12-28 17:32:36 +00:00
lukem
9f42ccc795 use #ifdef DDB (for consistency with the rest of the kernel) 2001-11-28 05:45:27 +00:00
augustss
b684cbc2a7 usbd_interface2device_handle() cannot fail. 2001-11-15 15:15:58 +00:00
lukem
667807e40c add RCSIDs 2001-11-13 06:24:53 +00:00
augustss
6e85b5b6c5 Add a workaround for broken ports (e.g. macppc) that do not call
cnpollc before cngetc in DDB.  DDB now works with USB console on Macs.

Don't frob the LEDs if nothing changes.
2001-11-07 02:52:47 +00:00
augustss
3deca4b069 Use the usb callout macros. 2001-10-28 16:53:21 +00:00
augustss
80d988187f If we are the console and we have DDB then events must not be delivered
from the interrupt routine since this will enter the USB interrupt
processing recursively during polling.
Now ukbd can be used as console keyboard for DDB!
2001-10-24 21:02:18 +00:00
augustss
5c2ee5ebed Make sure interrupt pipe is closed when detaching console keyboard. 2001-10-24 15:31:06 +00:00
augustss
c5a4cc1291 Only clear the endpoint on stall (from FreeBSD). 2001-09-28 23:42:16 +00:00
augustss
b8cfdb2c1d Allow a UKBD_LAYOUT option to determine the default keyboard layout.
(From OpenBSD.)
2001-04-06 22:54:15 +00:00
jdolecek
522f569810 make some more constant arrays 'const' 2001-02-21 21:39:52 +00:00
augustss
cbda952879 Make sure driver attach/detach events are generated in a consistent manner. 2001-01-23 14:04:13 +00:00
augustss
79f0bd6e1f Update many URLs. 2000-12-29 01:24:55 +00:00
augustss
b3b158b922 Implement handling of the UQ_SPUR_BUT_UP quirk. Some keyboards sometimes
generate a key up quickly followed by a key down for the same key, so we
take care of that.
(Finally I can type again without going nuts. :)
2000-08-20 22:30:17 +00:00
augustss
44c15e95b5 Add two keys to the raw mapping for German keyboards.
From Matthias Kretschmer <McCratch@gmx.net>, fixes PR 10850.
2000-08-17 23:08:07 +00:00
augustss
ed9486e158 Bring the coding style into the 80s, i.e., get rid of __P and use
ANSI prototypes and declarations.
2000-06-01 14:28:57 +00:00
augustss
30c20f930f Change my email address. 2000-04-27 15:26:44 +00:00
augustss
fc72e72d7d Change (almost) all static to Static. The symbol `Static' can then be defined
to `' or `static' depending on if you want to debug or not.
2000-03-27 12:33:53 +00:00
thorpej
fc96443d15 New callout mechanism with two major improvements over the old
timeout()/untimeout() API:
- Clients supply callout handle storage, thus eliminating problems of
  resource allocation.
- Insertion and removal of callouts is constant time, important as
  this facility is used quite a lot in the kernel.

The old timeout()/untimeout() API has been removed from the kernel.
2000-03-23 07:01:25 +00:00
augustss
7d05674ba7 Distinguish between device and interface classes.
(I finally found a document that said that they were different.)
2000-02-29 21:37:00 +00:00
augustss
4b93911b25 Generate usb events on attach and detach. 2000-02-02 13:18:45 +00:00
augustss
c3716a6bb9 Add an argument to usbd_open_pipe_intr() to specify the polling interval
for an interrupt pipe in case we don't what what the descriptor suggests.
2000-01-19 00:23:58 +00:00
augustss
4539a83cdc Add a DPRINTF on keyboard errors. 2000-01-16 09:41:22 +00:00
augustss
c664f35fc5 Let usbd_set_polling() work on a usbd_device_handle instead of
a usbd_interface_handle.
2000-01-16 09:37:18 +00:00
augustss
8111aaeef9 Cosmetics and a couple of diagnostic messages. 1999-12-06 21:06:59 +00:00
augustss
02faf8d588 Done something half sensible if a USB console keyboard is unplugged instead
of panic()ing.
XXX Untested.  I will test it the next time I can borrow an iMac.
1999-12-01 23:22:57 +00:00
augustss
aa32088c20 Cosmetic changes. 1999-11-26 01:39:27 +00:00
mjacob
5f4088eb26 Hide function definition within ifdef's is becomes active in. 1999-11-12 19:11:25 +00:00
augustss
0d2fabdf26 A number of stylistic changes to increase readability (many suggested
by Nick Hibma):
	use NULL not 0
	declare all local definitions static
	rename s/usbd_request/usbd_xfer/ s/reqh/xfer/
	rename s/r/err/
	use implicit test for no err
	KNF
1999-11-12 00:34:57 +00:00
augustss
03a522d3c1 Merge in a large batch of changes from Nick Hibma <hibma@skylink.it> so
the USB stack compiles on FreeBSD again.
1999-10-13 08:10:55 +00:00
augustss
df435c83b2 Add an event mechanism so that a userland process can watch devices come
and go.
1999-10-12 11:54:56 +00:00
augustss
305998532f Dot't forget to deactivate subdevices. 1999-09-12 08:21:49 +00:00
augustss
24251055bc Change the way the `struct device' base part of all driver softc are
declared and accessed to make it more portable.  Idea from Nick Hibma, FreeBSD.
No functional changes.
1999-09-05 19:32:18 +00:00
augustss
f3421bec94 Change the way the direction is extracted from the endpoint descriptor.
No functional changes to the drivers.  From Nick Hibma, FreeBSD.
1999-09-04 22:26:11 +00:00
augustss
036a9c6974 Change some 'struct device' to 'bdevice'. From FreeBSD. 1999-08-28 21:42:35 +00:00
augustss
1f2661798f Make sure to mark the device as dying already in the (de)activate routine.
This avoids access to it before the detach routine has blown it away.
1999-08-23 22:55:14 +00:00
augustss
b8b1e35ece Some changes from FreeBSD (no functional differences). 1999-08-14 14:49:31 +00:00
augustss
4047458551 More DIAGNOSTIC messages. 1999-07-24 01:40:19 +00:00
augustss
b177c7a397 Totally redo the way device detach is done. It now uses a kernel event
thread and the config detach method.
Squish a number of space leaks on detach.
1999-06-30 06:44:22 +00:00
augustss
701eca7576 Remove unneeded #include. 1999-06-26 03:14:25 +00:00