1 From 0b7e0b20da67546344f9fc8e57699adfe61b8953 Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?Noralf=20Tr=C3=B8nnes?= <noralf@tronnes.org>
3 Date: Sat, 15 Aug 2015 20:50:02 +0200
4 Subject: [PATCH 025/381] bcm2835: Add support for uart1
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
9 This is a hack until a proper solution is agreed upon.
10 Martin Sperl is doing some work in this area.
12 Signed-off-by: Noralf Trønnes <noralf@tronnes.org>
14 arch/arm/mach-bcm/board_bcm2835.c | 25 +++++++++++++++++++++++++
15 1 file changed, 25 insertions(+)
17 --- a/arch/arm/mach-bcm/board_bcm2835.c
18 +++ b/arch/arm/mach-bcm/board_bcm2835.c
20 #include <asm/mach/arch.h>
21 #include <asm/mach/map.h>
23 +/* Use this hack until a proper solution is agreed upon */
24 +static void __init bcm2835_init_uart1(void)
26 + struct device_node *np;
28 + np = of_find_compatible_node(NULL, NULL, "brcm,bcm2835-aux-uart");
29 + if (of_device_is_available(np)) {
30 + np = of_find_compatible_node(NULL, NULL,
31 + "bcrm,bcm2835-aux-enable");
33 + void __iomem *base = of_iomap(np, 0);
36 + pr_err("bcm2835: Failed enabling Mini UART\n");
41 + pr_info("bcm2835: Mini UART enabled\n");
46 static void __init bcm2835_init(void)
48 struct device_node *np = of_find_node_by_path("/system");
49 @@ -42,6 +65,8 @@ static void __init bcm2835_init(void)
51 if (!of_property_read_u64(np, "linux,serial", &val64))
52 system_serial_low = val64;
54 + bcm2835_init_uart1();
57 static const char * const bcm2835_compat[] = {