Commit Graph

12 Commits

Author SHA1 Message Date
Andrew Turner
405ada37fb Add support for the uart classes to set their default register shift value.
This is needed with the pl011 driver. Before this change it would default
to a shift of 0, however the hardware places the registers at 4-byte
addresses meaning the value should be 2.

This patch fixes this for the pl011 when configured using the fdt. The
other drivers have a default value of 0 to keep this a no-op.

MFC after:	1 week
2015-04-11 17:16:23 +00:00
Ian Lepore
3bb693af87 Move the uart_class definitions and fdt compat data into the individual
uart implementations, and export them using the new linker-set mechanism.

Differential Revision:	https://reviews.freebsd.org/D1993
Submitted by:	Michal Meloun
2015-03-07 15:24:15 +00:00
Ian Lepore
0dc54d18b2 Use the FIFOs in the imx5/imx6 uart hardware instead of interrupting on
each byte sent or received.
2014-10-12 17:56:02 +00:00
Ian Lepore
c3f0f2847f Return the actual baud rate programmed in the hardware rather than 115200.
This allows the "3wire" entry in /etc/ttys (with no speed specified) to work.
2014-09-30 23:01:11 +00:00
Ian Lepore
49d0a4c3ff Reword a comment block a bit; no functional changes. 2014-04-26 20:27:58 +00:00
Ian Lepore
2d40ec16a8 Flesh out imx_uart_init() so that we're not relying on u-boot to init
the hardware (meaning uarts other than the console will work).
2014-04-26 20:03:04 +00:00
Ian Lepore
a90f19753f The freescale imx uart driver works for the whole i.MX family, so rename the
header file to not have "5xx" in the name.
2014-04-26 17:56:39 +00:00
Rui Paulo
3329109cb9 Use a more professional device description. 2014-04-07 05:18:27 +00:00
Warner Losh
d76a1ef4e1 Introduce grab and ungrab upcalls. When the kernel desires to grab the
console, it calls the grab functions. These functions should turn off
the RX interrupts, and any others that interfere. This makes mountroot
prompt work again. If there's more generalized need other than
prompting, many of these routines should be expanded to do those new
things.

Should have been part of r260889, but waasn't due to command line typo.

Reviewed by:	bde (with reservations)
2014-01-19 19:39:13 +00:00
Aleksandr Rybalko
3a1f3e0d0c Fix crossed fingers output. Only comment changed. 2013-10-24 09:27:06 +00:00
Ian Lepore
4d7abca057 Fix low-level uart drivers that set their fifo sizes in the softc too late.
uart(4) allocates send and receiver buffers in attach() before it calls
the low-level driver's attach routine.  Many low-level drivers set the
fifo sizes in their attach routine, which is too late.  Other drivers set
them in the probe() routine, so that they're available when uart(4)
allocates buffers.  This fixes the ones that were setting the values too
late by moving the code to probe().
2013-04-01 00:44:20 +00:00
Aleksandr Rybalko
a2c472e741 Integrate Efika MX project back to home.
Sponsored by:	The FreeBSD Foundation
2013-03-20 15:39:27 +00:00