linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch
@ 2014-07-09 13:12 Laurent Pinchart
  2014-07-09 13:12 ` [PATCH v5 1/8] ARM: shmobile: r8a7790: Add CMT devices to DT Laurent Pinchart
                   ` (8 more replies)
  0 siblings, 9 replies; 22+ messages in thread
From: Laurent Pinchart @ 2014-07-09 13:12 UTC (permalink / raw)
  To: linux-arm-kernel

Hello,

This patch set enables timer devices in DT for the Marzen, Genmai, Lager and
Koelsch boards. It has previously been posted as part of the "[PATCH v4 00/19]
Renesas CMT, MTU2 and TMU timers DT support" series, and is now split into its
own patch set for merge in v3.17.

The series depends on the driver changes of the "[PATCH v4 00/19] Renesas CMT,
MTU2 and TMU timers DT support" series, for which a pull request has been sent.

Changes since v4:

- Rebased on top of Simon's latest devel branch
- Dropped driver patches merged through the clocksource tree

Changes since v3:

- Fixed TMU interrupt numbers
- Fixed NULL platform device ID dereference in TMU driver
- Removed interrupt-parent property from documentation
- Add missing of_match_ptr() and __maybe_unused() annotations

Changes since v2:

- Rebased on top of Simon's latest devel branch

Changes since v1:

- Dropped the channel subnodes from the CMT DT bindings and just use a
  channels mask, as we don't need to specify per-channel properties.

Laurent Pinchart (8):
  ARM: shmobile: r8a7790: Add CMT devices to DT
  ARM: shmobile: r8a7791: Add CMT devices to DT
  ARM: shmobile: r8a7779: Add TMU devices to DT
  ARM: shmobile: r7s72100: Add MTU2 device to DT
  ARM: shmobile: lager-reference: Enable CMT0 in device tree
  ARM: shmobile: koelsch-reference: Enable CMT0 in device tree
  ARM: shmobile: marzen-reference: Enable TMU0 in device tree
  ARM: shmobile: genmai-reference: Enable MTU2 in device tree

 arch/arm/boot/dts/r7s72100-genmai.dts            |  4 +++
 arch/arm/boot/dts/r7s72100.dtsi                  | 10 ++++++
 arch/arm/boot/dts/r8a7779-marzen.dts             |  4 +++
 arch/arm/boot/dts/r8a7779.dtsi                   | 42 ++++++++++++++++++++++++
 arch/arm/boot/dts/r8a7790-lager.dts              |  4 +++
 arch/arm/boot/dts/r8a7790.dtsi                   | 32 ++++++++++++++++++
 arch/arm/boot/dts/r8a7791-koelsch.dts            |  4 +++
 arch/arm/boot/dts/r8a7791.dtsi                   | 32 ++++++++++++++++++
 arch/arm/mach-shmobile/board-genmai-reference.c  | 20 -----------
 arch/arm/mach-shmobile/board-genmai.c            | 14 +++++++-
 arch/arm/mach-shmobile/board-koelsch-reference.c |  2 --
 arch/arm/mach-shmobile/board-lager-reference.c   |  2 --
 arch/arm/mach-shmobile/board-marzen-reference.c  | 10 ------
 arch/arm/mach-shmobile/r7s72100.h                |  1 -
 arch/arm/mach-shmobile/r8a7779.h                 |  1 -
 arch/arm/mach-shmobile/r8a7790.h                 |  1 -
 arch/arm/mach-shmobile/r8a7791.h                 |  1 -
 arch/arm/mach-shmobile/setup-r7s72100.c          | 21 ------------
 arch/arm/mach-shmobile/setup-r8a7779.c           | 17 +++-------
 arch/arm/mach-shmobile/setup-r8a7790.c           |  7 +---
 arch/arm/mach-shmobile/setup-r8a7791.c           |  7 +---
 21 files changed, 152 insertions(+), 84 deletions(-)

-- 
Regards,

Laurent Pinchart

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

* [PATCH v5 1/8] ARM: shmobile: r8a7790: Add CMT devices to DT
  2014-07-09 13:12 [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Laurent Pinchart
@ 2014-07-09 13:12 ` Laurent Pinchart
  2014-07-09 13:12 ` [PATCH v5 2/8] ARM: shmobile: r8a7791: " Laurent Pinchart
                   ` (7 subsequent siblings)
  8 siblings, 0 replies; 22+ messages in thread
From: Laurent Pinchart @ 2014-07-09 13:12 UTC (permalink / raw)
  To: linux-arm-kernel

Add the CMT0 and CMT1 counters to the r8a7790 device tree and make them
disabled by default.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Tested-by: Simon Horman <horms+renesas@verge.net.au>
---
 arch/arm/boot/dts/r8a7790.dtsi | 32 ++++++++++++++++++++++++++++++++
 1 file changed, 32 insertions(+)

diff --git a/arch/arm/boot/dts/r8a7790.dtsi b/arch/arm/boot/dts/r8a7790.dtsi
index bdcb7f0..2e65c30 100644
--- a/arch/arm/boot/dts/r8a7790.dtsi
+++ b/arch/arm/boot/dts/r8a7790.dtsi
@@ -206,6 +206,38 @@
 			     <1 10 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>;
 	};
 
+	cmt0: timer at ffca0000 {
+		compatible = "renesas,cmt-48-gen2";
+		reg = <0 0xffca0000 0 0x1004>;
+		interrupts = <0 142 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 143 IRQ_TYPE_LEVEL_HIGH>;
+		clocks = <&mstp1_clks R8A7790_CLK_CMT0>;
+		clock-names = "fck";
+
+		renesas,channels-mask = <0x60>;
+
+		status = "disabled";
+	};
+
+	cmt1: timer at e6130000 {
+		compatible = "renesas,cmt-48-gen2";
+		reg = <0 0xe6130000 0 0x1004>;
+		interrupts = <0 120 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 121 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 122 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 123 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 124 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 125 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 126 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 127 IRQ_TYPE_LEVEL_HIGH>;
+		clocks = <&mstp3_clks R8A7790_CLK_CMT1>;
+		clock-names = "fck";
+
+		renesas,channels-mask = <0xff>;
+
+		status = "disabled";
+	};
+
 	irqc0: interrupt-controller at e61c0000 {
 		compatible = "renesas,irqc-r8a7790", "renesas,irqc";
 		#interrupt-cells = <2>;
-- 
1.8.5.5

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

* [PATCH v5 2/8] ARM: shmobile: r8a7791: Add CMT devices to DT
  2014-07-09 13:12 [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Laurent Pinchart
  2014-07-09 13:12 ` [PATCH v5 1/8] ARM: shmobile: r8a7790: Add CMT devices to DT Laurent Pinchart
@ 2014-07-09 13:12 ` Laurent Pinchart
  2014-07-09 13:12 ` [PATCH v5 3/8] ARM: shmobile: r8a7779: Add TMU " Laurent Pinchart
                   ` (6 subsequent siblings)
  8 siblings, 0 replies; 22+ messages in thread
From: Laurent Pinchart @ 2014-07-09 13:12 UTC (permalink / raw)
  To: linux-arm-kernel

Add the CMT0 and CMT1 counters to the r8a7791 device tree and make them
disabled by default.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Tested-by: Simon Horman <horms+renesas@verge.net.au>
---
 arch/arm/boot/dts/r8a7791.dtsi | 32 ++++++++++++++++++++++++++++++++
 1 file changed, 32 insertions(+)

diff --git a/arch/arm/boot/dts/r8a7791.dtsi b/arch/arm/boot/dts/r8a7791.dtsi
index 336a6c0..acca93e 100644
--- a/arch/arm/boot/dts/r8a7791.dtsi
+++ b/arch/arm/boot/dts/r8a7791.dtsi
@@ -189,6 +189,38 @@
 			     <1 10 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>;
 	};
 
+	cmt0: timer at ffca0000 {
+		compatible = "renesas,cmt-48-gen2";
+		reg = <0 0xffca0000 0 0x1004>;
+		interrupts = <0 142 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 143 IRQ_TYPE_LEVEL_HIGH>;
+		clocks = <&mstp1_clks R8A7791_CLK_CMT0>;
+		clock-names = "fck";
+
+		renesas,channels-mask = <0x60>;
+
+		status = "disabled";
+	};
+
+	cmt1: timer at e6130000 {
+		compatible = "renesas,cmt-48-gen2";
+		reg = <0 0xe6130000 0 0x1004>;
+		interrupts = <0 120 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 121 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 122 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 123 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 124 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 125 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 126 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 127 IRQ_TYPE_LEVEL_HIGH>;
+		clocks = <&mstp3_clks R8A7791_CLK_CMT1>;
+		clock-names = "fck";
+
+		renesas,channels-mask = <0xff>;
+
+		status = "disabled";
+	};
+
 	irqc0: interrupt-controller at e61c0000 {
 		compatible = "renesas,irqc-r8a7791", "renesas,irqc";
 		#interrupt-cells = <2>;
-- 
1.8.5.5

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

* [PATCH v5 3/8] ARM: shmobile: r8a7779: Add TMU devices to DT
  2014-07-09 13:12 [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Laurent Pinchart
  2014-07-09 13:12 ` [PATCH v5 1/8] ARM: shmobile: r8a7790: Add CMT devices to DT Laurent Pinchart
  2014-07-09 13:12 ` [PATCH v5 2/8] ARM: shmobile: r8a7791: " Laurent Pinchart
@ 2014-07-09 13:12 ` Laurent Pinchart
  2014-07-09 13:12 ` [PATCH v5 4/8] ARM: shmobile: r7s72100: Add MTU2 device " Laurent Pinchart
                   ` (5 subsequent siblings)
  8 siblings, 0 replies; 22+ messages in thread
From: Laurent Pinchart @ 2014-07-09 13:12 UTC (permalink / raw)
  To: linux-arm-kernel

Add the TMU0, TMU1 and TMU2 counters to the r8a7779 device tree and make
them disabled by default.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Tested-by: Simon Horman <horms+renesas@verge.net.au>
---
 arch/arm/boot/dts/r8a7779.dtsi | 42 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 42 insertions(+)

diff --git a/arch/arm/boot/dts/r8a7779.dtsi b/arch/arm/boot/dts/r8a7779.dtsi
index 94e2fc8..671d8e4 100644
--- a/arch/arm/boot/dts/r8a7779.dtsi
+++ b/arch/arm/boot/dts/r8a7779.dtsi
@@ -266,6 +266,48 @@
 		reg = <0xffc48000 0x38>;
 	};
 
+	tmu0: timer at ffd80000 {
+		compatible = "renesas,tmu";
+		reg = <0xffd80000 0x30>;
+		interrupts = <0 32 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 33 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 34 IRQ_TYPE_LEVEL_HIGH>;
+		clocks = <&mstp0_clks R8A7779_CLK_TMU0>;
+		clock-names = "fck";
+
+		#renesas,channels = <3>;
+
+		status = "disabled";
+	};
+
+	tmu1: timer at ffd81000 {
+		compatible = "renesas,tmu";
+		reg = <0xffd81000 0x30>;
+		interrupts = <0 36 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 37 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 38 IRQ_TYPE_LEVEL_HIGH>;
+		clocks = <&mstp0_clks R8A7779_CLK_TMU1>;
+		clock-names = "fck";
+
+		#renesas,channels = <3>;
+
+		status = "disabled";
+	};
+
+	tmu2: timer at ffd82000 {
+		compatible = "renesas,tmu";
+		reg = <0xffd82000 0x30>;
+		interrupts = <0 40 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 41 IRQ_TYPE_LEVEL_HIGH>,
+			     <0 42 IRQ_TYPE_LEVEL_HIGH>;
+		clocks = <&mstp0_clks R8A7779_CLK_TMU2>;
+		clock-names = "fck";
+
+		#renesas,channels = <3>;
+
+		status = "disabled";
+	};
+
 	sata: sata at fc600000 {
 		compatible = "renesas,rcar-sata";
 		reg = <0xfc600000 0x2000>;
-- 
1.8.5.5

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

* [PATCH v5 4/8] ARM: shmobile: r7s72100: Add MTU2 device to DT
  2014-07-09 13:12 [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Laurent Pinchart
                   ` (2 preceding siblings ...)
  2014-07-09 13:12 ` [PATCH v5 3/8] ARM: shmobile: r8a7779: Add TMU " Laurent Pinchart
@ 2014-07-09 13:12 ` Laurent Pinchart
  2014-07-10  9:53   ` Wolfram Sang
  2014-07-15 11:47   ` Simon Horman
  2014-07-09 13:12 ` [PATCH v5 5/8] ARM: shmobile: lager-reference: Enable CMT0 in device tree Laurent Pinchart
                   ` (4 subsequent siblings)
  8 siblings, 2 replies; 22+ messages in thread
From: Laurent Pinchart @ 2014-07-09 13:12 UTC (permalink / raw)
  To: linux-arm-kernel

Add the MTU2 counter to the r7s72100 device tree and make it disabled by
default.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
---
 arch/arm/boot/dts/r7s72100.dtsi | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/arch/arm/boot/dts/r7s72100.dtsi b/arch/arm/boot/dts/r7s72100.dtsi
index bdee225..c902b0b 100644
--- a/arch/arm/boot/dts/r7s72100.dtsi
+++ b/arch/arm/boot/dts/r7s72100.dtsi
@@ -229,6 +229,16 @@
 		status = "disabled";
 	};
 
+	mtu2: timer at fcff0000 {
+		compatible = "renesas,mtu2";
+		reg = <0xfcff0000 0x400>;
+		interrupts = <0 139 IRQ_TYPE_LEVEL_HIGH>;
+		interrupt-names = "tgi0a";
+		clocks = <&mstp3_clks R7S72100_CLK_MTU2>;
+		clock-names = "fck";
+		status = "disabled";
+	};
+
 	scif0: serial at e8007000 {
 		compatible = "renesas,scif-r7s72100", "renesas,scif";
 		reg = <0xe8007000 64>;
-- 
1.8.5.5

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

* [PATCH v5 5/8] ARM: shmobile: lager-reference: Enable CMT0 in device tree
  2014-07-09 13:12 [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Laurent Pinchart
                   ` (3 preceding siblings ...)
  2014-07-09 13:12 ` [PATCH v5 4/8] ARM: shmobile: r7s72100: Add MTU2 device " Laurent Pinchart
@ 2014-07-09 13:12 ` Laurent Pinchart
  2014-07-09 13:12 ` [PATCH v5 6/8] ARM: shmobile: koelsch-reference: " Laurent Pinchart
                   ` (3 subsequent siblings)
  8 siblings, 0 replies; 22+ messages in thread
From: Laurent Pinchart @ 2014-07-09 13:12 UTC (permalink / raw)
  To: linux-arm-kernel

No more device needs to be added from platform code when booting the
reference platform, remove the now empty r8a7790_add_dt_devices()
function completely.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Tested-by: Simon Horman <horms+renesas@verge.net.au>
---
 arch/arm/boot/dts/r8a7790-lager.dts            | 4 ++++
 arch/arm/mach-shmobile/board-lager-reference.c | 2 --
 arch/arm/mach-shmobile/r8a7790.h               | 1 -
 arch/arm/mach-shmobile/setup-r8a7790.c         | 7 +------
 4 files changed, 5 insertions(+), 9 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7790-lager.dts b/arch/arm/boot/dts/r8a7790-lager.dts
index 544202b..d22cee4 100644
--- a/arch/arm/boot/dts/r8a7790-lager.dts
+++ b/arch/arm/boot/dts/r8a7790-lager.dts
@@ -252,6 +252,10 @@
 	};
 };
 
+&cmt0 {
+	status = "ok";
+};
+
 &mmcif1 {
 	pinctrl-0 = <&mmc1_pins>;
 	pinctrl-names = "default";
diff --git a/arch/arm/mach-shmobile/board-lager-reference.c b/arch/arm/mach-shmobile/board-lager-reference.c
index 41c808e..2a05c02 100644
--- a/arch/arm/mach-shmobile/board-lager-reference.c
+++ b/arch/arm/mach-shmobile/board-lager-reference.c
@@ -92,7 +92,6 @@ static void __init lager_add_du_device(void)
  * devices until they get moved to DT.
  */
 static const struct clk_name clk_names[] __initconst = {
-	{ "cmt0", "fck", "sh-cmt-48-gen2.0" },
 	{ "du0", "du.0", "rcar-du-r8a7790" },
 	{ "du1", "du.1", "rcar-du-r8a7790" },
 	{ "du2", "du.2", "rcar-du-r8a7790" },
@@ -103,7 +102,6 @@ static const struct clk_name clk_names[] __initconst = {
 static void __init lager_add_standard_devices(void)
 {
 	shmobile_clk_workaround(clk_names, ARRAY_SIZE(clk_names), false);
-	r8a7790_add_dt_devices();
 	of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
 
 	lager_add_du_device();
diff --git a/arch/arm/mach-shmobile/r8a7790.h b/arch/arm/mach-shmobile/r8a7790.h
index 459827f..388f051 100644
--- a/arch/arm/mach-shmobile/r8a7790.h
+++ b/arch/arm/mach-shmobile/r8a7790.h
@@ -27,7 +27,6 @@ enum {
 };
 
 void r8a7790_add_standard_devices(void);
-void r8a7790_add_dt_devices(void);
 void r8a7790_clock_init(void);
 void r8a7790_pinmux_init(void);
 void r8a7790_pm_init(void);
diff --git a/arch/arm/mach-shmobile/setup-r8a7790.c b/arch/arm/mach-shmobile/setup-r8a7790.c
index c37d82d..4795c98 100644
--- a/arch/arm/mach-shmobile/setup-r8a7790.c
+++ b/arch/arm/mach-shmobile/setup-r8a7790.c
@@ -282,11 +282,6 @@ static struct resource cmt0_resources[] = {
 					  &cmt##idx##_platform_data,	\
 					  sizeof(struct sh_timer_config))
 
-void __init r8a7790_add_dt_devices(void)
-{
-	r8a7790_register_cmt(0);
-}
-
 void __init r8a7790_add_standard_devices(void)
 {
 	r8a7790_register_scif(0);
@@ -299,7 +294,7 @@ void __init r8a7790_add_standard_devices(void)
 	r8a7790_register_scif(7);
 	r8a7790_register_scif(8);
 	r8a7790_register_scif(9);
-	r8a7790_add_dt_devices();
+	r8a7790_register_cmt(0);
 	r8a7790_register_irqc(0);
 	r8a7790_register_thermal();
 	r8a7790_register_i2c(0);
-- 
1.8.5.5

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

* [PATCH v5 6/8] ARM: shmobile: koelsch-reference: Enable CMT0 in device tree
  2014-07-09 13:12 [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Laurent Pinchart
                   ` (4 preceding siblings ...)
  2014-07-09 13:12 ` [PATCH v5 5/8] ARM: shmobile: lager-reference: Enable CMT0 in device tree Laurent Pinchart
@ 2014-07-09 13:12 ` Laurent Pinchart
  2014-07-09 13:12 ` [PATCH v5 7/8] ARM: shmobile: marzen-reference: Enable TMU0 " Laurent Pinchart
                   ` (2 subsequent siblings)
  8 siblings, 0 replies; 22+ messages in thread
From: Laurent Pinchart @ 2014-07-09 13:12 UTC (permalink / raw)
  To: linux-arm-kernel

No more device needs to be added from platform code when booting the
reference platform, remove the now empty r8a7791_add_dt_devices()
function completely.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Tested-by: Simon Horman <horms+renesas@verge.net.au>
---
 arch/arm/boot/dts/r8a7791-koelsch.dts            | 4 ++++
 arch/arm/mach-shmobile/board-koelsch-reference.c | 2 --
 arch/arm/mach-shmobile/r8a7791.h                 | 1 -
 arch/arm/mach-shmobile/setup-r8a7791.c           | 7 +------
 4 files changed, 5 insertions(+), 9 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7791-koelsch.dts b/arch/arm/boot/dts/r8a7791-koelsch.dts
index 5dac673..7817ca8 100644
--- a/arch/arm/boot/dts/r8a7791-koelsch.dts
+++ b/arch/arm/boot/dts/r8a7791-koelsch.dts
@@ -297,6 +297,10 @@
 	};
 };
 
+&cmt0 {
+	status = "ok";
+};
+
 &sata0 {
 	status = "okay";
 };
diff --git a/arch/arm/mach-shmobile/board-koelsch-reference.c b/arch/arm/mach-shmobile/board-koelsch-reference.c
index 3ff88c1..9db5e67 100644
--- a/arch/arm/mach-shmobile/board-koelsch-reference.c
+++ b/arch/arm/mach-shmobile/board-koelsch-reference.c
@@ -88,7 +88,6 @@ static void __init koelsch_add_du_device(void)
  * devices until they get moved to DT.
  */
 static const struct clk_name clk_names[] __initconst = {
-	{ "cmt0", "fck", "sh-cmt-48-gen2.0" },
 	{ "du0", "du.0", "rcar-du-r8a7791" },
 	{ "du1", "du.1", "rcar-du-r8a7791" },
 	{ "lvds0", "lvds.0", "rcar-du-r8a7791" },
@@ -97,7 +96,6 @@ static const struct clk_name clk_names[] __initconst = {
 static void __init koelsch_add_standard_devices(void)
 {
 	shmobile_clk_workaround(clk_names, ARRAY_SIZE(clk_names), false);
-	r8a7791_add_dt_devices();
 	of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
 
 	koelsch_add_du_device();
diff --git a/arch/arm/mach-shmobile/r8a7791.h b/arch/arm/mach-shmobile/r8a7791.h
index 86eae7b..c1bf7ab 100644
--- a/arch/arm/mach-shmobile/r8a7791.h
+++ b/arch/arm/mach-shmobile/r8a7791.h
@@ -2,7 +2,6 @@
 #define __ASM_R8A7791_H__
 
 void r8a7791_add_standard_devices(void);
-void r8a7791_add_dt_devices(void);
 void r8a7791_clock_init(void);
 void r8a7791_pinmux_init(void);
 void r8a7791_pm_init(void);
diff --git a/arch/arm/mach-shmobile/setup-r8a7791.c b/arch/arm/mach-shmobile/setup-r8a7791.c
index 8823324..64cb1d7 100644
--- a/arch/arm/mach-shmobile/setup-r8a7791.c
+++ b/arch/arm/mach-shmobile/setup-r8a7791.c
@@ -182,11 +182,6 @@ static const struct resource thermal_resources[] __initconst = {
 					thermal_resources,		\
 					ARRAY_SIZE(thermal_resources))
 
-void __init r8a7791_add_dt_devices(void)
-{
-	r8a7791_register_cmt(0);
-}
-
 void __init r8a7791_add_standard_devices(void)
 {
 	r8a7791_register_scif(0);
@@ -204,7 +199,7 @@ void __init r8a7791_add_standard_devices(void)
 	r8a7791_register_scif(12);
 	r8a7791_register_scif(13);
 	r8a7791_register_scif(14);
-	r8a7791_add_dt_devices();
+	r8a7791_register_cmt(0);
 	r8a7791_register_irqc(0);
 	r8a7791_register_thermal();
 }
-- 
1.8.5.5

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

* [PATCH v5 7/8] ARM: shmobile: marzen-reference: Enable TMU0 in device tree
  2014-07-09 13:12 [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Laurent Pinchart
                   ` (5 preceding siblings ...)
  2014-07-09 13:12 ` [PATCH v5 6/8] ARM: shmobile: koelsch-reference: " Laurent Pinchart
@ 2014-07-09 13:12 ` Laurent Pinchart
  2014-07-09 13:12 ` [PATCH v5 8/8] ARM: shmobile: genmai-reference: Enable MTU2 " Laurent Pinchart
  2014-07-15  5:01 ` [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Simon Horman
  8 siblings, 0 replies; 22+ messages in thread
From: Laurent Pinchart @ 2014-07-09 13:12 UTC (permalink / raw)
  To: linux-arm-kernel

No more device needs to be added from platform code when booting the
reference platform, remove the now empty
r8a7779_add_standard_devices_dt() function completely.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Tested-by: Simon Horman <horms+renesas@verge.net.au>
---
 arch/arm/boot/dts/r8a7779-marzen.dts            |  4 ++++
 arch/arm/mach-shmobile/board-marzen-reference.c | 10 ----------
 arch/arm/mach-shmobile/r8a7779.h                |  1 -
 arch/arm/mach-shmobile/setup-r8a7779.c          | 17 +++++------------
 4 files changed, 9 insertions(+), 23 deletions(-)

diff --git a/arch/arm/boot/dts/r8a7779-marzen.dts b/arch/arm/boot/dts/r8a7779-marzen.dts
index 20b1768..6025822 100644
--- a/arch/arm/boot/dts/r8a7779-marzen.dts
+++ b/arch/arm/boot/dts/r8a7779-marzen.dts
@@ -78,6 +78,10 @@
 	clock-frequency = <31250000>;
 };
 
+&tmu0 {
+	status = "okay";
+};
+
 &pfc {
 	lan0_pins: lan0 {
 		intc {
diff --git a/arch/arm/mach-shmobile/board-marzen-reference.c b/arch/arm/mach-shmobile/board-marzen-reference.c
index 21b3e1c..f671003 100644
--- a/arch/arm/mach-shmobile/board-marzen-reference.c
+++ b/arch/arm/mach-shmobile/board-marzen-reference.c
@@ -37,18 +37,8 @@ static void __init marzen_init_timer(void)
 	clocksource_of_init();
 }
 
-/*
- * This is a really crude hack to provide clkdev support to platform
- * devices until they get moved to DT.
- */
-static const struct clk_name clk_names[] __initconst = {
-	{ "tmu0", "fck", "sh-tmu.0" },
-};
-
 static void __init marzen_init(void)
 {
-	shmobile_clk_workaround(clk_names, ARRAY_SIZE(clk_names), false);
-	r8a7779_add_standard_devices_dt();
 	of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
 	r8a7779_init_irq_extpin_dt(1); /* IRQ1 as individual interrupt */
 }
diff --git a/arch/arm/mach-shmobile/r8a7779.h b/arch/arm/mach-shmobile/r8a7779.h
index 5415c71..19f9704 100644
--- a/arch/arm/mach-shmobile/r8a7779.h
+++ b/arch/arm/mach-shmobile/r8a7779.h
@@ -17,7 +17,6 @@ extern void r8a7779_map_io(void);
 extern void r8a7779_earlytimer_init(void);
 extern void r8a7779_add_early_devices(void);
 extern void r8a7779_add_standard_devices(void);
-extern void r8a7779_add_standard_devices_dt(void);
 extern void r8a7779_init_late(void);
 extern u32 r8a7779_read_mode_pins(void);
 extern void r8a7779_clock_init(void);
diff --git a/arch/arm/mach-shmobile/setup-r8a7779.c b/arch/arm/mach-shmobile/setup-r8a7779.c
index 8dbc407..8c0530d 100644
--- a/arch/arm/mach-shmobile/setup-r8a7779.c
+++ b/arch/arm/mach-shmobile/setup-r8a7779.c
@@ -641,7 +641,7 @@ static void __init r8a7779_register_hpb_dmae(void)
 					  sizeof(dma_platform_data));
 }
 
-static struct platform_device *r8a7779_devices_dt[] __initdata = {
+static struct platform_device *r8a7779_early_devices[] __initdata = {
 	&tmu0_device,
 };
 
@@ -669,8 +669,8 @@ void __init r8a7779_add_standard_devices(void)
 
 	r8a7779_init_pm_domains();
 
-	platform_add_devices(r8a7779_devices_dt,
-			    ARRAY_SIZE(r8a7779_devices_dt));
+	platform_add_devices(r8a7779_early_devices,
+			    ARRAY_SIZE(r8a7779_early_devices));
 	platform_add_devices(r8a7779_standard_devices,
 			    ARRAY_SIZE(r8a7779_standard_devices));
 	r8a7779_register_hpb_dmae();
@@ -678,8 +678,8 @@ void __init r8a7779_add_standard_devices(void)
 
 void __init r8a7779_add_early_devices(void)
 {
-	early_platform_add_devices(r8a7779_devices_dt,
-				   ARRAY_SIZE(r8a7779_devices_dt));
+	early_platform_add_devices(r8a7779_early_devices,
+				   ARRAY_SIZE(r8a7779_early_devices));
 
 	/* Early serial console setup is not included here due to
 	 * memory map collisions. The SCIF serial ports in r8a7779
@@ -739,12 +739,6 @@ void __init r8a7779_init_irq_dt(void)
 	__raw_writel(0x003fee3f, INT2SMSKCR4);
 }
 
-void __init r8a7779_add_standard_devices_dt(void)
-{
-	platform_add_devices(r8a7779_devices_dt,
-			     ARRAY_SIZE(r8a7779_devices_dt));
-}
-
 #define MODEMR		0xffcc0020
 
 u32 __init r8a7779_read_mode_pins(void)
@@ -773,7 +767,6 @@ DT_MACHINE_START(R8A7779_DT, "Generic R8A7779 (Flattened Device Tree)")
 	.init_early	= shmobile_init_delay,
 	.nr_irqs	= NR_IRQS_LEGACY,
 	.init_irq	= r8a7779_init_irq_dt,
-	.init_machine	= r8a7779_add_standard_devices_dt,
 	.init_late	= r8a7779_init_late,
 	.dt_compat	= r8a7779_compat_dt,
 MACHINE_END
-- 
1.8.5.5

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

* [PATCH v5 8/8] ARM: shmobile: genmai-reference: Enable MTU2 in device tree
  2014-07-09 13:12 [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Laurent Pinchart
                   ` (6 preceding siblings ...)
  2014-07-09 13:12 ` [PATCH v5 7/8] ARM: shmobile: marzen-reference: Enable TMU0 " Laurent Pinchart
@ 2014-07-09 13:12 ` Laurent Pinchart
  2014-07-10  9:54   ` Wolfram Sang
  2014-07-15  5:01 ` [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Simon Horman
  8 siblings, 1 reply; 22+ messages in thread
From: Laurent Pinchart @ 2014-07-09 13:12 UTC (permalink / raw)
  To: linux-arm-kernel

No more device needs to be added from platform code when booting the
reference platform, move MTU2 registration from setup-r7s72100.c to
board-genmai.c and remove the now empty r7s72100_add_dt_devices()
function.

As the genmai_add_standard_devices() function is now identical to the
default init_machine implementation, remove it as well.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
---
 arch/arm/boot/dts/r7s72100-genmai.dts           |  4 ++++
 arch/arm/mach-shmobile/board-genmai-reference.c | 20 --------------------
 arch/arm/mach-shmobile/board-genmai.c           | 14 +++++++++++++-
 arch/arm/mach-shmobile/r7s72100.h               |  1 -
 arch/arm/mach-shmobile/setup-r7s72100.c         | 21 ---------------------
 5 files changed, 17 insertions(+), 43 deletions(-)

diff --git a/arch/arm/boot/dts/r7s72100-genmai.dts b/arch/arm/boot/dts/r7s72100-genmai.dts
index 56849b5..a352734 100644
--- a/arch/arm/boot/dts/r7s72100-genmai.dts
+++ b/arch/arm/boot/dts/r7s72100-genmai.dts
@@ -43,6 +43,10 @@
 	clock-frequency = <48000000>;
 };
 
+&mtu2 {
+	status = "ok";
+};
+
 &i2c2 {
 	status = "okay";
 	clock-frequency = <400000>;
diff --git a/arch/arm/mach-shmobile/board-genmai-reference.c b/arch/arm/mach-shmobile/board-genmai-reference.c
index e5448f7..bc52677 100644
--- a/arch/arm/mach-shmobile/board-genmai-reference.c
+++ b/arch/arm/mach-shmobile/board-genmai-reference.c
@@ -19,29 +19,10 @@
  */
 
 #include <linux/kernel.h>
-#include <linux/of_platform.h>
 
-#include <asm/mach-types.h>
 #include <asm/mach/arch.h>
 
-#include "clock.h"
 #include "common.h"
-#include "r7s72100.h"
-
-/*
- * This is a really crude hack to provide clkdev support to platform
- * devices until they get moved to DT.
- */
-static const struct clk_name clk_names[] = {
-	{ "mtu2", "fck", "sh-mtu2" },
-};
-
-static void __init genmai_add_standard_devices(void)
-{
-	shmobile_clk_workaround(clk_names, ARRAY_SIZE(clk_names), true);
-	r7s72100_add_dt_devices();
-	of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
-}
 
 static const char * const genmai_boards_compat_dt[] __initconst = {
 	"renesas,genmai",
@@ -50,6 +31,5 @@ static const char * const genmai_boards_compat_dt[] __initconst = {
 
 DT_MACHINE_START(GENMAI_DT, "genmai")
 	.init_early	= shmobile_init_delay,
-	.init_machine	= genmai_add_standard_devices,
 	.dt_compat	= genmai_boards_compat_dt,
 MACHINE_END
diff --git a/arch/arm/mach-shmobile/board-genmai.c b/arch/arm/mach-shmobile/board-genmai.c
index e2a3ba4..b5dee53 100644
--- a/arch/arm/mach-shmobile/board-genmai.c
+++ b/arch/arm/mach-shmobile/board-genmai.c
@@ -23,6 +23,7 @@
 #include <linux/platform_device.h>
 #include <linux/serial_sci.h>
 #include <linux/sh_eth.h>
+#include <linux/sh_timer.h>
 #include <linux/spi/rspi.h>
 #include <linux/spi/spi.h>
 
@@ -126,10 +127,21 @@ R7S72100_SCIF(7, 0xe800a800, gic_iid(249));
 					  &scif##index##_platform_data,	       \
 					  sizeof(scif##index##_platform_data))
 
+static struct resource mtu2_resources[] __initdata = {
+	DEFINE_RES_MEM(0xfcff0000, 0x400),
+	DEFINE_RES_IRQ_NAMED(gic_iid(139), "tgi0a"),
+};
+
+#define r7s72100_register_mtu2()					\
+	platform_device_register_resndata(&platform_bus, "sh-mtu2",	\
+					  -1, mtu2_resources,		\
+					  ARRAY_SIZE(mtu2_resources),	\
+					  NULL, 0)
+
 static void __init genmai_add_standard_devices(void)
 {
 	r7s72100_clock_init();
-	r7s72100_add_dt_devices();
+	r7s72100_register_mtu2();
 
 	platform_device_register_full(&ether_info);
 
diff --git a/arch/arm/mach-shmobile/r7s72100.h b/arch/arm/mach-shmobile/r7s72100.h
index efb723c..321ae4e 100644
--- a/arch/arm/mach-shmobile/r7s72100.h
+++ b/arch/arm/mach-shmobile/r7s72100.h
@@ -1,7 +1,6 @@
 #ifndef __ASM_R7S72100_H__
 #define __ASM_R7S72100_H__
 
-void r7s72100_add_dt_devices(void);
 void r7s72100_clock_init(void);
 
 #endif /* __ASM_R7S72100_H__ */
diff --git a/arch/arm/mach-shmobile/setup-r7s72100.c b/arch/arm/mach-shmobile/setup-r7s72100.c
index 4a98b23..d898cef 100644
--- a/arch/arm/mach-shmobile/setup-r7s72100.c
+++ b/arch/arm/mach-shmobile/setup-r7s72100.c
@@ -18,32 +18,11 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
  */
 
-#include <linux/irq.h>
 #include <linux/kernel.h>
-#include <linux/of_platform.h>
-#include <linux/sh_timer.h>
 
 #include <asm/mach/arch.h>
 
 #include "common.h"
-#include "irqs.h"
-#include "r7s72100.h"
-
-static struct resource mtu2_resources[] __initdata = {
-	DEFINE_RES_MEM(0xfcff0000, 0x400),
-	DEFINE_RES_IRQ_NAMED(gic_iid(139), "tgi0a"),
-};
-
-#define r7s72100_register_mtu2()					\
-	platform_device_register_resndata(&platform_bus, "sh-mtu2",	\
-					  -1, mtu2_resources,		\
-					  ARRAY_SIZE(mtu2_resources),	\
-					  NULL, 0)
-
-void __init r7s72100_add_dt_devices(void)
-{
-	r7s72100_register_mtu2();
-}
 
 #ifdef CONFIG_USE_OF
 static const char *r7s72100_boards_compat_dt[] __initdata = {
-- 
1.8.5.5

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

* [PATCH v5 4/8] ARM: shmobile: r7s72100: Add MTU2 device to DT
  2014-07-09 13:12 ` [PATCH v5 4/8] ARM: shmobile: r7s72100: Add MTU2 device " Laurent Pinchart
@ 2014-07-10  9:53   ` Wolfram Sang
  2014-07-15 11:47   ` Simon Horman
  1 sibling, 0 replies; 22+ messages in thread
From: Wolfram Sang @ 2014-07-10  9:53 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Jul 09, 2014 at 03:12:40PM +0200, Laurent Pinchart wrote:
> Add the MTU2 counter to the r7s72100 device tree and make it disabled by
> default.
> 
> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>

Acked-by: Wolfram Sang <wsa+renesas@sang-engineering.com>

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20140710/a55086e1/attachment.sig>

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

* [PATCH v5 8/8] ARM: shmobile: genmai-reference: Enable MTU2 in device tree
  2014-07-09 13:12 ` [PATCH v5 8/8] ARM: shmobile: genmai-reference: Enable MTU2 " Laurent Pinchart
@ 2014-07-10  9:54   ` Wolfram Sang
  2014-07-15  8:54     ` Simon Horman
  0 siblings, 1 reply; 22+ messages in thread
From: Wolfram Sang @ 2014-07-10  9:54 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Jul 09, 2014 at 03:12:44PM +0200, Laurent Pinchart wrote:
> No more device needs to be added from platform code when booting the
> reference platform, move MTU2 registration from setup-r7s72100.c to
> board-genmai.c and remove the now empty r7s72100_add_dt_devices()
> function.
> 
> As the genmai_add_standard_devices() function is now identical to the
> default init_machine implementation, remove it as well.
> 
> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>

Yay, tasty!

Reviewed-by: Wolfram Sang <wsa@sang-engineering.com>

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20140710/6021a48d/attachment.sig>

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

* [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch
  2014-07-09 13:12 [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Laurent Pinchart
                   ` (7 preceding siblings ...)
  2014-07-09 13:12 ` [PATCH v5 8/8] ARM: shmobile: genmai-reference: Enable MTU2 " Laurent Pinchart
@ 2014-07-15  5:01 ` Simon Horman
  2014-07-15  8:55   ` Simon Horman
  8 siblings, 1 reply; 22+ messages in thread
From: Simon Horman @ 2014-07-15  5:01 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Jul 09, 2014 at 03:12:36PM +0200, Laurent Pinchart wrote:
> Hello,
> 
> This patch set enables timer devices in DT for the Marzen, Genmai, Lager and
> Koelsch boards. It has previously been posted as part of the "[PATCH v4 00/19]
> Renesas CMT, MTU2 and TMU timers DT support" series, and is now split into its
> own patch set for merge in v3.17.
> 
> The series depends on the driver changes of the "[PATCH v4 00/19] Renesas CMT,
> MTU2 and TMU timers DT support" series, for which a pull request has been sent.

Thanks, I have queued these up.

> 
> Changes since v4:
> 
> - Rebased on top of Simon's latest devel branch
> - Dropped driver patches merged through the clocksource tree
> 
> Changes since v3:
> 
> - Fixed TMU interrupt numbers
> - Fixed NULL platform device ID dereference in TMU driver
> - Removed interrupt-parent property from documentation
> - Add missing of_match_ptr() and __maybe_unused() annotations
> 
> Changes since v2:
> 
> - Rebased on top of Simon's latest devel branch
> 
> Changes since v1:
> 
> - Dropped the channel subnodes from the CMT DT bindings and just use a
>   channels mask, as we don't need to specify per-channel properties.
> 
> Laurent Pinchart (8):
>   ARM: shmobile: r8a7790: Add CMT devices to DT
>   ARM: shmobile: r8a7791: Add CMT devices to DT
>   ARM: shmobile: r8a7779: Add TMU devices to DT
>   ARM: shmobile: r7s72100: Add MTU2 device to DT
>   ARM: shmobile: lager-reference: Enable CMT0 in device tree
>   ARM: shmobile: koelsch-reference: Enable CMT0 in device tree
>   ARM: shmobile: marzen-reference: Enable TMU0 in device tree
>   ARM: shmobile: genmai-reference: Enable MTU2 in device tree
> 
>  arch/arm/boot/dts/r7s72100-genmai.dts            |  4 +++
>  arch/arm/boot/dts/r7s72100.dtsi                  | 10 ++++++
>  arch/arm/boot/dts/r8a7779-marzen.dts             |  4 +++
>  arch/arm/boot/dts/r8a7779.dtsi                   | 42 ++++++++++++++++++++++++
>  arch/arm/boot/dts/r8a7790-lager.dts              |  4 +++
>  arch/arm/boot/dts/r8a7790.dtsi                   | 32 ++++++++++++++++++
>  arch/arm/boot/dts/r8a7791-koelsch.dts            |  4 +++
>  arch/arm/boot/dts/r8a7791.dtsi                   | 32 ++++++++++++++++++
>  arch/arm/mach-shmobile/board-genmai-reference.c  | 20 -----------
>  arch/arm/mach-shmobile/board-genmai.c            | 14 +++++++-
>  arch/arm/mach-shmobile/board-koelsch-reference.c |  2 --
>  arch/arm/mach-shmobile/board-lager-reference.c   |  2 --
>  arch/arm/mach-shmobile/board-marzen-reference.c  | 10 ------
>  arch/arm/mach-shmobile/r7s72100.h                |  1 -
>  arch/arm/mach-shmobile/r8a7779.h                 |  1 -
>  arch/arm/mach-shmobile/r8a7790.h                 |  1 -
>  arch/arm/mach-shmobile/r8a7791.h                 |  1 -
>  arch/arm/mach-shmobile/setup-r7s72100.c          | 21 ------------
>  arch/arm/mach-shmobile/setup-r8a7779.c           | 17 +++-------
>  arch/arm/mach-shmobile/setup-r8a7790.c           |  7 +---
>  arch/arm/mach-shmobile/setup-r8a7791.c           |  7 +---
>  21 files changed, 152 insertions(+), 84 deletions(-)
> 
> -- 
> Regards,
> 
> Laurent Pinchart
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sh" in
> the body of a message to majordomo at vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

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

* [PATCH v5 8/8] ARM: shmobile: genmai-reference: Enable MTU2 in device tree
  2014-07-10  9:54   ` Wolfram Sang
@ 2014-07-15  8:54     ` Simon Horman
  2014-07-15  8:58       ` Simon Horman
  0 siblings, 1 reply; 22+ messages in thread
From: Simon Horman @ 2014-07-15  8:54 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Jul 10, 2014 at 11:54:30AM +0200, Wolfram Sang wrote:
> On Wed, Jul 09, 2014 at 03:12:44PM +0200, Laurent Pinchart wrote:
> > No more device needs to be added from platform code when booting the
> > reference platform, move MTU2 registration from setup-r7s72100.c to
> > board-genmai.c and remove the now empty r7s72100_add_dt_devices()
> > function.
> > 
> > As the genmai_add_standard_devices() function is now identical to the
> > default init_machine implementation, remove it as well.
> > 
> > Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
> 
> Yay, tasty!
> 
> Reviewed-by: Wolfram Sang <wsa@sang-engineering.com>

Hi Laurent,

I am having some trouble with this patch.
In particular the shmobile defconfig with an initrd added
(to compensate for the lack of ethernet and thus NFS) does
not seem to make it to userspace with this patch applied :(

I am dropping it for now, but could you look into it?

For the record it seems to stop right near the end.
A bad boot looks like this:

Booting Linux on physical CPU 0x0
Linux version 3.16.0-rc3-00750-g004c383-dirty (horms at ayumi.isobedori.kobe.vergenet.net) (gcc version 4.6.3 (GCC) ) #463 SMP Tue Jul 15 16:58:01 JST 2014
CPU: ARMv7 Processor [413fc090] revision 0 (ARMv7), cr=18c5347d
CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
Machine model: Genmai
debug: ignoring loglevel setting.
Memory policy: Data cache writeback
On node 0 totalpages: 32768
free_area_init_node: node 0, pgdat c071f640, node_mem_map c7ef9000
  Normal zone: 256 pages used for memmap
  Normal zone: 0 pages reserved
  Normal zone: 32768 pages, LIFO batch:7
CPU: All CPU(s) started in SVC mode.
PERCPU: Embedded 5 pages/cpu @c7eea000 s7488 r0 d12992 u32768
pcpu-alloc: s7488 r0 d12992 u32768 alloc=8*4096
pcpu-alloc: [0] 0 
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 32512
Kernel command line: console=ttySC2,115200 ignore_loglevel rw root=/dev/nfs ip=dhcp
PID hash table entries: 512 (order: -1, 2048 bytes)
Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
Memory: 122388K/131072K available (4327K kernel code, 227K rwdata, 1016K rodata, 1691K init, 197K bss, 8684K reserved, 0K highmem)
Virtual kernel memory layout:
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    fixmap  : 0xffc00000 - 0xffe00000   (2048 kB)
    vmalloc : 0xc8800000 - 0xff000000   ( 872 MB)
    lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB)
    pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
      .text : 0xc0008000 - 0xc0540fc4   (5348 kB)
      .init : 0xc0541000 - 0xc06e7d40   (1692 kB)
      .data : 0xc06e8000 - 0xc0720dc0   ( 228 kB)
       .bss : 0xc0720dc8 - 0xc07521fc   ( 198 kB)
Hierarchical RCU implementation.
        RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
NR_IRQS:16 nr_irqs:16 16
clocksource_of_init: no matching clocksources found
sched_clock: 32 bits at 100 Hz, resolution 10000000ns, wraps every 21474836480000000ns
Console: colour dummy device 80x30
Calibrating delay loop (skipped) preset value.. 266.66 BogoMIPS (lpj=1333333)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
CPU: Testing write buffer coherency: ok
CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
Setting up static identity map for 0x84405f8 - 0x8440650
Brought up 1 CPUs
SMP: Total of 1 processors activated.
CPU: All CPU(s) started in SVC mode.
devtmpfs: initialized
VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
pinctrl core: initialized pinctrl subsystem
regulator-dummy: no parameters
NET: Registered protocol family 16
DMA: preallocated 256 KiB pool for atomic coherent allocations
No ATAGs?
hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.
hw-breakpoint: maximum watchpoint size is 4 bytes.
vgaarb: loaded
SCSI subsystem initialized
libata version 3.00 loaded.
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
media: Linux media interface: v0.10
Linux video capture interface: v2.00
sh_mtu2 fcff0000.timer: ch0: used for clock events
sh_mtu2 fcff0000.timer: ch0: used for periodic clock events
Advanced Linux Sound Architecture Driver Initialized.
NET: Registered protocol family 2
TCP established hash table entries: 1024 (order: 0, 4096 bytes)
TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
TCP: Hash tables configured (established 1024 bind 1024)
TCP: reno registered
UDP hash table entries: 256 (order: 1, 8192 bytes)
UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
NET: Registered protocol family 1
RPC: Registered named UNIX socket transport module.
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
RPC: Registered tcp NFSv4.1 backchannel transport module.
PCI: CLS 0 bytes, default 64
futex hash table entries: 256 (order: 2, 16384 bytes)
NFS: Registering the id_resolver key type
Key type id_resolver registered
Key type id_legacy registered
nfs4filelayout_init: NFSv4 File Layout Driver Registering...
msgmni has been set to 239
Block layer SCSI generic (bsg) driver version 0.4 loaded (major 252)
io scheduler noop registered
io scheduler deadline registered
io scheduler cfq registered (default)
Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
SuperH (H)SCI(F) driver initialized
e8008000.serial: ttySC2 at MMIO 0xe8008000 (irq = 231, base_baud = 0) is a scif
console [ttySC2] enabled
[drm] Initialized drm 1.1.0 20060810
renesas_spi e800e800.spi: probed
ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
ehci-pci: EHCI PCI platform driver
ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
ohci-pci: OHCI PCI platform driver
mousedev: PS/2 mouse device common for all mice
usbcore: registered new interface driver usbhid
usbhid: USB HID core driver
TCP: cubic registered
NET: Registered protocol family 10
sit: IPv6 over IPv4 tunneling driver
NET: Registered protocol family 17
Key type dns_resolver registered
drivers/rtc/hctosys.c: unable to open rtc device (rtc0)


And a good one looks like this:


Booting Linux on physical CPU 0x0
Linux version 3.16.0-rc3-00751-gd14f001 (horms at ayumi.isobedori.kobe.vergenet.net) (gcc version 4.6.3 (GCC) ) #461 SMP Tue Jul 15 16:48:13 JST 2014
CPU: ARMv7 Processor [413fc090] revision 0 (ARMv7), cr=18c5347d
CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
Machine model: Genmai
debug: ignoring loglevel setting.
Memory policy: Data cache writeback
On node 0 totalpages: 32768
free_area_init_node: node 0, pgdat c071f640, node_mem_map c7ef9000
  Normal zone: 256 pages used for memmap
  Normal zone: 0 pages reserved
  Normal zone: 32768 pages, LIFO batch:7
CPU: All CPU(s) started in SVC mode.
PERCPU: Embedded 5 pages/cpu @c7eea000 s7488 r0 d12992 u32768
pcpu-alloc: s7488 r0 d12992 u32768 alloc=8*4096
pcpu-alloc: [0] 0 
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 32512
Kernel command line: console=ttySC2,115200 ignore_loglevel rw root=/dev/nfs ip=dhcp
PID hash table entries: 512 (order: -1, 2048 bytes)
Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
Memory: 122388K/131072K available (4327K kernel code, 227K rwdata, 1016K rodata, 1691K init, 197K bss, 8684K reserved, 0K highmem)
Virtual kernel memory layout:
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    fixmap  : 0xffc00000 - 0xffe00000   (2048 kB)
    vmalloc : 0xc8800000 - 0xff000000   ( 872 MB)
    lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB)
    pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
      .text : 0xc0008000 - 0xc0540fc4   (5348 kB)
      .init : 0xc0541000 - 0xc06e7d40   (1692 kB)
      .data : 0xc06e8000 - 0xc0720dc0   ( 228 kB)
       .bss : 0xc0720dc8 - 0xc07521fc   ( 198 kB)
Hierarchical RCU implementation.
        RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
NR_IRQS:16 nr_irqs:16 16
clocksource_of_init: no matching clocksources found
sched_clock: 32 bits at 100 Hz, resolution 10000000ns, wraps every 21474836480000000ns
Console: colour dummy device 80x30
Calibrating delay loop (skipped) preset value.. 266.66 BogoMIPS (lpj=1333333)
pid_max: default: 32768 minimum: 301
Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
CPU: Testing write buffer coherency: ok
CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
Setting up static identity map for 0x84405f8 - 0x8440650
Brought up 1 CPUs
SMP: Total of 1 processors activated.
CPU: All CPU(s) started in SVC mode.
devtmpfs: initialized
VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
pinctrl core: initialized pinctrl subsystem
regulator-dummy: no parameters
NET: Registered protocol family 16
DMA: preallocated 256 KiB pool for atomic coherent allocations
No ATAGs?
hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.
hw-breakpoint: maximum watchpoint size is 4 bytes.
vgaarb: loaded
SCSI subsystem initialized
libata version 3.00 loaded.
usbcore: registered new interface driver usbfs
usbcore: registered new interface driver hub
usbcore: registered new device driver usb
media: Linux media interface: v0.10
Linux video capture interface: v2.00
sh_mtu2 sh-mtu2: ch0: used for clock events
sh_mtu2 sh-mtu2: ch0: used for periodic clock events
Advanced Linux Sound Architecture Driver Initialized.
NET: Registered protocol family 2
TCP established hash table entries: 1024 (order: 0, 4096 bytes)
TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
TCP: Hash tables configured (established 1024 bind 1024)
TCP: reno registered
UDP hash table entries: 256 (order: 1, 8192 bytes)
UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
NET: Registered protocol family 1
RPC: Registered named UNIX socket transport module.
RPC: Registered udp transport module.
RPC: Registered tcp transport module.
RPC: Registered tcp NFSv4.1 backchannel transport module.
PCI: CLS 0 bytes, default 64
futex hash table entries: 256 (order: 2, 16384 bytes)
NFS: Registering the id_resolver key type
Key type id_resolver registered
Key type id_legacy registered
nfs4filelayout_init: NFSv4 File Layout Driver Registering...
msgmni has been set to 239
Block layer SCSI generic (bsg) driver version 0.4 loaded (major 252)
io scheduler noop registered
io scheduler deadline registered
io scheduler cfq registered (default)
Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
SuperH (H)SCI(F) driver initialized
e8008000.serial: ttySC2 at MMIO 0xe8008000 (irq = 231, base_baud = 0) is a scif
console [ttySC2] enabled
[drm] Initialized drm 1.1.0 20060810
renesas_spi e800e800.spi: probed
ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
ehci-pci: EHCI PCI platform driver
ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
ohci-pci: OHCI PCI platform driver
mousedev: PS/2 mouse device common for all mice
usbcore: registered new interface driver usbhid
usbhid: USB HID core driver
TCP: cubic registered
NET: Registered protocol family 10
sit: IPv6 over IPv4 tunneling driver
NET: Registered protocol family 17
Key type dns_resolver registered
drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
ALSA device list:
  No soundcards found.
Freeing unused kernel memory: 1688K (c0541000 - c06e7000)


boot (Linux 3.16.0-rc3-00751-gd14f001, BusyBox v1.16.0.git, kexec-tools 2.0.1-git)
/ # 

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

* [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch
  2014-07-15  5:01 ` [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Simon Horman
@ 2014-07-15  8:55   ` Simon Horman
  2014-07-15 11:35     ` Simon Horman
  0 siblings, 1 reply; 22+ messages in thread
From: Simon Horman @ 2014-07-15  8:55 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Jul 15, 2014 at 02:01:07PM +0900, Simon Horman wrote:
> On Wed, Jul 09, 2014 at 03:12:36PM +0200, Laurent Pinchart wrote:
> > Hello,
> > 
> > This patch set enables timer devices in DT for the Marzen, Genmai, Lager and
> > Koelsch boards. It has previously been posted as part of the "[PATCH v4 00/19]
> > Renesas CMT, MTU2 and TMU timers DT support" series, and is now split into its
> > own patch set for merge in v3.17.
> > 
> > The series depends on the driver changes of the "[PATCH v4 00/19] Renesas CMT,
> > MTU2 and TMU timers DT support" series, for which a pull request has been sent.
> 
> Thanks, I have queued these up.

As reported elsewhere I am having a bit of trouble with the dependencies
for this series so I have dropped it for now.

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

* [PATCH v5 8/8] ARM: shmobile: genmai-reference: Enable MTU2 in device tree
  2014-07-15  8:54     ` Simon Horman
@ 2014-07-15  8:58       ` Simon Horman
  2014-07-15 11:36         ` Simon Horman
  0 siblings, 1 reply; 22+ messages in thread
From: Simon Horman @ 2014-07-15  8:58 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Jul 15, 2014 at 05:54:32PM +0900, Simon Horman wrote:
> On Thu, Jul 10, 2014 at 11:54:30AM +0200, Wolfram Sang wrote:
> > On Wed, Jul 09, 2014 at 03:12:44PM +0200, Laurent Pinchart wrote:
> > > No more device needs to be added from platform code when booting the
> > > reference platform, move MTU2 registration from setup-r7s72100.c to
> > > board-genmai.c and remove the now empty r7s72100_add_dt_devices()
> > > function.
> > > 
> > > As the genmai_add_standard_devices() function is now identical to the
> > > default init_machine implementation, remove it as well.
> > > 
> > > Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
> > 
> > Yay, tasty!
> > 
> > Reviewed-by: Wolfram Sang <wsa@sang-engineering.com>
> 
> Hi Laurent,
> 
> I am having some trouble with this patch.
> In particular the shmobile defconfig with an initrd added
> (to compensate for the lack of ethernet and thus NFS) does
> not seem to make it to userspace with this patch applied :(
> 
> I am dropping it for now, but could you look into it?

I have likewise dropped "ARM: shmobile: r7s72100: Add MTU2 device to DT"
for now.

> 
> For the record it seems to stop right near the end.
> A bad boot looks like this:
> 
> Booting Linux on physical CPU 0x0
> Linux version 3.16.0-rc3-00750-g004c383-dirty (horms at ayumi.isobedori.kobe.vergenet.net) (gcc version 4.6.3 (GCC) ) #463 SMP Tue Jul 15 16:58:01 JST 2014
> CPU: ARMv7 Processor [413fc090] revision 0 (ARMv7), cr=18c5347d
> CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
> Machine model: Genmai
> debug: ignoring loglevel setting.
> Memory policy: Data cache writeback
> On node 0 totalpages: 32768
> free_area_init_node: node 0, pgdat c071f640, node_mem_map c7ef9000
>   Normal zone: 256 pages used for memmap
>   Normal zone: 0 pages reserved
>   Normal zone: 32768 pages, LIFO batch:7
> CPU: All CPU(s) started in SVC mode.
> PERCPU: Embedded 5 pages/cpu @c7eea000 s7488 r0 d12992 u32768
> pcpu-alloc: s7488 r0 d12992 u32768 alloc=8*4096
> pcpu-alloc: [0] 0 
> Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 32512
> Kernel command line: console=ttySC2,115200 ignore_loglevel rw root=/dev/nfs ip=dhcp
> PID hash table entries: 512 (order: -1, 2048 bytes)
> Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
> Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
> Memory: 122388K/131072K available (4327K kernel code, 227K rwdata, 1016K rodata, 1691K init, 197K bss, 8684K reserved, 0K highmem)
> Virtual kernel memory layout:
>     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
>     fixmap  : 0xffc00000 - 0xffe00000   (2048 kB)
>     vmalloc : 0xc8800000 - 0xff000000   ( 872 MB)
>     lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB)
>     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
>       .text : 0xc0008000 - 0xc0540fc4   (5348 kB)
>       .init : 0xc0541000 - 0xc06e7d40   (1692 kB)
>       .data : 0xc06e8000 - 0xc0720dc0   ( 228 kB)
>        .bss : 0xc0720dc8 - 0xc07521fc   ( 198 kB)
> Hierarchical RCU implementation.
>         RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
> RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
> NR_IRQS:16 nr_irqs:16 16
> clocksource_of_init: no matching clocksources found
> sched_clock: 32 bits at 100 Hz, resolution 10000000ns, wraps every 21474836480000000ns
> Console: colour dummy device 80x30
> Calibrating delay loop (skipped) preset value.. 266.66 BogoMIPS (lpj=1333333)
> pid_max: default: 32768 minimum: 301
> Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
> Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
> CPU: Testing write buffer coherency: ok
> CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
> Setting up static identity map for 0x84405f8 - 0x8440650
> Brought up 1 CPUs
> SMP: Total of 1 processors activated.
> CPU: All CPU(s) started in SVC mode.
> devtmpfs: initialized
> VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
> pinctrl core: initialized pinctrl subsystem
> regulator-dummy: no parameters
> NET: Registered protocol family 16
> DMA: preallocated 256 KiB pool for atomic coherent allocations
> No ATAGs?
> hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.
> hw-breakpoint: maximum watchpoint size is 4 bytes.
> vgaarb: loaded
> SCSI subsystem initialized
> libata version 3.00 loaded.
> usbcore: registered new interface driver usbfs
> usbcore: registered new interface driver hub
> usbcore: registered new device driver usb
> media: Linux media interface: v0.10
> Linux video capture interface: v2.00
> sh_mtu2 fcff0000.timer: ch0: used for clock events
> sh_mtu2 fcff0000.timer: ch0: used for periodic clock events
> Advanced Linux Sound Architecture Driver Initialized.
> NET: Registered protocol family 2
> TCP established hash table entries: 1024 (order: 0, 4096 bytes)
> TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
> TCP: Hash tables configured (established 1024 bind 1024)
> TCP: reno registered
> UDP hash table entries: 256 (order: 1, 8192 bytes)
> UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
> NET: Registered protocol family 1
> RPC: Registered named UNIX socket transport module.
> RPC: Registered udp transport module.
> RPC: Registered tcp transport module.
> RPC: Registered tcp NFSv4.1 backchannel transport module.
> PCI: CLS 0 bytes, default 64
> futex hash table entries: 256 (order: 2, 16384 bytes)
> NFS: Registering the id_resolver key type
> Key type id_resolver registered
> Key type id_legacy registered
> nfs4filelayout_init: NFSv4 File Layout Driver Registering...
> msgmni has been set to 239
> Block layer SCSI generic (bsg) driver version 0.4 loaded (major 252)
> io scheduler noop registered
> io scheduler deadline registered
> io scheduler cfq registered (default)
> Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
> SuperH (H)SCI(F) driver initialized
> e8008000.serial: ttySC2 at MMIO 0xe8008000 (irq = 231, base_baud = 0) is a scif
> console [ttySC2] enabled
> [drm] Initialized drm 1.1.0 20060810
> renesas_spi e800e800.spi: probed
> ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
> ehci-pci: EHCI PCI platform driver
> ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
> ohci-pci: OHCI PCI platform driver
> mousedev: PS/2 mouse device common for all mice
> usbcore: registered new interface driver usbhid
> usbhid: USB HID core driver
> TCP: cubic registered
> NET: Registered protocol family 10
> sit: IPv6 over IPv4 tunneling driver
> NET: Registered protocol family 17
> Key type dns_resolver registered
> drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
> 
> 
> And a good one looks like this:
> 
> 
> Booting Linux on physical CPU 0x0
> Linux version 3.16.0-rc3-00751-gd14f001 (horms at ayumi.isobedori.kobe.vergenet.net) (gcc version 4.6.3 (GCC) ) #461 SMP Tue Jul 15 16:48:13 JST 2014
> CPU: ARMv7 Processor [413fc090] revision 0 (ARMv7), cr=18c5347d
> CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
> Machine model: Genmai
> debug: ignoring loglevel setting.
> Memory policy: Data cache writeback
> On node 0 totalpages: 32768
> free_area_init_node: node 0, pgdat c071f640, node_mem_map c7ef9000
>   Normal zone: 256 pages used for memmap
>   Normal zone: 0 pages reserved
>   Normal zone: 32768 pages, LIFO batch:7
> CPU: All CPU(s) started in SVC mode.
> PERCPU: Embedded 5 pages/cpu @c7eea000 s7488 r0 d12992 u32768
> pcpu-alloc: s7488 r0 d12992 u32768 alloc=8*4096
> pcpu-alloc: [0] 0 
> Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 32512
> Kernel command line: console=ttySC2,115200 ignore_loglevel rw root=/dev/nfs ip=dhcp
> PID hash table entries: 512 (order: -1, 2048 bytes)
> Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
> Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
> Memory: 122388K/131072K available (4327K kernel code, 227K rwdata, 1016K rodata, 1691K init, 197K bss, 8684K reserved, 0K highmem)
> Virtual kernel memory layout:
>     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
>     fixmap  : 0xffc00000 - 0xffe00000   (2048 kB)
>     vmalloc : 0xc8800000 - 0xff000000   ( 872 MB)
>     lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB)
>     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
>       .text : 0xc0008000 - 0xc0540fc4   (5348 kB)
>       .init : 0xc0541000 - 0xc06e7d40   (1692 kB)
>       .data : 0xc06e8000 - 0xc0720dc0   ( 228 kB)
>        .bss : 0xc0720dc8 - 0xc07521fc   ( 198 kB)
> Hierarchical RCU implementation.
>         RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
> RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
> NR_IRQS:16 nr_irqs:16 16
> clocksource_of_init: no matching clocksources found
> sched_clock: 32 bits at 100 Hz, resolution 10000000ns, wraps every 21474836480000000ns
> Console: colour dummy device 80x30
> Calibrating delay loop (skipped) preset value.. 266.66 BogoMIPS (lpj=1333333)
> pid_max: default: 32768 minimum: 301
> Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
> Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
> CPU: Testing write buffer coherency: ok
> CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
> Setting up static identity map for 0x84405f8 - 0x8440650
> Brought up 1 CPUs
> SMP: Total of 1 processors activated.
> CPU: All CPU(s) started in SVC mode.
> devtmpfs: initialized
> VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
> pinctrl core: initialized pinctrl subsystem
> regulator-dummy: no parameters
> NET: Registered protocol family 16
> DMA: preallocated 256 KiB pool for atomic coherent allocations
> No ATAGs?
> hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.
> hw-breakpoint: maximum watchpoint size is 4 bytes.
> vgaarb: loaded
> SCSI subsystem initialized
> libata version 3.00 loaded.
> usbcore: registered new interface driver usbfs
> usbcore: registered new interface driver hub
> usbcore: registered new device driver usb
> media: Linux media interface: v0.10
> Linux video capture interface: v2.00
> sh_mtu2 sh-mtu2: ch0: used for clock events
> sh_mtu2 sh-mtu2: ch0: used for periodic clock events
> Advanced Linux Sound Architecture Driver Initialized.
> NET: Registered protocol family 2
> TCP established hash table entries: 1024 (order: 0, 4096 bytes)
> TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
> TCP: Hash tables configured (established 1024 bind 1024)
> TCP: reno registered
> UDP hash table entries: 256 (order: 1, 8192 bytes)
> UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
> NET: Registered protocol family 1
> RPC: Registered named UNIX socket transport module.
> RPC: Registered udp transport module.
> RPC: Registered tcp transport module.
> RPC: Registered tcp NFSv4.1 backchannel transport module.
> PCI: CLS 0 bytes, default 64
> futex hash table entries: 256 (order: 2, 16384 bytes)
> NFS: Registering the id_resolver key type
> Key type id_resolver registered
> Key type id_legacy registered
> nfs4filelayout_init: NFSv4 File Layout Driver Registering...
> msgmni has been set to 239
> Block layer SCSI generic (bsg) driver version 0.4 loaded (major 252)
> io scheduler noop registered
> io scheduler deadline registered
> io scheduler cfq registered (default)
> Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
> SuperH (H)SCI(F) driver initialized
> e8008000.serial: ttySC2 at MMIO 0xe8008000 (irq = 231, base_baud = 0) is a scif
> console [ttySC2] enabled
> [drm] Initialized drm 1.1.0 20060810
> renesas_spi e800e800.spi: probed
> ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
> ehci-pci: EHCI PCI platform driver
> ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
> ohci-pci: OHCI PCI platform driver
> mousedev: PS/2 mouse device common for all mice
> usbcore: registered new interface driver usbhid
> usbhid: USB HID core driver
> TCP: cubic registered
> NET: Registered protocol family 10
> sit: IPv6 over IPv4 tunneling driver
> NET: Registered protocol family 17
> Key type dns_resolver registered
> drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
> ALSA device list:
>   No soundcards found.
> Freeing unused kernel memory: 1688K (c0541000 - c06e7000)
> 
> 
> boot (Linux 3.16.0-rc3-00751-gd14f001, BusyBox v1.16.0.git, kexec-tools 2.0.1-git)
> / # 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sh" in
> the body of a message to majordomo at vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

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

* [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch
  2014-07-15  8:55   ` Simon Horman
@ 2014-07-15 11:35     ` Simon Horman
  0 siblings, 0 replies; 22+ messages in thread
From: Simon Horman @ 2014-07-15 11:35 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Jul 15, 2014 at 05:55:36PM +0900, Simon Horman wrote:
> On Tue, Jul 15, 2014 at 02:01:07PM +0900, Simon Horman wrote:
> > On Wed, Jul 09, 2014 at 03:12:36PM +0200, Laurent Pinchart wrote:
> > > Hello,
> > > 
> > > This patch set enables timer devices in DT for the Marzen, Genmai, Lager and
> > > Koelsch boards. It has previously been posted as part of the "[PATCH v4 00/19]
> > > Renesas CMT, MTU2 and TMU timers DT support" series, and is now split into its
> > > own patch set for merge in v3.17.
> > > 
> > > The series depends on the driver changes of the "[PATCH v4 00/19] Renesas CMT,
> > > MTU2 and TMU timers DT support" series, for which a pull request has been sent.
> > 
> > Thanks, I have queued these up.
> 
> As reported elsewhere I am having a bit of trouble with the dependencies
> for this series so I have dropped it for now.

Please ignore that remark, it was supposed to be about
"ARM: shmobile: r7s72100: Remove legacy board support".

I have only dropped the 72100/genmai patches of this series.

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

* [PATCH v5 8/8] ARM: shmobile: genmai-reference: Enable MTU2 in device tree
  2014-07-15  8:58       ` Simon Horman
@ 2014-07-15 11:36         ` Simon Horman
  2014-07-15 12:28           ` Simon Horman
  0 siblings, 1 reply; 22+ messages in thread
From: Simon Horman @ 2014-07-15 11:36 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Jul 15, 2014 at 05:58:15PM +0900, Simon Horman wrote:
> On Tue, Jul 15, 2014 at 05:54:32PM +0900, Simon Horman wrote:
> > On Thu, Jul 10, 2014 at 11:54:30AM +0200, Wolfram Sang wrote:
> > > On Wed, Jul 09, 2014 at 03:12:44PM +0200, Laurent Pinchart wrote:
> > > > No more device needs to be added from platform code when booting the
> > > > reference platform, move MTU2 registration from setup-r7s72100.c to
> > > > board-genmai.c and remove the now empty r7s72100_add_dt_devices()
> > > > function.
> > > > 
> > > > As the genmai_add_standard_devices() function is now identical to the
> > > > default init_machine implementation, remove it as well.
> > > > 
> > > > Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
> > > 
> > > Yay, tasty!
> > > 
> > > Reviewed-by: Wolfram Sang <wsa@sang-engineering.com>
> > 
> > Hi Laurent,
> > 
> > I am having some trouble with this patch.
> > In particular the shmobile defconfig with an initrd added
> > (to compensate for the lack of ethernet and thus NFS) does
> > not seem to make it to userspace with this patch applied :(
> > 
> > I am dropping it for now, but could you look into it?
> 
> I have likewise dropped "ARM: shmobile: r7s72100: Add MTU2 device to DT"
> for now.

I believe that I have tracked down the problem and that it is
in "ARM: shmobile: r7s72100: Add MTU2 device to DT".
I will describe it in a response to that patch.

> > For the record it seems to stop right near the end.
> > A bad boot looks like this:
> > 
> > Booting Linux on physical CPU 0x0
> > Linux version 3.16.0-rc3-00750-g004c383-dirty (horms at ayumi.isobedori.kobe.vergenet.net) (gcc version 4.6.3 (GCC) ) #463 SMP Tue Jul 15 16:58:01 JST 2014
> > CPU: ARMv7 Processor [413fc090] revision 0 (ARMv7), cr=18c5347d
> > CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
> > Machine model: Genmai
> > debug: ignoring loglevel setting.
> > Memory policy: Data cache writeback
> > On node 0 totalpages: 32768
> > free_area_init_node: node 0, pgdat c071f640, node_mem_map c7ef9000
> >   Normal zone: 256 pages used for memmap
> >   Normal zone: 0 pages reserved
> >   Normal zone: 32768 pages, LIFO batch:7
> > CPU: All CPU(s) started in SVC mode.
> > PERCPU: Embedded 5 pages/cpu @c7eea000 s7488 r0 d12992 u32768
> > pcpu-alloc: s7488 r0 d12992 u32768 alloc=8*4096
> > pcpu-alloc: [0] 0 
> > Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 32512
> > Kernel command line: console=ttySC2,115200 ignore_loglevel rw root=/dev/nfs ip=dhcp
> > PID hash table entries: 512 (order: -1, 2048 bytes)
> > Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
> > Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
> > Memory: 122388K/131072K available (4327K kernel code, 227K rwdata, 1016K rodata, 1691K init, 197K bss, 8684K reserved, 0K highmem)
> > Virtual kernel memory layout:
> >     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
> >     fixmap  : 0xffc00000 - 0xffe00000   (2048 kB)
> >     vmalloc : 0xc8800000 - 0xff000000   ( 872 MB)
> >     lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB)
> >     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
> >       .text : 0xc0008000 - 0xc0540fc4   (5348 kB)
> >       .init : 0xc0541000 - 0xc06e7d40   (1692 kB)
> >       .data : 0xc06e8000 - 0xc0720dc0   ( 228 kB)
> >        .bss : 0xc0720dc8 - 0xc07521fc   ( 198 kB)
> > Hierarchical RCU implementation.
> >         RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
> > RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
> > NR_IRQS:16 nr_irqs:16 16
> > clocksource_of_init: no matching clocksources found
> > sched_clock: 32 bits at 100 Hz, resolution 10000000ns, wraps every 21474836480000000ns
> > Console: colour dummy device 80x30
> > Calibrating delay loop (skipped) preset value.. 266.66 BogoMIPS (lpj=1333333)
> > pid_max: default: 32768 minimum: 301
> > Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
> > Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
> > CPU: Testing write buffer coherency: ok
> > CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
> > Setting up static identity map for 0x84405f8 - 0x8440650
> > Brought up 1 CPUs
> > SMP: Total of 1 processors activated.
> > CPU: All CPU(s) started in SVC mode.
> > devtmpfs: initialized
> > VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
> > pinctrl core: initialized pinctrl subsystem
> > regulator-dummy: no parameters
> > NET: Registered protocol family 16
> > DMA: preallocated 256 KiB pool for atomic coherent allocations
> > No ATAGs?
> > hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.
> > hw-breakpoint: maximum watchpoint size is 4 bytes.
> > vgaarb: loaded
> > SCSI subsystem initialized
> > libata version 3.00 loaded.
> > usbcore: registered new interface driver usbfs
> > usbcore: registered new interface driver hub
> > usbcore: registered new device driver usb
> > media: Linux media interface: v0.10
> > Linux video capture interface: v2.00
> > sh_mtu2 fcff0000.timer: ch0: used for clock events
> > sh_mtu2 fcff0000.timer: ch0: used for periodic clock events
> > Advanced Linux Sound Architecture Driver Initialized.
> > NET: Registered protocol family 2
> > TCP established hash table entries: 1024 (order: 0, 4096 bytes)
> > TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
> > TCP: Hash tables configured (established 1024 bind 1024)
> > TCP: reno registered
> > UDP hash table entries: 256 (order: 1, 8192 bytes)
> > UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
> > NET: Registered protocol family 1
> > RPC: Registered named UNIX socket transport module.
> > RPC: Registered udp transport module.
> > RPC: Registered tcp transport module.
> > RPC: Registered tcp NFSv4.1 backchannel transport module.
> > PCI: CLS 0 bytes, default 64
> > futex hash table entries: 256 (order: 2, 16384 bytes)
> > NFS: Registering the id_resolver key type
> > Key type id_resolver registered
> > Key type id_legacy registered
> > nfs4filelayout_init: NFSv4 File Layout Driver Registering...
> > msgmni has been set to 239
> > Block layer SCSI generic (bsg) driver version 0.4 loaded (major 252)
> > io scheduler noop registered
> > io scheduler deadline registered
> > io scheduler cfq registered (default)
> > Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
> > SuperH (H)SCI(F) driver initialized
> > e8008000.serial: ttySC2 at MMIO 0xe8008000 (irq = 231, base_baud = 0) is a scif
> > console [ttySC2] enabled
> > [drm] Initialized drm 1.1.0 20060810
> > renesas_spi e800e800.spi: probed
> > ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
> > ehci-pci: EHCI PCI platform driver
> > ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
> > ohci-pci: OHCI PCI platform driver
> > mousedev: PS/2 mouse device common for all mice
> > usbcore: registered new interface driver usbhid
> > usbhid: USB HID core driver
> > TCP: cubic registered
> > NET: Registered protocol family 10
> > sit: IPv6 over IPv4 tunneling driver
> > NET: Registered protocol family 17
> > Key type dns_resolver registered
> > drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
> > 
> > 
> > And a good one looks like this:
> > 
> > 
> > Booting Linux on physical CPU 0x0
> > Linux version 3.16.0-rc3-00751-gd14f001 (horms at ayumi.isobedori.kobe.vergenet.net) (gcc version 4.6.3 (GCC) ) #461 SMP Tue Jul 15 16:48:13 JST 2014
> > CPU: ARMv7 Processor [413fc090] revision 0 (ARMv7), cr=18c5347d
> > CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
> > Machine model: Genmai
> > debug: ignoring loglevel setting.
> > Memory policy: Data cache writeback
> > On node 0 totalpages: 32768
> > free_area_init_node: node 0, pgdat c071f640, node_mem_map c7ef9000
> >   Normal zone: 256 pages used for memmap
> >   Normal zone: 0 pages reserved
> >   Normal zone: 32768 pages, LIFO batch:7
> > CPU: All CPU(s) started in SVC mode.
> > PERCPU: Embedded 5 pages/cpu @c7eea000 s7488 r0 d12992 u32768
> > pcpu-alloc: s7488 r0 d12992 u32768 alloc=8*4096
> > pcpu-alloc: [0] 0 
> > Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 32512
> > Kernel command line: console=ttySC2,115200 ignore_loglevel rw root=/dev/nfs ip=dhcp
> > PID hash table entries: 512 (order: -1, 2048 bytes)
> > Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
> > Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
> > Memory: 122388K/131072K available (4327K kernel code, 227K rwdata, 1016K rodata, 1691K init, 197K bss, 8684K reserved, 0K highmem)
> > Virtual kernel memory layout:
> >     vector  : 0xffff0000 - 0xffff1000   (   4 kB)
> >     fixmap  : 0xffc00000 - 0xffe00000   (2048 kB)
> >     vmalloc : 0xc8800000 - 0xff000000   ( 872 MB)
> >     lowmem  : 0xc0000000 - 0xc8000000   ( 128 MB)
> >     pkmap   : 0xbfe00000 - 0xc0000000   (   2 MB)
> >       .text : 0xc0008000 - 0xc0540fc4   (5348 kB)
> >       .init : 0xc0541000 - 0xc06e7d40   (1692 kB)
> >       .data : 0xc06e8000 - 0xc0720dc0   ( 228 kB)
> >        .bss : 0xc0720dc8 - 0xc07521fc   ( 198 kB)
> > Hierarchical RCU implementation.
> >         RCU restricting CPUs from NR_CPUS=8 to nr_cpu_ids=1.
> > RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=1
> > NR_IRQS:16 nr_irqs:16 16
> > clocksource_of_init: no matching clocksources found
> > sched_clock: 32 bits at 100 Hz, resolution 10000000ns, wraps every 21474836480000000ns
> > Console: colour dummy device 80x30
> > Calibrating delay loop (skipped) preset value.. 266.66 BogoMIPS (lpj=1333333)
> > pid_max: default: 32768 minimum: 301
> > Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
> > Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
> > CPU: Testing write buffer coherency: ok
> > CPU0: thread -1, cpu 0, socket 0, mpidr 80000000
> > Setting up static identity map for 0x84405f8 - 0x8440650
> > Brought up 1 CPUs
> > SMP: Total of 1 processors activated.
> > CPU: All CPU(s) started in SVC mode.
> > devtmpfs: initialized
> > VFP support v0.3: implementor 41 architecture 3 part 30 variant 9 rev 4
> > pinctrl core: initialized pinctrl subsystem
> > regulator-dummy: no parameters
> > NET: Registered protocol family 16
> > DMA: preallocated 256 KiB pool for atomic coherent allocations
> > No ATAGs?
> > hw-breakpoint: found 5 (+1 reserved) breakpoint and 1 watchpoint registers.
> > hw-breakpoint: maximum watchpoint size is 4 bytes.
> > vgaarb: loaded
> > SCSI subsystem initialized
> > libata version 3.00 loaded.
> > usbcore: registered new interface driver usbfs
> > usbcore: registered new interface driver hub
> > usbcore: registered new device driver usb
> > media: Linux media interface: v0.10
> > Linux video capture interface: v2.00
> > sh_mtu2 sh-mtu2: ch0: used for clock events
> > sh_mtu2 sh-mtu2: ch0: used for periodic clock events
> > Advanced Linux Sound Architecture Driver Initialized.
> > NET: Registered protocol family 2
> > TCP established hash table entries: 1024 (order: 0, 4096 bytes)
> > TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
> > TCP: Hash tables configured (established 1024 bind 1024)
> > TCP: reno registered
> > UDP hash table entries: 256 (order: 1, 8192 bytes)
> > UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
> > NET: Registered protocol family 1
> > RPC: Registered named UNIX socket transport module.
> > RPC: Registered udp transport module.
> > RPC: Registered tcp transport module.
> > RPC: Registered tcp NFSv4.1 backchannel transport module.
> > PCI: CLS 0 bytes, default 64
> > futex hash table entries: 256 (order: 2, 16384 bytes)
> > NFS: Registering the id_resolver key type
> > Key type id_resolver registered
> > Key type id_legacy registered
> > nfs4filelayout_init: NFSv4 File Layout Driver Registering...
> > msgmni has been set to 239
> > Block layer SCSI generic (bsg) driver version 0.4 loaded (major 252)
> > io scheduler noop registered
> > io scheduler deadline registered
> > io scheduler cfq registered (default)
> > Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
> > SuperH (H)SCI(F) driver initialized
> > e8008000.serial: ttySC2 at MMIO 0xe8008000 (irq = 231, base_baud = 0) is a scif
> > console [ttySC2] enabled
> > [drm] Initialized drm 1.1.0 20060810
> > renesas_spi e800e800.spi: probed
> > ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
> > ehci-pci: EHCI PCI platform driver
> > ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
> > ohci-pci: OHCI PCI platform driver
> > mousedev: PS/2 mouse device common for all mice
> > usbcore: registered new interface driver usbhid
> > usbhid: USB HID core driver
> > TCP: cubic registered
> > NET: Registered protocol family 10
> > sit: IPv6 over IPv4 tunneling driver
> > NET: Registered protocol family 17
> > Key type dns_resolver registered
> > drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
> > ALSA device list:
> >   No soundcards found.
> > Freeing unused kernel memory: 1688K (c0541000 - c06e7000)
> > 
> > 
> > boot (Linux 3.16.0-rc3-00751-gd14f001, BusyBox v1.16.0.git, kexec-tools 2.0.1-git)
> > / # 
> > --
> > To unsubscribe from this list: send the line "unsubscribe linux-sh" in
> > the body of a message to majordomo at vger.kernel.org
> > More majordomo info at  http://vger.kernel.org/majordomo-info.html
> > 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sh" in
> the body of a message to majordomo at vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

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

* [PATCH v5 4/8] ARM: shmobile: r7s72100: Add MTU2 device to DT
  2014-07-09 13:12 ` [PATCH v5 4/8] ARM: shmobile: r7s72100: Add MTU2 device " Laurent Pinchart
  2014-07-10  9:53   ` Wolfram Sang
@ 2014-07-15 11:47   ` Simon Horman
  2014-07-15 11:55     ` Laurent Pinchart
  1 sibling, 1 reply; 22+ messages in thread
From: Simon Horman @ 2014-07-15 11:47 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Jul 09, 2014 at 03:12:40PM +0200, Laurent Pinchart wrote:
> Add the MTU2 counter to the r7s72100 device tree and make it disabled by
> default.
> 
> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
> ---
>  arch/arm/boot/dts/r7s72100.dtsi | 10 ++++++++++
>  1 file changed, 10 insertions(+)
> 
> diff --git a/arch/arm/boot/dts/r7s72100.dtsi b/arch/arm/boot/dts/r7s72100.dtsi
> index bdee225..c902b0b 100644
> --- a/arch/arm/boot/dts/r7s72100.dtsi
> +++ b/arch/arm/boot/dts/r7s72100.dtsi
> @@ -229,6 +229,16 @@
>  		status = "disabled";
>  	};
>  
> +	mtu2: timer at fcff0000 {
> +		compatible = "renesas,mtu2";
> +		reg = <0xfcff0000 0x400>;
> +		interrupts = <0 139 IRQ_TYPE_LEVEL_HIGH>;
> +		interrupt-names = "tgi0a";
> +		clocks = <&mstp3_clks R7S72100_CLK_MTU2>;
> +		clock-names = "fck";
> +		status = "disabled";
> +	};
> +
>  	scif0: serial at e8007000 {
>  		compatible = "renesas,scif-r7s72100", "renesas,scif";
>  		reg = <0xe8007000 64>;

I believe that I claimed to have tested this in the past but that
my testing was by booting a config to userspace that as it happens
did not require to timer to get that far.

I now believe there is a minor error: the interrupt number should be
(139 - 32 =) 107 rather than 139.

This allows a system with this and the related genmai patch applied
on top of renesas-next-v3.16-rc3-20140715 to boot to uerspace
when compiled with shmobile_defconfig (+ an initrd).
Without the irq number change the boot gets stuck in
ip_auto_config (which presumably sleeps).

Laurent, should I squash the following in and queue-up the result?

diff --git a/arch/arm/boot/dts/r7s72100.dtsi b/arch/arm/boot/dts/r7s72100.dtsi
index c902b0b..1d28d01 100644
--- a/arch/arm/boot/dts/r7s72100.dtsi
+++ b/arch/arm/boot/dts/r7s72100.dtsi
@@ -232,7 +232,7 @@
 	mtu2: timer at fcff0000 {
 		compatible = "renesas,mtu2";
 		reg = <0xfcff0000 0x400>;
-		interrupts = <0 139 IRQ_TYPE_LEVEL_HIGH>;
+		interrupts = <0 107 IRQ_TYPE_LEVEL_HIGH>;
 		interrupt-names = "tgi0a";
 		clocks = <&mstp3_clks R7S72100_CLK_MTU2>;
 		clock-names = "fck";

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

* [PATCH v5 4/8] ARM: shmobile: r7s72100: Add MTU2 device to DT
  2014-07-15 11:47   ` Simon Horman
@ 2014-07-15 11:55     ` Laurent Pinchart
  2014-07-15 12:23       ` Simon Horman
  0 siblings, 1 reply; 22+ messages in thread
From: Laurent Pinchart @ 2014-07-15 11:55 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Simon,

On Tuesday 15 July 2014 20:47:41 Simon Horman wrote:
> On Wed, Jul 09, 2014 at 03:12:40PM +0200, Laurent Pinchart wrote:
> > Add the MTU2 counter to the r7s72100 device tree and make it disabled by
> > default.
> > 
> > Signed-off-by: Laurent Pinchart
> > <laurent.pinchart+renesas@ideasonboard.com>
> > ---
> > 
> >  arch/arm/boot/dts/r7s72100.dtsi | 10 ++++++++++
> >  1 file changed, 10 insertions(+)
> > 
> > diff --git a/arch/arm/boot/dts/r7s72100.dtsi
> > b/arch/arm/boot/dts/r7s72100.dtsi index bdee225..c902b0b 100644
> > --- a/arch/arm/boot/dts/r7s72100.dtsi
> > +++ b/arch/arm/boot/dts/r7s72100.dtsi
> > @@ -229,6 +229,16 @@
> >  		status = "disabled";
> >  	};
> > 
> > +	mtu2: timer at fcff0000 {
> > +		compatible = "renesas,mtu2";
> > +		reg = <0xfcff0000 0x400>;
> > +		interrupts = <0 139 IRQ_TYPE_LEVEL_HIGH>;
> > +		interrupt-names = "tgi0a";
> > +		clocks = <&mstp3_clks R7S72100_CLK_MTU2>;
> > +		clock-names = "fck";
> > +		status = "disabled";
> > +	};
> > +
> >  	scif0: serial at e8007000 {
> >  		compatible = "renesas,scif-r7s72100", "renesas,scif";
> >  		reg = <0xe8007000 64>;
> 
> I believe that I claimed to have tested this in the past but that
> my testing was by booting a config to userspace that as it happens
> did not require to timer to get that far.
> 
> I now believe there is a minor error: the interrupt number should be
> (139 - 32 =) 107 rather than 139.
> 
> This allows a system with this and the related genmai patch applied
> on top of renesas-next-v3.16-rc3-20140715 to boot to uerspace
> when compiled with shmobile_defconfig (+ an initrd).
> Without the irq number change the boot gets stuck in
> ip_auto_config (which presumably sleeps).
> 
> Laurent, should I squash the following in and queue-up the result?

Please do, and sorry for the mistake.

> diff --git a/arch/arm/boot/dts/r7s72100.dtsi
> b/arch/arm/boot/dts/r7s72100.dtsi index c902b0b..1d28d01 100644
> --- a/arch/arm/boot/dts/r7s72100.dtsi
> +++ b/arch/arm/boot/dts/r7s72100.dtsi
> @@ -232,7 +232,7 @@
>  	mtu2: timer at fcff0000 {
>  		compatible = "renesas,mtu2";
>  		reg = <0xfcff0000 0x400>;
> -		interrupts = <0 139 IRQ_TYPE_LEVEL_HIGH>;
> +		interrupts = <0 107 IRQ_TYPE_LEVEL_HIGH>;
>  		interrupt-names = "tgi0a";
>  		clocks = <&mstp3_clks R7S72100_CLK_MTU2>;
>  		clock-names = "fck";

-- 
Regards,

Laurent Pinchart

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

* [PATCH v5 4/8] ARM: shmobile: r7s72100: Add MTU2 device to DT
  2014-07-15 11:55     ` Laurent Pinchart
@ 2014-07-15 12:23       ` Simon Horman
  2014-07-15 12:28         ` Simon Horman
  0 siblings, 1 reply; 22+ messages in thread
From: Simon Horman @ 2014-07-15 12:23 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Jul 15, 2014 at 01:55:25PM +0200, Laurent Pinchart wrote:
> Hi Simon,
> 
> On Tuesday 15 July 2014 20:47:41 Simon Horman wrote:
> > On Wed, Jul 09, 2014 at 03:12:40PM +0200, Laurent Pinchart wrote:
> > > Add the MTU2 counter to the r7s72100 device tree and make it disabled by
> > > default.
> > > 
> > > Signed-off-by: Laurent Pinchart
> > > <laurent.pinchart+renesas@ideasonboard.com>
> > > ---
> > > 
> > >  arch/arm/boot/dts/r7s72100.dtsi | 10 ++++++++++
> > >  1 file changed, 10 insertions(+)
> > > 
> > > diff --git a/arch/arm/boot/dts/r7s72100.dtsi
> > > b/arch/arm/boot/dts/r7s72100.dtsi index bdee225..c902b0b 100644
> > > --- a/arch/arm/boot/dts/r7s72100.dtsi
> > > +++ b/arch/arm/boot/dts/r7s72100.dtsi
> > > @@ -229,6 +229,16 @@
> > >  		status = "disabled";
> > >  	};
> > > 
> > > +	mtu2: timer at fcff0000 {
> > > +		compatible = "renesas,mtu2";
> > > +		reg = <0xfcff0000 0x400>;
> > > +		interrupts = <0 139 IRQ_TYPE_LEVEL_HIGH>;
> > > +		interrupt-names = "tgi0a";
> > > +		clocks = <&mstp3_clks R7S72100_CLK_MTU2>;
> > > +		clock-names = "fck";
> > > +		status = "disabled";
> > > +	};
> > > +
> > >  	scif0: serial at e8007000 {
> > >  		compatible = "renesas,scif-r7s72100", "renesas,scif";
> > >  		reg = <0xe8007000 64>;
> > 
> > I believe that I claimed to have tested this in the past but that
> > my testing was by booting a config to userspace that as it happens
> > did not require to timer to get that far.
> > 
> > I now believe there is a minor error: the interrupt number should be
> > (139 - 32 =) 107 rather than 139.
> > 
> > This allows a system with this and the related genmai patch applied
> > on top of renesas-next-v3.16-rc3-20140715 to boot to uerspace
> > when compiled with shmobile_defconfig (+ an initrd).
> > Without the irq number change the boot gets stuck in
> > ip_auto_config (which presumably sleeps).
> > 
> > Laurent, should I squash the following in and queue-up the result?
> 
> Please do, and sorry for the mistake.

Not at all. I've made the same one several times myself.

> > diff --git a/arch/arm/boot/dts/r7s72100.dtsi
> > b/arch/arm/boot/dts/r7s72100.dtsi index c902b0b..1d28d01 100644
> > --- a/arch/arm/boot/dts/r7s72100.dtsi
> > +++ b/arch/arm/boot/dts/r7s72100.dtsi
> > @@ -232,7 +232,7 @@
> >  	mtu2: timer at fcff0000 {
> >  		compatible = "renesas,mtu2";
> >  		reg = <0xfcff0000 0x400>;
> > -		interrupts = <0 139 IRQ_TYPE_LEVEL_HIGH>;
> > +		interrupts = <0 107 IRQ_TYPE_LEVEL_HIGH>;
> >  		interrupt-names = "tgi0a";
> >  		clocks = <&mstp3_clks R7S72100_CLK_MTU2>;
> >  		clock-names = "fck";
> 
> -- 
> Regards,
> 
> Laurent Pinchart
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sh" in
> the body of a message to majordomo at vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

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

* [PATCH v5 4/8] ARM: shmobile: r7s72100: Add MTU2 device to DT
  2014-07-15 12:23       ` Simon Horman
@ 2014-07-15 12:28         ` Simon Horman
  0 siblings, 0 replies; 22+ messages in thread
From: Simon Horman @ 2014-07-15 12:28 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Jul 15, 2014 at 09:23:09PM +0900, Simon Horman wrote:
> On Tue, Jul 15, 2014 at 01:55:25PM +0200, Laurent Pinchart wrote:
> > Hi Simon,
> > 
> > On Tuesday 15 July 2014 20:47:41 Simon Horman wrote:
> > > On Wed, Jul 09, 2014 at 03:12:40PM +0200, Laurent Pinchart wrote:
> > > > Add the MTU2 counter to the r7s72100 device tree and make it disabled by
> > > > default.
> > > > 
> > > > Signed-off-by: Laurent Pinchart
> > > > <laurent.pinchart+renesas@ideasonboard.com>
> > > > ---
> > > > 
> > > >  arch/arm/boot/dts/r7s72100.dtsi | 10 ++++++++++
> > > >  1 file changed, 10 insertions(+)
> > > > 
> > > > diff --git a/arch/arm/boot/dts/r7s72100.dtsi
> > > > b/arch/arm/boot/dts/r7s72100.dtsi index bdee225..c902b0b 100644
> > > > --- a/arch/arm/boot/dts/r7s72100.dtsi
> > > > +++ b/arch/arm/boot/dts/r7s72100.dtsi
> > > > @@ -229,6 +229,16 @@
> > > >  		status = "disabled";
> > > >  	};
> > > > 
> > > > +	mtu2: timer at fcff0000 {
> > > > +		compatible = "renesas,mtu2";
> > > > +		reg = <0xfcff0000 0x400>;
> > > > +		interrupts = <0 139 IRQ_TYPE_LEVEL_HIGH>;
> > > > +		interrupt-names = "tgi0a";
> > > > +		clocks = <&mstp3_clks R7S72100_CLK_MTU2>;
> > > > +		clock-names = "fck";
> > > > +		status = "disabled";
> > > > +	};
> > > > +
> > > >  	scif0: serial at e8007000 {
> > > >  		compatible = "renesas,scif-r7s72100", "renesas,scif";
> > > >  		reg = <0xe8007000 64>;
> > > 
> > > I believe that I claimed to have tested this in the past but that
> > > my testing was by booting a config to userspace that as it happens
> > > did not require to timer to get that far.
> > > 
> > > I now believe there is a minor error: the interrupt number should be
> > > (139 - 32 =) 107 rather than 139.
> > > 
> > > This allows a system with this and the related genmai patch applied
> > > on top of renesas-next-v3.16-rc3-20140715 to boot to uerspace
> > > when compiled with shmobile_defconfig (+ an initrd).
> > > Without the irq number change the boot gets stuck in
> > > ip_auto_config (which presumably sleeps).
> > > 
> > > Laurent, should I squash the following in and queue-up the result?
> > 
> > Please do, and sorry for the mistake.
> 
> Not at all. I've made the same one several times myself.
> 
> > > diff --git a/arch/arm/boot/dts/r7s72100.dtsi
> > > b/arch/arm/boot/dts/r7s72100.dtsi index c902b0b..1d28d01 100644
> > > --- a/arch/arm/boot/dts/r7s72100.dtsi
> > > +++ b/arch/arm/boot/dts/r7s72100.dtsi
> > > @@ -232,7 +232,7 @@
> > >  	mtu2: timer at fcff0000 {
> > >  		compatible = "renesas,mtu2";
> > >  		reg = <0xfcff0000 0x400>;
> > > -		interrupts = <0 139 IRQ_TYPE_LEVEL_HIGH>;
> > > +		interrupts = <0 107 IRQ_TYPE_LEVEL_HIGH>;
> > >  		interrupt-names = "tgi0a";
> > >  		clocks = <&mstp3_clks R7S72100_CLK_MTU2>;
> > >  		clock-names = "fck";

For reference I have queued up the following.


From: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>

ARM: shmobile: r7s72100: Add MTU2 device to DT

Add the MTU2 counter to the r7s72100 device tree and make it disabled by
default.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Acked-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
[horms+renesas at verge.net.au correct irq number]
Signed-off-by: Simon Horman <horms+renesas@verge.net.au>
---
 arch/arm/boot/dts/r7s72100.dtsi | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/arch/arm/boot/dts/r7s72100.dtsi b/arch/arm/boot/dts/r7s72100.dtsi
index bdee225..1d28d01 100644
--- a/arch/arm/boot/dts/r7s72100.dtsi
+++ b/arch/arm/boot/dts/r7s72100.dtsi
@@ -229,6 +229,16 @@
 		status = "disabled";
 	};
 
+	mtu2: timer at fcff0000 {
+		compatible = "renesas,mtu2";
+		reg = <0xfcff0000 0x400>;
+		interrupts = <0 107 IRQ_TYPE_LEVEL_HIGH>;
+		interrupt-names = "tgi0a";
+		clocks = <&mstp3_clks R7S72100_CLK_MTU2>;
+		clock-names = "fck";
+		status = "disabled";
+	};
+
 	scif0: serial at e8007000 {
 		compatible = "renesas,scif-r7s72100", "renesas,scif";
 		reg = <0xe8007000 64>;
-- 
2.0.0

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

* [PATCH v5 8/8] ARM: shmobile: genmai-reference: Enable MTU2 in device tree
  2014-07-15 11:36         ` Simon Horman
@ 2014-07-15 12:28           ` Simon Horman
  0 siblings, 0 replies; 22+ messages in thread
From: Simon Horman @ 2014-07-15 12:28 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Jul 15, 2014 at 08:36:06PM +0900, Simon Horman wrote:
> On Tue, Jul 15, 2014 at 05:58:15PM +0900, Simon Horman wrote:
> > On Tue, Jul 15, 2014 at 05:54:32PM +0900, Simon Horman wrote:
> > > On Thu, Jul 10, 2014 at 11:54:30AM +0200, Wolfram Sang wrote:
> > > > On Wed, Jul 09, 2014 at 03:12:44PM +0200, Laurent Pinchart wrote:
> > > > > No more device needs to be added from platform code when booting the
> > > > > reference platform, move MTU2 registration from setup-r7s72100.c to
> > > > > board-genmai.c and remove the now empty r7s72100_add_dt_devices()
> > > > > function.
> > > > > 
> > > > > As the genmai_add_standard_devices() function is now identical to the
> > > > > default init_machine implementation, remove it as well.
> > > > > 
> > > > > Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
> > > > 
> > > > Yay, tasty!
> > > > 
> > > > Reviewed-by: Wolfram Sang <wsa@sang-engineering.com>
> > > 
> > > Hi Laurent,
> > > 
> > > I am having some trouble with this patch.
> > > In particular the shmobile defconfig with an initrd added
> > > (to compensate for the lack of ethernet and thus NFS) does
> > > not seem to make it to userspace with this patch applied :(
> > > 
> > > I am dropping it for now, but could you look into it?
> > 
> > I have likewise dropped "ARM: shmobile: r7s72100: Add MTU2 device to DT"
> > for now.
> 
> I believe that I have tracked down the problem and that it is
> in "ARM: shmobile: r7s72100: Add MTU2 device to DT".
> I will describe it in a response to that patch.

Now that problem has been resolved I have re-queued-up this patch.

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

end of thread, other threads:[~2014-07-15 12:28 UTC | newest]

Thread overview: 22+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-07-09 13:12 [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Laurent Pinchart
2014-07-09 13:12 ` [PATCH v5 1/8] ARM: shmobile: r8a7790: Add CMT devices to DT Laurent Pinchart
2014-07-09 13:12 ` [PATCH v5 2/8] ARM: shmobile: r8a7791: " Laurent Pinchart
2014-07-09 13:12 ` [PATCH v5 3/8] ARM: shmobile: r8a7779: Add TMU " Laurent Pinchart
2014-07-09 13:12 ` [PATCH v5 4/8] ARM: shmobile: r7s72100: Add MTU2 device " Laurent Pinchart
2014-07-10  9:53   ` Wolfram Sang
2014-07-15 11:47   ` Simon Horman
2014-07-15 11:55     ` Laurent Pinchart
2014-07-15 12:23       ` Simon Horman
2014-07-15 12:28         ` Simon Horman
2014-07-09 13:12 ` [PATCH v5 5/8] ARM: shmobile: lager-reference: Enable CMT0 in device tree Laurent Pinchart
2014-07-09 13:12 ` [PATCH v5 6/8] ARM: shmobile: koelsch-reference: " Laurent Pinchart
2014-07-09 13:12 ` [PATCH v5 7/8] ARM: shmobile: marzen-reference: Enable TMU0 " Laurent Pinchart
2014-07-09 13:12 ` [PATCH v5 8/8] ARM: shmobile: genmai-reference: Enable MTU2 " Laurent Pinchart
2014-07-10  9:54   ` Wolfram Sang
2014-07-15  8:54     ` Simon Horman
2014-07-15  8:58       ` Simon Horman
2014-07-15 11:36         ` Simon Horman
2014-07-15 12:28           ` Simon Horman
2014-07-15  5:01 ` [PATCH v5 0/8] Enable timers DT devices for Marzen, Genmai, Lager and Koelsch Simon Horman
2014-07-15  8:55   ` Simon Horman
2014-07-15 11:35     ` Simon Horman

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