devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/4] bcm2835: enable auxiliary uart1
@ 2015-09-11 12:20 kernel-TqfNSX0MhmxHKSADF0wUEw
       [not found] ` <1441974053-2630-1-git-send-email-kernel-TqfNSX0MhmxHKSADF0wUEw@public.gmane.org>
  0 siblings, 1 reply; 10+ messages in thread
From: kernel-TqfNSX0MhmxHKSADF0wUEw @ 2015-09-11 12:20 UTC (permalink / raw)
  To: Rob Herring, Pawel Moll, Mark Rutland, Ian Campbell, Kumar Gala,
	Russell King, Stephen Warren, Lee Jones, Greg Kroah-Hartman,
	Jiri Slaby, devicetree-u79uwXL29TY76Z2rM5mHXA,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	linux-rpi-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	linux-serial-u79uwXL29TY76Z2rM5mHXA
  Cc: Martin Sperl

From: Martin Sperl <kernel-TqfNSX0MhmxHKSADF0wUEw@public.gmane.org>

The bcm2835 SOC contains an auxiliary uart, which is very close
to the ns16550 with some differences.

The big difference is that the uart HW is not using an internal divider
of 16 but 8, which results in an effictive baud-rate being twice
the requested baud-rate.

The bcm2835-aux-uart is also special in such that it is enabled/disabled
by a gate in the clock, which is managed by the clk-bcm2835-aux
clock driver.

there are 2 options:
* defining the clock-frequency property in the device tree to 500k
  instead of 250k, but this keeps the HW block disabled making the
  uart not work.
* defining a clock in the device tree, but this results in a baud rate
  that is twice the requested baud-rate.

To address this this patch-set introduce a new property in the device tree
to define a clock divider other than 16.

This currently just scales the clock by a factor of 16/divider.

Note that the use of fixed-factor-clock has also been proposed as a
workarround, but this does not really describe the hw in the device tree
so another solution was needed that allows a correct representation of
the HW in the device tree.

Martin Sperl (4):
  serial: of-serial: allow for a custom clock divider different from 16
  dt/bindings: serial: of-serial: add description for clock-divider
    property
  serial: bcm2835: add auxiliary uart1 to device tree of bcm2835
  ARM: bcm2835: add of-serial and 8250 to bcm2835_defconfig

 Documentation/devicetree/bindings/serial/8250.txt |    1 +
 arch/arm/boot/dts/bcm2835.dtsi                    |   11 +++++++++++
 arch/arm/configs/bcm2835_defconfig                |    7 +++++++
 drivers/tty/serial/of_serial.c                    |   14 ++++++++++++++
 4 files changed, 33 insertions(+)

--
1.7.10.4
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2015-09-23 15:18 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-09-11 12:20 [PATCH 0/4] bcm2835: enable auxiliary uart1 kernel-TqfNSX0MhmxHKSADF0wUEw
     [not found] ` <1441974053-2630-1-git-send-email-kernel-TqfNSX0MhmxHKSADF0wUEw@public.gmane.org>
2015-09-11 12:20   ` [PATCH 1/4] serial: of-serial: allow for a custom clock divider different from 16 kernel-TqfNSX0MhmxHKSADF0wUEw
2015-09-11 12:20   ` [PATCH 2/4] dt/bindings: serial: of-serial: add description for clock-divider property kernel-TqfNSX0MhmxHKSADF0wUEw
2015-09-11 12:20   ` [PATCH 3/4] serial: bcm2835: add auxiliary uart1 to device tree of bcm2835 kernel-TqfNSX0MhmxHKSADF0wUEw
     [not found]     ` <1441974053-2630-4-git-send-email-kernel-TqfNSX0MhmxHKSADF0wUEw@public.gmane.org>
2015-09-22  2:42       ` Stephen Warren
     [not found]         ` <5600C011.8020402-3lzwWm7+Weoh9ZMKESR00Q@public.gmane.org>
2015-09-23 10:01           ` Martin Sperl
     [not found]             ` <5602788E.3070103-TqfNSX0MhmxHKSADF0wUEw@public.gmane.org>
2015-09-23 15:18               ` Stephen Warren
2015-09-11 12:20   ` [PATCH 4/4] ARM: bcm2835: add of-serial and 8250 to bcm2835_defconfig kernel-TqfNSX0MhmxHKSADF0wUEw
2015-09-14 14:53   ` [PATCH 0/4] bcm2835: enable auxiliary uart1 Eric Anholt
     [not found]     ` <87r3m1jbmr.fsf-omZaPlIz5HhaEpDpdNBo/KxOck334EZe@public.gmane.org>
2015-09-22  2:39       ` Stephen Warren

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).