devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH RESEND 0/9] ARM: davinci: DT boot support for DA850
@ 2012-09-12 16:35 Sekhar Nori
       [not found] ` <1347467732-1332-1-git-send-email-nsekhar-l0cyMroinI0@public.gmane.org>
  2012-10-23 12:36 ` [PATCH RESEND 0/9] ARM: davinci: DT boot support for DA850 Sekhar Nori
  0 siblings, 2 replies; 11+ messages in thread
From: Sekhar Nori @ 2012-09-12 16:35 UTC (permalink / raw)
  To: Grant Likely, Rob Herring, Rob Landley, Russell King,
	Kevin Hilman
  Cc: davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/,
	linux-doc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ, Heiko Schocher,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

This series adds basic DT boot support for DA850 EVM and EnBW CMC board.
It applies to master branch of Linux DaVinci tree[1].

Resending this because I missed copying the DT and Documentation folks
last time around. Sorry about that. There is no change in patch contents.

Thanks,
Sekhar

[1] git://gitorious.org/linux-davinci/linux-davinci.git

Heiko Schocher (2):
  ARM: davinci: da850: add SoC DT data
  ARM: davinci: add support for am1808 based EnBW CMC board

Sekhar Nori (7):
  ARM: davinci: uncompress.h: bail out if uart not initialized
  ARM: davinci: serial: provide API to initialze UART clocks
  ARM: davinci: arrange kconfig selects in alphabetical order
  ARM: davinci: da850: add DT boot support
  ARM: davinci: da850 evm: add DT data
  ARM: davinci: da850: generate dtbs for da850 boards
  ARM: davinci: da8xx defconfig: enable DT config options

 Documentation/devicetree/bindings/arm/davinci.txt |   17 ++++++
 arch/arm/Kconfig                                  |    9 +--
 arch/arm/boot/dts/da850-enbw-cmc.dts              |   30 ++++++++++
 arch/arm/boot/dts/da850-evm.dts                   |   28 +++++++++
 arch/arm/boot/dts/da850.dtsi                      |   60 +++++++++++++++++++
 arch/arm/configs/da8xx_omapl_defconfig            |    3 +
 arch/arm/mach-davinci/Kconfig                     |    8 +++
 arch/arm/mach-davinci/Makefile                    |    1 +
 arch/arm/mach-davinci/Makefile.boot               |    2 +
 arch/arm/mach-davinci/da8xx-dt.c                  |   66 +++++++++++++++++++++
 arch/arm/mach-davinci/include/mach/serial.h       |    1 +
 arch/arm/mach-davinci/include/mach/uncompress.h   |    6 ++
 arch/arm/mach-davinci/serial.c                    |   39 ++++++++----
 13 files changed, 254 insertions(+), 16 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/arm/davinci.txt
 create mode 100644 arch/arm/boot/dts/da850-enbw-cmc.dts
 create mode 100644 arch/arm/boot/dts/da850-evm.dts
 create mode 100644 arch/arm/boot/dts/da850.dtsi
 create mode 100644 arch/arm/mach-davinci/da8xx-dt.c

-- 
1.7.10.1

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

* [PATCH 1/9] ARM: davinci: uncompress.h: bail out if uart not initialized
       [not found] ` <1347467732-1332-1-git-send-email-nsekhar-l0cyMroinI0@public.gmane.org>
@ 2012-09-12 16:35   ` Sekhar Nori
  2012-09-12 16:35   ` [PATCH 2/9] ARM: davinci: serial: provide API to initialze UART clocks Sekhar Nori
                     ` (7 subsequent siblings)
  8 siblings, 0 replies; 11+ messages in thread
From: Sekhar Nori @ 2012-09-12 16:35 UTC (permalink / raw)
  To: Grant Likely, Rob Herring, Rob Landley, Russell King,
	Kevin Hilman
  Cc: davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/,
	linux-doc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ, Heiko Schocher,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Bail out of UART access functions in uncompress.h if the uart
port is not setup. This will happen when booting from DT since
machine type matching does not work in this case. This may also
happen if a correct machine type is not setup by bootloader.

Signed-off-by: Sekhar Nori <nsekhar-l0cyMroinI0@public.gmane.org>
---
 arch/arm/mach-davinci/include/mach/uncompress.h |    6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/arch/arm/mach-davinci/include/mach/uncompress.h b/arch/arm/mach-davinci/include/mach/uncompress.h
index 18cfd49..3a0ff90 100644
--- a/arch/arm/mach-davinci/include/mach/uncompress.h
+++ b/arch/arm/mach-davinci/include/mach/uncompress.h
@@ -32,6 +32,9 @@ u32 *uart;
 /* PORT_16C550A, in polled non-fifo mode */
 static void putc(char c)
 {
+	if (!uart)
+		return;
+
 	while (!(uart[UART_LSR] & UART_LSR_THRE))
 		barrier();
 	uart[UART_TX] = c;
@@ -39,6 +42,9 @@ static void putc(char c)
 
 static inline void flush(void)
 {
+	if (!uart)
+		return;
+
 	while (!(uart[UART_LSR] & UART_LSR_THRE))
 		barrier();
 }
-- 
1.7.10.1

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

* [PATCH 2/9] ARM: davinci: serial: provide API to initialze UART clocks
       [not found] ` <1347467732-1332-1-git-send-email-nsekhar-l0cyMroinI0@public.gmane.org>
  2012-09-12 16:35   ` [PATCH 1/9] ARM: davinci: uncompress.h: bail out if uart not initialized Sekhar Nori
@ 2012-09-12 16:35   ` Sekhar Nori
  2012-09-12 16:35   ` [PATCH 3/9] ARM: davinci: arrange kconfig selects in alphabetical order Sekhar Nori
                     ` (6 subsequent siblings)
  8 siblings, 0 replies; 11+ messages in thread
From: Sekhar Nori @ 2012-09-12 16:35 UTC (permalink / raw)
  To: Grant Likely, Rob Herring, Rob Landley, Russell King,
	Kevin Hilman
  Cc: davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/,
	linux-doc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ, Heiko Schocher,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Provide an API to initialize a UART clock. Refactor existing
davinci_serial_init() to separate out the part which enables
the clock.

This will later be used to help DA850 DT boot support.

Signed-off-by: Sekhar Nori <nsekhar-l0cyMroinI0@public.gmane.org>
---
 arch/arm/mach-davinci/include/mach/serial.h |    1 +
 arch/arm/mach-davinci/serial.c              |   39 ++++++++++++++++++---------
 2 files changed, 28 insertions(+), 12 deletions(-)

diff --git a/arch/arm/mach-davinci/include/mach/serial.h b/arch/arm/mach-davinci/include/mach/serial.h
index 46b3cd1..2d9d921 100644
--- a/arch/arm/mach-davinci/include/mach/serial.h
+++ b/arch/arm/mach-davinci/include/mach/serial.h
@@ -43,6 +43,7 @@ struct davinci_uart_config {
 };
 
 extern int davinci_serial_init(struct davinci_uart_config *);
+extern int davinci_serial_setup_clk(unsigned instance, unsigned int *rate);
 #endif
 
 #endif /* __ASM_ARCH_SERIAL_H */
diff --git a/arch/arm/mach-davinci/serial.c b/arch/arm/mach-davinci/serial.c
index 24ddb0d..f262581 100644
--- a/arch/arm/mach-davinci/serial.c
+++ b/arch/arm/mach-davinci/serial.c
@@ -70,11 +70,33 @@ static void __init davinci_serial_reset(struct plat_serial8250_port *p)
 				 UART_DM646X_SCR_TX_WATERMARK);
 }
 
-int __init davinci_serial_init(struct davinci_uart_config *info)
+/* Enable UART clock and obtain its rate */
+int __init davinci_serial_setup_clk(unsigned instance, unsigned int *rate)
 {
-	int i;
 	char name[16];
-	struct clk *uart_clk;
+	struct clk *clk;
+	struct davinci_soc_info *soc_info = &davinci_soc_info;
+	struct device *dev = &soc_info->serial_dev->dev;
+
+	sprintf(name, "uart%d", instance);
+	clk = clk_get(dev, name);
+	if (IS_ERR(clk)) {
+		pr_err("%s:%d: failed to get UART%d clock\n",
+					__func__, __LINE__, instance);
+		return PTR_ERR(clk);
+	}
+
+	clk_prepare_enable(clk);
+
+	if (rate)
+		*rate = clk_get_rate(clk);
+
+	return 0;
+}
+
+int __init davinci_serial_init(struct davinci_uart_config *info)
+{
+	int i, ret;
 	struct davinci_soc_info *soc_info = &davinci_soc_info;
 	struct device *dev = &soc_info->serial_dev->dev;
 	struct plat_serial8250_port *p = dev->platform_data;
@@ -87,16 +109,9 @@ int __init davinci_serial_init(struct davinci_uart_config *info)
 		if (!(info->enabled_uarts & (1 << i)))
 			continue;
 
-		sprintf(name, "uart%d", i);
-		uart_clk = clk_get(dev, name);
-		if (IS_ERR(uart_clk)) {
-			printk(KERN_ERR "%s:%d: failed to get UART%d clock\n",
-					__func__, __LINE__, i);
+		ret = davinci_serial_setup_clk(i, &p->uartclk);
+		if (ret)
 			continue;
-		}
-
-		clk_prepare_enable(uart_clk);
-		p->uartclk = clk_get_rate(uart_clk);
 
 		if (!p->membase && p->mapbase) {
 			p->membase = ioremap(p->mapbase, SZ_4K);
-- 
1.7.10.1

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

* [PATCH 3/9] ARM: davinci: arrange kconfig selects in alphabetical order
       [not found] ` <1347467732-1332-1-git-send-email-nsekhar-l0cyMroinI0@public.gmane.org>
  2012-09-12 16:35   ` [PATCH 1/9] ARM: davinci: uncompress.h: bail out if uart not initialized Sekhar Nori
  2012-09-12 16:35   ` [PATCH 2/9] ARM: davinci: serial: provide API to initialze UART clocks Sekhar Nori
@ 2012-09-12 16:35   ` Sekhar Nori
  2012-09-12 16:35   ` [PATCH 4/9] ARM: davinci: da850: add DT boot support Sekhar Nori
                     ` (5 subsequent siblings)
  8 siblings, 0 replies; 11+ messages in thread
From: Sekhar Nori @ 2012-09-12 16:35 UTC (permalink / raw)
  To: Grant Likely, Rob Herring, Rob Landley, Russell King,
	Kevin Hilman
  Cc: davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/,
	linux-doc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ, Heiko Schocher,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Arrange Kconfig selects for DaVinci in alphabetical order.
This makes it easier to avoid adding duplicate selects.

Signed-off-by: Sekhar Nori <nsekhar-l0cyMroinI0@public.gmane.org>
---
 arch/arm/Kconfig |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index c5f9ae5..df04b0b 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -963,14 +963,14 @@ config ARCH_NOMADIK
 
 config ARCH_DAVINCI
 	bool "TI DaVinci"
-	select GENERIC_CLOCKEVENTS
+	select ARCH_HAS_HOLES_MEMORYMODEL
 	select ARCH_REQUIRE_GPIOLIB
-	select ZONE_DMA
-	select HAVE_IDE
 	select CLKDEV_LOOKUP
 	select GENERIC_ALLOCATOR
+	select GENERIC_CLOCKEVENTS
 	select GENERIC_IRQ_CHIP
-	select ARCH_HAS_HOLES_MEMORYMODEL
+	select HAVE_IDE
+	select ZONE_DMA
 	help
 	  Support for TI's DaVinci platform.
 
-- 
1.7.10.1

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

* [PATCH 4/9] ARM: davinci: da850: add DT boot support
       [not found] ` <1347467732-1332-1-git-send-email-nsekhar-l0cyMroinI0@public.gmane.org>
                     ` (2 preceding siblings ...)
  2012-09-12 16:35   ` [PATCH 3/9] ARM: davinci: arrange kconfig selects in alphabetical order Sekhar Nori
@ 2012-09-12 16:35   ` Sekhar Nori
  2012-09-12 16:35   ` [PATCH 5/9] ARM: davinci: da850: add SoC DT data Sekhar Nori
                     ` (4 subsequent siblings)
  8 siblings, 0 replies; 11+ messages in thread
From: Sekhar Nori @ 2012-09-12 16:35 UTC (permalink / raw)
  To: Grant Likely, Rob Herring, Rob Landley, Russell King,
	Kevin Hilman
  Cc: davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/,
	linux-doc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ, Heiko Schocher,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Add support for booting DA850 using flattened device
tree to describe the hardware. At this time only the
very basic bootup using a serial console is supported.

Signed-off-by: Sekhar Nori <nsekhar-l0cyMroinI0@public.gmane.org>
---
 Documentation/devicetree/bindings/arm/davinci.txt |    9 +++
 arch/arm/Kconfig                                  |    1 +
 arch/arm/mach-davinci/Kconfig                     |    8 +++
 arch/arm/mach-davinci/Makefile                    |    1 +
 arch/arm/mach-davinci/da8xx-dt.c                  |   64 +++++++++++++++++++++
 5 files changed, 83 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/arm/davinci.txt
 create mode 100644 arch/arm/mach-davinci/da8xx-dt.c

diff --git a/Documentation/devicetree/bindings/arm/davinci.txt b/Documentation/devicetree/bindings/arm/davinci.txt
new file mode 100644
index 0000000..aa4e7a1
--- /dev/null
+++ b/Documentation/devicetree/bindings/arm/davinci.txt
@@ -0,0 +1,9 @@
+Texas Instruments DaVinci Platforms Device Tree Bindings
+--------------------------------------------------------
+
+Generic DaVinci Boards
+----------------------
+
+DA850/OMAP-L138/AM18x generic board
+Required root node properties:
+    - compatible = "ti,da850";
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index df04b0b..d59765a 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -970,6 +970,7 @@ config ARCH_DAVINCI
 	select GENERIC_CLOCKEVENTS
 	select GENERIC_IRQ_CHIP
 	select HAVE_IDE
+	select USE_OF
 	select ZONE_DMA
 	help
 	  Support for TI's DaVinci platform.
diff --git a/arch/arm/mach-davinci/Kconfig b/arch/arm/mach-davinci/Kconfig
index ab99c3c..5da2148 100644
--- a/arch/arm/mach-davinci/Kconfig
+++ b/arch/arm/mach-davinci/Kconfig
@@ -58,6 +58,14 @@ config ARCH_DAVINCI_TNETV107X
 
 comment "DaVinci Board Type"
 
+config MACH_DA8XX_DT
+	bool "Support DA8XX platforms using device tree"
+	default y
+	depends on ARCH_DAVINCI_DA8XX
+	help
+	  Say y here to include support for TI DaVinci DA850 based using
+	  Flattened Device Tree. More information at Documentation/devicetree
+
 config MACH_DAVINCI_EVM
 	bool "TI DM644x EVM"
 	default ARCH_DAVINCI_DM644x
diff --git a/arch/arm/mach-davinci/Makefile b/arch/arm/mach-davinci/Makefile
index 2227eff..fb5c1aa 100644
--- a/arch/arm/mach-davinci/Makefile
+++ b/arch/arm/mach-davinci/Makefile
@@ -22,6 +22,7 @@ obj-$(CONFIG_AINTC)			+= irq.o
 obj-$(CONFIG_CP_INTC)			+= cp_intc.o
 
 # Board specific
+obj-$(CONFIG_MACH_DA8XX_DT)		+= da8xx-dt.o
 obj-$(CONFIG_MACH_DAVINCI_EVM)  	+= board-dm644x-evm.o
 obj-$(CONFIG_MACH_SFFSDR)		+= board-sffsdr.o
 obj-$(CONFIG_MACH_NEUROS_OSD2)		+= board-neuros-osd2.o
diff --git a/arch/arm/mach-davinci/da8xx-dt.c b/arch/arm/mach-davinci/da8xx-dt.c
new file mode 100644
index 0000000..df393d9
--- /dev/null
+++ b/arch/arm/mach-davinci/da8xx-dt.c
@@ -0,0 +1,64 @@
+/*
+ * Copyright (C) 2012 Texas Instruments Incorporated - http://www.ti.com/
+ *
+ * Modified from mach-omap/omap2/board-generic.c
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+#include <linux/io.h>
+#include <linux/of_irq.h>
+#include <linux/of_platform.h>
+#include <linux/irqdomain.h>
+
+#include <asm/mach/arch.h>
+
+#include <mach/common.h>
+#include <mach/cp_intc.h>
+#include <mach/da8xx.h>
+
+#define DA8XX_NUM_UARTS	3
+
+void __init da8xx_uart_clk_enable(void)
+{
+	int i;
+	for (i = 0; i < DA8XX_NUM_UARTS; i++)
+		davinci_serial_setup_clk(i, NULL);
+}
+
+static struct of_device_id da8xx_irq_match[] __initdata = {
+	{ .compatible = "ti,cp-intc", .data = cp_intc_of_init, },
+	{ }
+};
+
+static void __init da8xx_init_irq(void)
+{
+	of_irq_init(da8xx_irq_match);
+}
+
+#ifdef CONFIG_ARCH_DAVINCI_DA850
+
+static void __init da850_init_machine(void)
+{
+	of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
+
+	da8xx_uart_clk_enable();
+}
+
+static const char *da850_boards_compat[] __initdata = {
+	"ti,da850",
+	NULL,
+};
+
+DT_MACHINE_START(DA850_DT, "Generic DA850/OMAP-L138/AM18x")
+	.map_io		= da850_init,
+	.init_irq	= da8xx_init_irq,
+	.timer		= &davinci_timer,
+	.init_machine	= da850_init_machine,
+	.dt_compat	= da850_boards_compat,
+	.init_late	= davinci_init_late,
+	.restart	= da8xx_restart,
+MACHINE_END
+
+#endif
-- 
1.7.10.1

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

* [PATCH 5/9] ARM: davinci: da850: add SoC DT data
       [not found] ` <1347467732-1332-1-git-send-email-nsekhar-l0cyMroinI0@public.gmane.org>
                     ` (3 preceding siblings ...)
  2012-09-12 16:35   ` [PATCH 4/9] ARM: davinci: da850: add DT boot support Sekhar Nori
@ 2012-09-12 16:35   ` Sekhar Nori
  2012-09-12 16:35   ` [PATCH 6/9] ARM: davinci: da850 evm: add " Sekhar Nori
                     ` (3 subsequent siblings)
  8 siblings, 0 replies; 11+ messages in thread
From: Sekhar Nori @ 2012-09-12 16:35 UTC (permalink / raw)
  To: Grant Likely, Rob Herring, Rob Landley, Russell King,
	Kevin Hilman
  Cc: davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/,
	linux-doc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ, Heiko Schocher,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

From: Heiko Schocher <hs-ynQEQJNshbs@public.gmane.org>

Add DT data for DA850 SoC. Only interrupt controller and
serial port information is being added at this time.

Signed-off-by: Heiko Schocher <hs-ynQEQJNshbs@public.gmane.org>
[nsekhar-l0cyMroinI0@public.gmane.org: refactored DT data into SoC specific and
board specific and include SoC data into .dtsi file]
Signed-off-by: Sekhar Nori <nsekhar-l0cyMroinI0@public.gmane.org>
---
 arch/arm/boot/dts/da850.dtsi |   60 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 60 insertions(+)
 create mode 100644 arch/arm/boot/dts/da850.dtsi

diff --git a/arch/arm/boot/dts/da850.dtsi b/arch/arm/boot/dts/da850.dtsi
new file mode 100644
index 0000000..640ab75
--- /dev/null
+++ b/arch/arm/boot/dts/da850.dtsi
@@ -0,0 +1,60 @@
+/*
+ * Copyright 2012 DENX Software Engineering GmbH
+ * Heiko Schocher <hs-ynQEQJNshbs@public.gmane.org>
+ *
+ * This program is free software; you can redistribute  it and/or modify it
+ * under  the terms of  the GNU General  Public License as published by the
+ * Free Software Foundation;  either version 2 of the  License, or (at your
+ * option) any later version.
+ */
+/include/ "skeleton.dtsi"
+
+/ {
+	arm {
+		#address-cells = <1>;
+		#size-cells = <1>;
+		ranges;
+		intc: interrupt-controller {
+			compatible = "ti,cp-intc";
+			interrupt-controller;
+			#interrupt-cells = <1>;
+			ti,intc-size = <100>;
+			reg = <0xfffee000 0x2000>;
+		};
+	};
+	soc {
+		compatible = "simple-bus";
+		model = "da850";
+		#address-cells = <1>;
+		#size-cells = <1>;
+		ranges = <0x0 0x01c00000 0x400000>;
+
+		serial0: serial@1c42000 {
+			compatible = "ns16550a";
+			reg = <0x42000 0x100>;
+			clock-frequency = <150000000>;
+			reg-shift = <2>;
+			interrupts = <25>;
+			interrupt-parent = <&intc>;
+			status = "disabled";
+		};
+		serial1: serial@1d0c000 {
+			compatible = "ns16550a";
+			reg = <0x10c000 0x100>;
+			clock-frequency = <150000000>;
+			reg-shift = <2>;
+			interrupts = <53>;
+			interrupt-parent = <&intc>;
+			status = "disabled";
+		};
+		serial2: serial@1d0d000 {
+			compatible = "ns16550a";
+			reg = <0x10d000 0x100>;
+			clock-frequency = <150000000>;
+			reg-shift = <2>;
+			interrupts = <61>;
+			interrupt-parent = <&intc>;
+			status = "disabled";
+		};
+	};
+};
-- 
1.7.10.1

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

* [PATCH 6/9] ARM: davinci: da850 evm: add DT data
       [not found] ` <1347467732-1332-1-git-send-email-nsekhar-l0cyMroinI0@public.gmane.org>
                     ` (4 preceding siblings ...)
  2012-09-12 16:35   ` [PATCH 5/9] ARM: davinci: da850: add SoC DT data Sekhar Nori
@ 2012-09-12 16:35   ` Sekhar Nori
  2012-09-12 16:35   ` [PATCH 7/9] ARM: davinci: add support for am1808 based EnBW CMC board Sekhar Nori
                     ` (2 subsequent siblings)
  8 siblings, 0 replies; 11+ messages in thread
From: Sekhar Nori @ 2012-09-12 16:35 UTC (permalink / raw)
  To: Grant Likely, Rob Herring, Rob Landley, Russell King,
	Kevin Hilman
  Cc: davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/,
	linux-doc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ, Heiko Schocher,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Add device tree data for DA850 EVM. At this time, only
information on serial ports is added.

Signed-off-by: Sekhar Nori <nsekhar-l0cyMroinI0@public.gmane.org>
---
 Documentation/devicetree/bindings/arm/davinci.txt |    4 +++
 arch/arm/boot/dts/da850-evm.dts                   |   28 +++++++++++++++++++++
 arch/arm/mach-davinci/da8xx-dt.c                  |    1 +
 3 files changed, 33 insertions(+)
 create mode 100644 arch/arm/boot/dts/da850-evm.dts

diff --git a/Documentation/devicetree/bindings/arm/davinci.txt b/Documentation/devicetree/bindings/arm/davinci.txt
index aa4e7a1..2dda756 100644
--- a/Documentation/devicetree/bindings/arm/davinci.txt
+++ b/Documentation/devicetree/bindings/arm/davinci.txt
@@ -1,6 +1,10 @@
 Texas Instruments DaVinci Platforms Device Tree Bindings
 --------------------------------------------------------
 
+DA850/OMAP-L138/AM18x Evaluation Module (EVM) board
+Required root node properties:
+    - compatible = "ti,da850-evm", "ti,da850";
+
 Generic DaVinci Boards
 ----------------------
 
diff --git a/arch/arm/boot/dts/da850-evm.dts b/arch/arm/boot/dts/da850-evm.dts
new file mode 100644
index 0000000..37dc5a3
--- /dev/null
+++ b/arch/arm/boot/dts/da850-evm.dts
@@ -0,0 +1,28 @@
+/*
+ * Device Tree for DA850 EVM board
+ *
+ * Copyright (C) 2012 Texas Instruments Incorporated - http://www.ti.com/
+ *
+ * This program is free software; you can redistribute  it and/or modify it
+ * under  the terms of  the GNU General  Public License as published by the
+ * Free Software Foundation, version 2.
+ */
+/dts-v1/;
+/include/ "da850.dtsi"
+
+/ {
+	compatible = "ti,da850-evm", "ti,da850";
+	model = "DA850/AM1808/OMAP-L138 EVM";
+
+	soc {
+		serial0: serial@1c42000 {
+			status = "okay";
+		};
+		serial1: serial@1d0c000 {
+			status = "okay";
+		};
+		serial2: serial@1d0d000 {
+			status = "okay";
+		};
+	};
+};
diff --git a/arch/arm/mach-davinci/da8xx-dt.c b/arch/arm/mach-davinci/da8xx-dt.c
index df393d9..94b09fd 100644
--- a/arch/arm/mach-davinci/da8xx-dt.c
+++ b/arch/arm/mach-davinci/da8xx-dt.c
@@ -47,6 +47,7 @@ static void __init da850_init_machine(void)
 }
 
 static const char *da850_boards_compat[] __initdata = {
+	"ti,da850-evm",
 	"ti,da850",
 	NULL,
 };
-- 
1.7.10.1

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

* [PATCH 7/9] ARM: davinci: add support for am1808 based EnBW CMC board
       [not found] ` <1347467732-1332-1-git-send-email-nsekhar-l0cyMroinI0@public.gmane.org>
                     ` (5 preceding siblings ...)
  2012-09-12 16:35   ` [PATCH 6/9] ARM: davinci: da850 evm: add " Sekhar Nori
@ 2012-09-12 16:35   ` Sekhar Nori
  2012-09-12 16:35   ` [PATCH 8/9] ARM: davinci: da850: generate dtbs for da850 boards Sekhar Nori
  2012-09-12 16:35   ` [PATCH 9/9] ARM: davinci: da8xx defconfig: enable DT config options Sekhar Nori
  8 siblings, 0 replies; 11+ messages in thread
From: Sekhar Nori @ 2012-09-12 16:35 UTC (permalink / raw)
  To: Grant Likely, Rob Herring, Rob Landley, Russell King,
	Kevin Hilman
  Cc: davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/,
	Wolfgang Denk, linux-doc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ, Heiko Schocher,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

From: Heiko Schocher <hs-ynQEQJNshbs@public.gmane.org>

This board supports:

- AM1808 based board
- 64 MiB DDR ram
- 2 MiB Nor flash
- 128 MiB NAND flash
- use internal RTC
- I2C support
- hwmon lm75 support
- UBI/UBIFS support
- MMC support
- USB OTG support

This patch adds the basic DTS file enabling the serial ports.
Other features will be added in due course of time.

Signed-off-by: Heiko Schocher <hs-ynQEQJNshbs@public.gmane.org>
Cc: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
Cc: devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org
Cc: davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/@public.gmane.org
Cc: Sekhar Nori <nsekhar-l0cyMroinI0@public.gmane.org>
Cc: Kevin Hilman <khilman-l0cyMroinI0@public.gmane.org>
Cc: Wolfgang Denk <wd-ynQEQJNshbs@public.gmane.org>
[nsekhar-l0cyMroinI0@public.gmane.org: modified after dtsi refactoring and added binding
documentation]
Signed-off-by: Sekhar Nori <nsekhar-l0cyMroinI0@public.gmane.org>
---
 Documentation/devicetree/bindings/arm/davinci.txt |    4 +++
 arch/arm/boot/dts/da850-enbw-cmc.dts              |   30 +++++++++++++++++++++
 arch/arm/mach-davinci/da8xx-dt.c                  |    1 +
 3 files changed, 35 insertions(+)
 create mode 100644 arch/arm/boot/dts/da850-enbw-cmc.dts

diff --git a/Documentation/devicetree/bindings/arm/davinci.txt b/Documentation/devicetree/bindings/arm/davinci.txt
index 2dda756..cfaeda4 100644
--- a/Documentation/devicetree/bindings/arm/davinci.txt
+++ b/Documentation/devicetree/bindings/arm/davinci.txt
@@ -5,6 +5,10 @@ DA850/OMAP-L138/AM18x Evaluation Module (EVM) board
 Required root node properties:
     - compatible = "ti,da850-evm", "ti,da850";
 
+EnBW AM1808 based CMC board
+Required root node properties:
+    - compatible = "enbw,cmc", "ti,da850;
+
 Generic DaVinci Boards
 ----------------------
 
diff --git a/arch/arm/boot/dts/da850-enbw-cmc.dts b/arch/arm/boot/dts/da850-enbw-cmc.dts
new file mode 100644
index 0000000..422fdb3
--- /dev/null
+++ b/arch/arm/boot/dts/da850-enbw-cmc.dts
@@ -0,0 +1,30 @@
+/*
+ * Device Tree for AM1808 EnBW CMC board
+ *
+ * Copyright 2012 DENX Software Engineering GmbH
+ * Heiko Schocher <hs-ynQEQJNshbs@public.gmane.org>
+ *
+ * This program is free software; you can redistribute  it and/or modify it
+ * under  the terms of  the GNU General  Public License as published by the
+ * Free Software Foundation;  either version 2 of the  License, or (at your
+ * option) any later version.
+ */
+/dts-v1/;
+/include/ "da850.dtsi"
+
+/ {
+	compatible = "enbw,cmc", "ti,da850";
+	model = "EnBW CMC";
+
+	soc {
+		serial0: serial@1c42000 {
+			status = "okay";
+		};
+		serial1: serial@1d0c000 {
+			status = "okay";
+		};
+		serial2: serial@1d0d000 {
+			status = "okay";
+		};
+	};
+};
diff --git a/arch/arm/mach-davinci/da8xx-dt.c b/arch/arm/mach-davinci/da8xx-dt.c
index 94b09fd..37c27af 100644
--- a/arch/arm/mach-davinci/da8xx-dt.c
+++ b/arch/arm/mach-davinci/da8xx-dt.c
@@ -47,6 +47,7 @@ static void __init da850_init_machine(void)
 }
 
 static const char *da850_boards_compat[] __initdata = {
+	"enbw,cmc",
 	"ti,da850-evm",
 	"ti,da850",
 	NULL,
-- 
1.7.10.1

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

* [PATCH 8/9] ARM: davinci: da850: generate dtbs for da850 boards
       [not found] ` <1347467732-1332-1-git-send-email-nsekhar-l0cyMroinI0@public.gmane.org>
                     ` (6 preceding siblings ...)
  2012-09-12 16:35   ` [PATCH 7/9] ARM: davinci: add support for am1808 based EnBW CMC board Sekhar Nori
@ 2012-09-12 16:35   ` Sekhar Nori
  2012-09-12 16:35   ` [PATCH 9/9] ARM: davinci: da8xx defconfig: enable DT config options Sekhar Nori
  8 siblings, 0 replies; 11+ messages in thread
From: Sekhar Nori @ 2012-09-12 16:35 UTC (permalink / raw)
  To: Grant Likely, Rob Herring, Rob Landley, Russell King,
	Kevin Hilman
  Cc: davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/,
	linux-doc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ, Heiko Schocher,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

This helps generating device tree blobs for DaVinci DA850 boards with
command:

    'make ARCH=arm dtbs'.

Signed-off-by: Sekhar Nori <nsekhar-l0cyMroinI0@public.gmane.org>
---
 arch/arm/mach-davinci/Makefile.boot |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm/mach-davinci/Makefile.boot b/arch/arm/mach-davinci/Makefile.boot
index 04a6c4e..5c5a95a 100644
--- a/arch/arm/mach-davinci/Makefile.boot
+++ b/arch/arm/mach-davinci/Makefile.boot
@@ -11,3 +11,5 @@ else
 params_phys-y	:= 0x80000100
 initrd_phys-y	:= 0x80800000
 endif
+
+dtb-$(CONFIG_MACH_DA8XX_DT)	+= da850-enbw-cmc.dtb da850-evm.dtb
-- 
1.7.10.1

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

* [PATCH 9/9] ARM: davinci: da8xx defconfig: enable DT config options
       [not found] ` <1347467732-1332-1-git-send-email-nsekhar-l0cyMroinI0@public.gmane.org>
                     ` (7 preceding siblings ...)
  2012-09-12 16:35   ` [PATCH 8/9] ARM: davinci: da850: generate dtbs for da850 boards Sekhar Nori
@ 2012-09-12 16:35   ` Sekhar Nori
  8 siblings, 0 replies; 11+ messages in thread
From: Sekhar Nori @ 2012-09-12 16:35 UTC (permalink / raw)
  To: Grant Likely, Rob Herring, Rob Landley, Russell King,
	Kevin Hilman
  Cc: davinci-linux-open-source-VycZQUHpC/PFrsHnngEfi1aTQe2KTcn/,
	linux-doc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-discuss-uLR06cmDAlY/bJ5BZ2RsiQ, Heiko Schocher,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Enable DT related config options in da8xx_omapl_defconfig

Signed-off-by: Sekhar Nori <nsekhar-l0cyMroinI0@public.gmane.org>
---
 arch/arm/configs/da8xx_omapl_defconfig |    3 +++
 1 file changed, 3 insertions(+)

diff --git a/arch/arm/configs/da8xx_omapl_defconfig b/arch/arm/configs/da8xx_omapl_defconfig
index 88ccde0..f292239 100644
--- a/arch/arm/configs/da8xx_omapl_defconfig
+++ b/arch/arm/configs/da8xx_omapl_defconfig
@@ -17,6 +17,7 @@ CONFIG_MODVERSIONS=y
 CONFIG_ARCH_DAVINCI=y
 CONFIG_ARCH_DAVINCI_DA830=y
 CONFIG_ARCH_DAVINCI_DA850=y
+CONFIG_MACH_DA8XX_DT=y
 CONFIG_MACH_MITYOMAPL138=y
 CONFIG_MACH_OMAPL138_HAWKBOARD=y
 CONFIG_DAVINCI_RESET_CLOCKS=y
@@ -26,6 +27,7 @@ CONFIG_PREEMPT=y
 CONFIG_AEABI=y
 # CONFIG_OABI_COMPAT is not set
 CONFIG_LEDS=y
+CONFIG_USE_OF=y
 CONFIG_ZBOOT_ROM_TEXT=0x0
 CONFIG_ZBOOT_ROM_BSS=0x0
 CONFIG_CPU_FREQ=y
@@ -75,6 +77,7 @@ CONFIG_SERIO_LIBPS2=y
 CONFIG_SERIAL_8250=y
 CONFIG_SERIAL_8250_CONSOLE=y
 CONFIG_SERIAL_8250_NR_UARTS=3
+CONFIG_SERIAL_OF_PLATFORM=y
 CONFIG_I2C=y
 CONFIG_I2C_CHARDEV=y
 CONFIG_I2C_DAVINCI=y
-- 
1.7.10.1

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

* Re: [PATCH RESEND 0/9] ARM: davinci: DT boot support for DA850
  2012-09-12 16:35 [PATCH RESEND 0/9] ARM: davinci: DT boot support for DA850 Sekhar Nori
       [not found] ` <1347467732-1332-1-git-send-email-nsekhar-l0cyMroinI0@public.gmane.org>
@ 2012-10-23 12:36 ` Sekhar Nori
  1 sibling, 0 replies; 11+ messages in thread
From: Sekhar Nori @ 2012-10-23 12:36 UTC (permalink / raw)
  To: Sekhar Nori
  Cc: Grant Likely, Rob Herring, Rob Landley, Russell King,
	Kevin Hilman, Heiko Schocher, devicetree-discuss, linux-doc,
	davinci-linux-open-source, linux-arm-kernel

On 9/12/2012 10:05 PM, Sekhar Nori wrote:
> This series adds basic DT boot support for DA850 EVM and EnBW CMC board.
> It applies to master branch of Linux DaVinci tree[1].
> 
> Resending this because I missed copying the DT and Documentation folks
> last time around. Sorry about that. There is no change in patch contents.

I will be queuing these patches for inclusion in v3.8.

Thanks,
Sekhar

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

end of thread, other threads:[~2012-10-23 12:36 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-09-12 16:35 [PATCH RESEND 0/9] ARM: davinci: DT boot support for DA850 Sekhar Nori
     [not found] ` <1347467732-1332-1-git-send-email-nsekhar-l0cyMroinI0@public.gmane.org>
2012-09-12 16:35   ` [PATCH 1/9] ARM: davinci: uncompress.h: bail out if uart not initialized Sekhar Nori
2012-09-12 16:35   ` [PATCH 2/9] ARM: davinci: serial: provide API to initialze UART clocks Sekhar Nori
2012-09-12 16:35   ` [PATCH 3/9] ARM: davinci: arrange kconfig selects in alphabetical order Sekhar Nori
2012-09-12 16:35   ` [PATCH 4/9] ARM: davinci: da850: add DT boot support Sekhar Nori
2012-09-12 16:35   ` [PATCH 5/9] ARM: davinci: da850: add SoC DT data Sekhar Nori
2012-09-12 16:35   ` [PATCH 6/9] ARM: davinci: da850 evm: add " Sekhar Nori
2012-09-12 16:35   ` [PATCH 7/9] ARM: davinci: add support for am1808 based EnBW CMC board Sekhar Nori
2012-09-12 16:35   ` [PATCH 8/9] ARM: davinci: da850: generate dtbs for da850 boards Sekhar Nori
2012-09-12 16:35   ` [PATCH 9/9] ARM: davinci: da8xx defconfig: enable DT config options Sekhar Nori
2012-10-23 12:36 ` [PATCH RESEND 0/9] ARM: davinci: DT boot support for DA850 Sekhar Nori

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).