u-boot/drivers/serial
Paul Burton 50fce1d5d8 serial: ns16550: Support clocks via phandle
Previously ns16550 compatible UARTs probed via device tree have needed
their device tree nodes to contain a clock-frequency property. An
alternative to this commonly used with Linux is to reference a clock via
a phandle. This patch allows U-Boot to support that, retrieving the
clock frequency by probing the appropriate clock device.

For example, a system might choose to provide the UART base clock as a
reference to a clock common to multiple devices:

  sys_clk: clock {
    compatible = "fixed-clock";
    #clock-cells = <0>;
    clock-frequency = <10000000>;
  };

  uart0: uart@10000000 {
    compatible = "ns16550a";
    reg = <0x10000000 0x1000>;
    clocks = <&sys_clk>;
  };

  uart1: uart@10000000 {
    compatible = "ns16550a";
    reg = <0x10001000 0x1000>;
    clocks = <&sys_clk>;
  };

This removes the need for the frequency information to be duplicated in
multiple nodes and allows the device tree to be more descriptive of the
system.

Signed-off-by: Paul Burton <paul.burton@imgtec.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2016-09-21 15:04:32 +02:00
..
altera_jtag_uart.c altera_jtag_uart: change ioremap to map_physmem 2015-11-18 21:18:30 +08:00
altera_uart.c altera_uart: change ioremap to map_physmem 2015-11-18 21:18:30 +08:00
arm_dcc.c serial: dcc: Move driver to DM 2016-02-25 19:06:37 -05:00
atmel_usart.c serial: atmel_usart: Add device tree support 2016-06-12 23:49:38 +02:00
atmel_usart.h Add GPL-2.0+ SPDX-License-Identifier to source files 2013-07-24 09:44:38 -04:00
Kconfig ARM: uniphier: change UNIPHIER_SERIAL to default y option 2016-08-28 13:11:35 +09:00
lpc32xx_hsuart.c serial: lpc32xx hsuart: port driver to driver model 2016-01-13 21:05:22 -05:00
Makefile rockchip: serial: Add an of-platdata driver for rockchip 2016-07-14 20:40:24 -06:00
mcfuart.c m68k: add DM model serial driver 2016-05-17 09:54:43 -06:00
ns16550.c serial: ns16550: Support clocks via phandle 2016-09-21 15:04:32 +02:00
sandbox.c sandbox: serial: Don't sync video in SPL 2016-07-14 20:40:24 -06:00
serial_ar933x.c ar933x: serial: Remove the explicit pinctrl setting 2016-05-21 01:36:38 +02:00
serial_arc.c arc: get rid of running_on_hw 2016-04-11 10:20:30 -07:00
serial_bcm283x_mu.c serial: bcm283x_mu: Detect disabled serial device 2016-09-06 13:18:19 -04:00
serial_bfin.c Use correct spelling of "U-Boot" 2016-02-06 12:00:59 +01:00
serial_efi.c debug_uart: Adjust the declaration of debug_uart_init() 2015-10-21 07:46:50 -06:00
serial_linflexuart.c serial: Introduce linflex uart support 2016-06-13 08:56:02 -04:00
serial_lpuart.c dm: serial: Remove duplicated carriage return character 2016-03-14 15:34:50 -06:00
serial_meson.c arm: add initial support for Amlogic Meson and ODROID-C2 2016-05-27 15:39:47 -04:00
serial_msm.c clk: convert API to match reset/mailbox style 2016-06-19 17:05:55 -06:00
serial_mxc.c serial_mxc: Remove unconditional DCE setting 2016-07-21 10:43:52 +02:00
serial_ns16550.c serial: Remove serial_putc_raw_dev 2016-01-25 10:39:45 -05:00
serial_pic32.c clk: convert API to match reset/mailbox style 2016-06-19 17:05:55 -06:00
serial_pl01x_internal.h dm: serial: Tidy up the pl01x driver 2014-10-22 10:36:57 -06:00
serial_pl01x.c serial: pl01x: Add support for devices with the rate pre-configured. 2016-03-22 12:16:12 -04:00
serial_pxa.c serial: Move carriage return before line feed for some serial drivers 2016-03-14 15:34:50 -06:00
serial_rockchip.c rockchip: serial: Add an of-platdata driver for rockchip 2016-07-14 20:40:24 -06:00
serial_s3c24x0.c serial: Move carriage return before line feed for some serial drivers 2016-03-14 15:34:50 -06:00
serial_s5p.c clk: convert API to match reset/mailbox style 2016-06-19 17:05:55 -06:00
serial_sh.c serial_sh: Add standrad SCI (w/o FIFO) support 2016-07-09 05:51:57 +09:00
serial_sh.h arm: rmobile: Add BLANCHE board support 2016-08-17 10:25:35 +09:00
serial_stm32.c serial: serial_stm32: move clock config from driver to board 2016-02-08 10:10:36 -05:00
serial_stm32x7.c stm32: clk: Add 200MHz clock configuration for stm32f746 discovery board 2016-07-14 18:22:41 -04:00
serial_stm32x7.h stm32x7: add support for stm32x7 serial driver 2016-02-24 18:43:54 -05:00
serial_uniphier.c ARM: uniphier: use (devm_)ioremap() instead of map_sysmem() 2016-07-24 00:13:10 +09:00
serial_xuartlite.c serial: uartlite: Add support for debug console 2016-01-27 15:55:49 +01:00
serial_zynq.c serial: zynq: Read information about clock from DT 2016-07-22 14:04:40 +02:00
serial-uclass.c dm: serial: Add support for of-platdata 2016-07-14 20:40:24 -06:00
serial.c Fix typo: firstly -> first. 2015-12-05 18:22:23 -05:00
usbtty.c serial: Move carriage return before line feed for some serial drivers 2016-03-14 15:34:50 -06:00
usbtty.h omap: clean-up dead configs 2014-08-09 11:17:04 -04:00