aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/usb/ucomvar.h
Commit message (Collapse)AuthorAgeFilesLines
* Move usb to a graveyard location under sys/legacy/dev, it is intended that theAndrew Thompson2009-02-231-169/+0
| | | | | | | | | | new USB2 stack will fully replace this for 8.0. Remove kernel modules, a subsequent commit will update conf/files. Unhook usbdevs from the build. Notes: svn path=/head/; revision=188939
* Move the code that injects received characters into the tty system intoPoul-Henning Kamp2008-12-141-0/+1
| | | | | | | | a separate public function ucomrxchars(), to avoid requirement of simple metadata prefixing on the USB data stream. Notes: svn path=/head/; revision=186091
* Replace all calls to minor() with dev2unit().Ed Schouten2008-09-271-3/+3
| | | | | | | | | | | | | | | | | | After I removed all the unit2minor()/minor2unit() calls from the kernel yesterday, I realised calling minor() everywhere is quite confusing. Character devices now only have the ability to store a unit number, not a minor number. Remove the confusion by using dev2unit() everywhere. This commit could also be considered as a bug fix. A lot of drivers call minor(), while they should actually be calling dev2unit(). In -CURRENT this isn't a problem, but it turns out we never had any problem reports related to that issue in the past. I suspect not many people connect more than 256 pieces of the same hardware. Reviewed by: kib Notes: svn path=/head/; revision=183397
* Keep track of the active buffer on output. For the moment, panic ifWarner Losh2008-09-051-0/+1
| | | | | | | | | | | | | the device indicates that it wasn't able to write all the data in the buffer out. Ed Schouten doesn't like the idea of a panic here. I think for production code, we need something better. For right now, while we're trying to assess the impact of this issue, a panic is OK. So complain to me, not him if this is hit. Notes: svn path=/head/; revision=182800
* Integrate the new MPSAFE TTY layer to the FreeBSD operating system.Ed Schouten2008-08-201-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The last half year I've been working on a replacement TTY layer for the FreeBSD kernel. The new TTY layer was designed to improve the following: - Improved driver model: The old TTY layer has a driver model that is not abstract enough to make it friendly to use. A good example is the output path, where the device drivers directly access the output buffers. This means that an in-kernel PPP implementation must always convert network buffers into TTY buffers. If a PPP implementation would be built on top of the new TTY layer (still needs a hooks layer, though), it would allow the PPP implementation to directly hand the data to the TTY driver. - Improved hotplugging: With the old TTY layer, it isn't entirely safe to destroy TTY's from the system. This implementation has a two-step destructing design, where the driver first abandons the TTY. After all threads have left the TTY, the TTY layer calls a routine in the driver, which can be used to free resources (unit numbers, etc). The pts(4) driver also implements this feature, which means posix_openpt() will now return PTY's that are created on the fly. - Improved performance: One of the major improvements is the per-TTY mutex, which is expected to improve scalability when compared to the old Giant locking. Another change is the unbuffered copying to userspace, which is both used on TTY device nodes and PTY masters. Upgrading should be quite straightforward. Unlike previous versions, existing kernel configuration files do not need to be changed, except when they reference device drivers that are listed in UPDATING. Obtained from: //depot/projects/mpsafetty/... Approved by: philip (ex-mentor) Discussed: on the lists, at BSDCan, at the DevSummit Sponsored by: Snow B.V., the Netherlands dcons(4) fixed by: kan Notes: svn path=/head/; revision=181905
* split out tty create part of ucom_attach into ucom_attach_tty soSam Leffler2008-03-251-0/+1
| | | | | | | | | | derived drivers can use it Submitted by: Jared Go MFC after: 3 weeks Notes: svn path=/head/; revision=177623
* Eliminate usb_thread_t.Warner Losh2007-06-121-1/+1
| | | | Notes: svn path=/head/; revision=170617
* More removing compatibility macros.Warner Losh2006-09-071-1/+1
| | | | | | | | | md5 still the same. "Dave, stop. I feel my mind slipping away." -- hal Notes: svn path=/head/; revision=162097
* Start each of the license/copyright comments with /*-, minor shuffle of linesWarner Losh2005-01-061-1/+1
| | | | Notes: svn path=/head/; revision=139749
* Use generic infrastructure for the ucom driver instead of local stuff.Poul-Henning Kamp2004-09-281-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | This changes the naming of USB serial devices to: /dev/ttyU%d and /dev/cuaU%d for call-in and call-out devices respectively. (Please notice: capital 'U') Please also note that we now have .init and .lock devices for USB serial ports. These are not persistent across device removal. devd(8) can be used to configure them on attachment time. These changes also improve the chances of the system surviving if the USB device is unplugged at an inconvenient time. At least we do not rip things apart while there are any threads in the device driver anymore. Remove cdevsw, rely on the tty generic one. Don't make_dev(), use ttycreate() which does all the magic. In detach, do close procesing if we ripped things apart while the device was open. Call ttyfree() once we're done cleaning up. Notes: svn path=/head/; revision=135907
* Overhaul ucom serial driver by using generic stuff instead of homerolledPoul-Henning Kamp2004-09-171-16/+0
| | | | | | | all over the place. Notes: svn path=/head/; revision=135379
* Pick the hotchar out of the tty structure instead of caching privatePoul-Henning Kamp2004-06-261-1/+0
| | | | | | | | | | | copies. No current line disciplines have a dynamically changing hotchar, and expecting to receive anything sensible during a change in ldisc is insane so no locking of the hotchar field is necessary. Notes: svn path=/head/; revision=131134
* Do the dreaded s/dev_t/struct cdev */Poul-Henning Kamp2004-06-161-1/+1
| | | | | | | Bump __FreeBSD_version accordingly. Notes: svn path=/head/; revision=130585
* Replace the FOO_DEBUG definitions with USB_DEBUG, and switch theJosef Karthauser2002-07-311-6/+0
| | | | | | | | | debugging levels to off by default. Now that debug levels can be tweaked by sysctl we don't need to go through hoops to get the different usb parts to produce debug data. Notes: svn path=/head/; revision=101060
* Add a USB comm driver.Josef Karthauser2002-03-181-0/+189
Ported from NetBSD by: akiyama Notes: svn path=/head/; revision=92603