aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/uart/uart_tty.c
Commit message (Collapse)AuthorAgeFilesLines
* This commit was manufactured by cvs2svn to create tagrelease/6.0.0_cvscvs2svn2005-11-031-1/+1
| | | | | | 'RELENG_6_0_0_RELEASE'. This commit was manufactured to restore the state of the 6.0-RELEASE image.
* In uart_cnprobe(), fill in the cn_name field of the consdev structure.Marcel Moolenaar2005-05-081-0/+1
| | | | | | | | | | | | | | The core console code checks this field when a console is added and emits a warning if it's empty. In practice the warning is harmless for uart(4), because the cn_name is filled in as soon as the device name is known; which is when the device is enumerated. To avoid the warning, to avoid possible complications caused by emitting the warning without there (possibly) being a console selected yet and to avoid complications when the UART isn't found during bus enumeration, we just preset the cn_name field here to the name of the driver. Notes: svn path=/head/; revision=146013
* Start each of the license/copyright comments with /*-, minor shuffle of linesWarner Losh2005-01-061-1/+1
| | | | Notes: svn path=/head/; revision=139749
* Remove asserts which are not correct if the port is a tty.Poul-Henning Kamp2004-10-121-7/+1
| | | | Notes: svn path=/head/; revision=136453
* Use generic tty code instead of (comparatively little) local copies.Poul-Henning Kamp2004-10-121-170/+52
| | | | Notes: svn path=/head/; revision=136421
* Use tty->t_sc to find out softc.Poul-Henning Kamp2004-09-181-8/+6
| | | | Notes: svn path=/head/; revision=135429
* Use ttyalloc() instead of ttymalloc(NULL)Poul-Henning Kamp2004-09-171-1/+1
| | | | Notes: svn path=/head/; revision=135367
* Preparation commit for the tty cleanups that will follow in the nearPoul-Henning Kamp2004-07-151-2/+2
| | | | | | | | | | | | future: rename ttyopen() -> tty_open() and ttyclose() -> tty_close(). We need the ttyopen() and ttyclose() for the new generic cdevsw functions for tty devices in order to have consistent naming. Notes: svn path=/head/; revision=132226
* Define the tty methods as typedefs.Poul-Henning Kamp2004-06-301-2/+1
| | | | | | | | | Change the return type for t_break to void. Add t_ioctl (more about this later). Notes: svn path=/head/; revision=131373
* Use generic support for BREAK and modem control ioctls.Poul-Henning Kamp2004-06-251-65/+27
| | | | Notes: svn path=/head/; revision=131095
* Use the new serial port definitions for modemsignals.Poul-Henning Kamp2004-06-241-29/+29
| | | | Notes: svn path=/head/; revision=131043
* save a few redundant lines by moving the retry loop further backwards.Poul-Henning Kamp2004-06-231-7/+1
| | | | Notes: svn path=/head/; revision=130969
* Do the dreaded s/dev_t/struct cdev */Poul-Henning Kamp2004-06-161-3/+3
| | | | | | | Bump __FreeBSD_version accordingly. Notes: svn path=/head/; revision=130585
* Machine generated patch which changes linedisc calls from accessingPoul-Henning Kamp2004-06-041-8/+8
| | | | | | | | | linesw[] directly to using the ttyld...() functions The ttyld...() functions ar inline so there is no performance hit. Notes: svn path=/head/; revision=130077
* Make the remaining serial drivers call ttyioctl() rather than callingPoul-Henning Kamp2004-06-041-5/+2
| | | | | | | the linedisc directly. Notes: svn path=/head/; revision=130057
* Device megapatch 4/6:Poul-Henning Kamp2004-02-211-1/+2
| | | | | | | | | | | Introduce d_version field in struct cdevsw, this must always be initialized to D_VERSION. Flip sense of D_NOGIANT flag to D_NEEDGIANT, this involves removing four D_NOGIANT flags and adding 145 D_NEEDGIANT flags. Notes: svn path=/head/; revision=126080
* Device megapatch 3/6:Poul-Henning Kamp2004-02-211-4/+0
| | | | | | | | | | | | | | | Add missing D_TTY flags to various drivers. Complete asserts that dev_t's passed to ttyread(), ttywrite(), ttypoll() and ttykqwrite() have (d_flags & D_TTY) and a struct tty pointer. Make ttyread(), ttywrite(), ttypoll() and ttykqwrite() the default cdevsw methods for D_TTY drivers and remove the explicit initializations in various drivers cdevsw structures. Notes: svn path=/head/; revision=126078
* Use standard style for cdevsw initializtionPoul-Henning Kamp2004-02-141-9/+9
| | | | Notes: svn path=/head/; revision=125809
* Test the return value of UART_PARAM(). Invalid line parameters did notMarcel Moolenaar2004-02-141-1/+2
| | | | | | | | | | result in an error before. PR: kern/60284 Submitted by: Thomas Sandford <freebsduser@paradisegreen.co.uk> Notes: svn path=/head/; revision=125797
* Don't explicitly initialize d_maj in the cdevsw with MAJOR_AUTO, asMarcel Moolenaar2003-09-281-1/+0
| | | | | | | | per the intentions of conf.h, rev 1.176. This change is a no-op as MAJOR_AUTO equals to 0. Notes: svn path=/head/; revision=120558
* Catch up with the console interface change: the use of makedev() hasMarcel Moolenaar2003-09-261-3/+2
| | | | | | | | | | been abandoned in favor of a (device) name-based approach. Submitted by: phk Tested on: alpha Notes: svn path=/head/; revision=120487
* Add support for using uart(4) for pulse capturing for the Pulse PerMarcel Moolenaar2003-09-111-2/+9
| | | | | | | | | | | | | | | Second (PPS) timing interface. The support is non-optional and by default uses the DCD line signal as the pulse input. A compile-time option (UART_PPS_ON_CTS) can be used to have uart(4) use the CTS line signal. Include <sys/timepps.h> in uart_bus.h to avoid having to add the inclusion of that header in all source files. Reviewed by: phk Notes: svn path=/head/; revision=119996
* The uart(4) driver is an universal driver for various UART hardware.Marcel Moolenaar2003-09-061-0/+569
It improves on sio(4) in the following areas: o Fully newbusified to allow for memory mapped I/O. This is a must for ia64 and sparc64, o Machine dependent code to take full advantage of machine and firm- ware specific ways to define serial consoles and/or debug ports. o Hardware abstraction layer to allow the driver to be used with various UARTs, such as the well-known ns8250 family of UARTs, the Siemens sab82532 or the Zilog Z8530. This is especially important for pc98 and sparc64 where it's common to have different UARTs, o The notion of system devices to unkludge low-level consoles and remote gdb ports and provides the mechanics necessary to support the keyboard on sparc64 (which is UART based). o The notion of a kernel interface so that a UART can be tied to something other than the well-known TTY interface. This is needed on sparc64 to present the user with a device and ioctl handling suitable for a keyboard, but also allows us to cleanly hide an UART when used as a debug port. Following is a list of features and bugs/flaws specific to the ns8250 family of UARTs as compared to their support in sio(4): o The uart(4) driver determines the FIFO size and automaticly takes advantages of larger FIFOs and/or additional features. Note that since I don't have sufficient access to 16[679]5x UARTs, hardware flow control has not been enabled. This is almost trivial to do, provided one can test. The downside of this is that broken UARTs are more likely to not work correctly with uart(4). The need for tunables or knobs may be large enough to warrant their creation. o The uart(4) driver does not share the same bumpy history as sio(4) and will therefore not provide the necessary hooks, tweaks, quirks or work-arounds to deal with once common hardware. To that extend, uart(4) supports a subset of the UARTs that sio(4) supports. The question before us is whether the subset is sufficient for current hardware. o There is no support for multiport UARTs in uart(4). The decision behind this is that uart(4) deals with one EIA RS232-C interface. Packaging of multiple interfaces in a single chip or on a single expansion board is beyond the scope of uart(4) and is now mostly left for puc(4) to deal with. Lack of hardware made it impossible to actually implement such a dependency other than is present for the dual channel SAB82532 and Z8350 SCCs. The current list of missing features is: o No configuration capabilities. A set of tunables and sysctls is being worked out. There are likely not going to be any or much compile-time knobs. Such configuration does not fit well with current hardware. o No support for the PPS API. This is partly dependent on the ability to configure uart(4) and partly dependent on having sufficient information to implement it properly. As usual, the manpage is present but lacks the attention the software has gotten. Notes: svn path=/head/; revision=119815