Skip to contentSkip to conversation

Exynos device tree clean-up for 3.12

PATCH Superseded Tomasz Figa 4 participants 15 messages Aug 20, 2013 – Aug 26, 2013

Subsystems (3)

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

cover Exynos device tree clean-up for 3.12

This series intends to fix small problems with Exynos device tree sources that I spotted during my work on other things. The fixes are mostly stylistic, without any funtional changes introduced, except patch 6/8, which makes the mshc node disabled by default, but for all affected boards it is enabled at board level.

Tomasz Figa (8):
Documentation: devicetree: Update Exynos MCT bindings description
ARM: dts: exynos4: Drop interrupt controller properties from MCT nodes
ARM: dts: exynos4x12: Move MCT node to exynos4x12.dtsi
ARM: dts: exynos4: Simplify MCT interrupt map
ARM: dts: exynos4x12: Move mshc node to exynos4x12.dtsi
ARM: dts: exynos4x12: Keep mshc node disabled by default
ARM: dts: exynos: Fix missing spaces after labels
ARM: dts: exynos4: Add missing unit-address of sysreg node

 .../bindings/timer/samsung,exynos4210-mct.txt      | 49 ++++++++++++++--------
 arch/arm/boot/dts/exynos4.dtsi                     |  6 +--
 arch/arm/boot/dts/exynos4210.dtsi                  | 23 +++++-----
 arch/arm/boot/dts/exynos4212.dtsi                  | 24 +----------
 arch/arm/boot/dts/exynos4412.dtsi                  | 36 +---------------
 arch/arm/boot/dts/exynos4x12.dtsi                  | 29 +++++++++++++
 arch/arm/boot/dts/exynos5.dtsi                     |  4 +-
 arch/arm/boot/dts/exynos5250-smdk5250.dts          |  6 +--
 arch/arm/boot/dts/exynos5440.dtsi                  |  2 +-
 9 files changed, 82 insertions(+), 97 deletions(-)
Signature · 1 line
1.8.3.2
#1 lore raw

PATCH 1/8 Documentation: devicetree: Update Exynos MCT bindings description

This patch updates description of device tree bindings for Exynos MCT (multicore timers). Namely:
- added note about simplified specification of local timer interrupts, when using single per-processor interrupt for all local timers,
- changed first example that was incorrectly suggesting that global timer interrupts are optional,
- simplified example interrupt map,
- added example showing simplified local timer interrupt specification.

---
 .../bindings/timer/samsung,exynos4210-mct.txt      | 49 ++++++++++++++--------
 1 file changed, 32 insertions(+), 17 deletions(-)
Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +32 -17
index b5a86d2..a5d6891f 100644
@@ -31,38 +31,53 @@ Required properties:
 	7: ..
 	i: Local Timer Interrupt n
 
-Example 1: In this example, the system uses only the first global timer
-	   interrupt generated by MCT and the remaining three global timer
-	   interrupts are unused. Two local timer interrupts have been
-	   specified.
+  For MCT block that uses a per-processor interrupt for local timers, such
+  as ones compatible with "samusng,exynos4412-mct", only one local timer
+  interrupt might be specified, meaning that all local timers use the same
+  per processor interrupt.
+
+Example 1: In this example, the IP contains two local timers, using separate
+	   interrupts, so two local timer interrupts have been specified,
+	   in addition to four global timer interrupts.
 
 	mct at 10050000 {
 		compatible = "samsung,exynos4210-mct";
 		reg = <0x10050000 0x800>;
-		interrupts = <0 57 0>, <0 0 0>, <0 0 0>, <0 0 0>,
+		interrupts = <0 57 0>, <0 69 0>, <0 70 0>, <0 71 0>,
 			     <0 42 0>, <0 48 0>;
 	};
 
-Example 2: In this example, the MCT global and local timer interrupts are
-	   connected to two separate interrupt controllers. Hence, an
-	   interrupt-map is created to map the interrupts to the respective
-	   interrupt controllers.
+Example 2: In this example, the timer interrupts are connected to two separate
+	   interrupt controllers. Hence, an interrupt-map is created to map
+	   the interrupts to the respective interrupt controllers.
 
 	mct at 101C0000 {
 		compatible = "samsung,exynos4210-mct";
 		reg = <0x101C0000 0x800>;
-		interrupt-controller;
-		#interrups-cells = <2>;
 		interrupt-parent = <&mct_map>;
-		interrupts = <0 0>, <1 0>, <2 0>, <3 0>,
-			     <4 0>, <5 0>;
+		interrupts = <0>, <1>, <2>, <3>, <4>, <5>;
 
 		mct_map: mct-map {
-			#interrupt-cells = <2>;
+			#interrupt-cells = <1>;
 			#address-cells = <0>;
 			#size-cells = <0>;
-			interrupt-map = <0x0 0 &combiner 23 3>,
-					<0x4 0 &gic 0 120 0>,
-					<0x5 0 &gic 0 121 0>;
+			interrupt-map = <0 &gic 0 57 0>,
+					<1 &gic 0 69 0>,
+					<2 &combiner 12 6>,
+					<3 &combiner 12 7>,
+					<4 &gic 0 42 0>,
+					<5 &gic 0 48 0>;
 		};
 	};
+
+Example 3: In this example, the IP contains four local timers, but using
+	   a per-processor interrupt to handle them. Either all the local
+	   timer interrupts can be specified, with the same interrupt specifier
+	   value or just the first one.
+
+	mct at 10050000 {
+		compatible = "samsung,exynos4412-mct";
+		reg = <0x10050000 0x800>;
+		interrupts = <0 57 0>, <0 69 0>, <0 70 0>, <0 71 0>,
+			     <0 42 0>/*, <0 42 0>, <0 42 0>, <0 42 0>*/;
+	};
Signature · 1 line
1.8.3.2
#2 lore raw

PATCH 1/8 Documentation: devicetree: Update Exynos MCT bindings description

Quoted 10 lines · Tomasz Figa

This patch updates description of device tree bindings for Exynos MCT (multicore timers). Namely:
- added note about simplified specification of local timer interrupts, when using single per-processor interrupt for all local timers,
- changed first example that was incorrectly suggesting that global timer interrupts are optional,
- simplified example interrupt map,
- added example showing simplified local timer interrupt specification.

Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt Required properties: · line 35

Quoted 7 lines
Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +2 -4
 
-Example 1: In this example, the system uses only the first global timer
-	   interrupt generated by MCT and the remaining three global timer
-	   interrupts are unused. Two local timer interrupts have been
-	   specified.
+  For MCT block that uses a per-processor interrupt for local timers, such
+  as ones compatible with "samusng,exynos4412-mct", only one local timer

samsung is typo'd there.

Quoted 10 lines
Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +3 -2
+Example 2: In this example, the timer interrupts are connected to two separate
+	   interrupt controllers. Hence, an interrupt-map is created to map
+	   the interrupts to the respective interrupt controllers.
 
 	mct at 101C0000 {
 		compatible = "samsung,exynos4210-mct";
 		reg = <0x101C0000 0x800>;
-		interrupt-controller;
-		#interrups-cells = <2>;
 		interrupt-parent = <&mct_map>;

Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt Required properties: · line 63

Quoted 10 lines
Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +2 -3
-		interrupts = <0 0>, <1 0>, <2 0>, <3 0>,
-			     <4 0>, <5 0>;
+		interrupts = <0>, <1>, <2>, <3>, <4>, <5>;
 
 		mct_map: mct-map {
-			#interrupt-cells = <2>;
+			#interrupt-cells = <1>;
 
 			#address-cells = <0>;
 			#size-cells = <0>;

I don't believe you need either of those two properties in a node solely used as an interrupt map.

Also, why not put the interrupt-map property directly into the main mct node; I don't believe there's any requirement nor advantage to it being a separate node.

Quoted 6 lines
Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +3 -3
-			interrupt-map = <0x0 0 &combiner 23 3>,
-					<0x4 0 &gic 0 120 0>,
-					<0x5 0 &gic 0 121 0>;
+			interrupt-map = <0 &gic 0 57 0>,
+					<1 &gic 0 69 0>,
+					<2 &combiner 12 6>,

Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt Required properties: · line 76

Quoted 10 lines
Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +7 -0
+					<3 &combiner 12 7>,
+					<4 &gic 0 42 0>,
+					<5 &gic 0 48 0>;
 		};
 	};
 
+Example 3: In this example, the IP contains four local timers, but using
+	   a per-processor interrupt to handle them. Either all the local
+	   timer interrupts can be specified, with the same interrupt specifier
+	   value or just the first one.

That sounds like it should be two separate examples.

Actually, there's already a 2-timer example above using separate interrupts, so why not make this example *just* be for the single-interrupt case?

Quoted 6 lines
Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +6 -0
+	mct at 10050000 {
+		compatible = "samsung,exynos4412-mct";
+		reg = <0x10050000 0x800>;
+		interrupts = <0 57 0>, <0 69 0>, <0 70 0>, <0 71 0>,
+			     <0 42 0>/*, <0 42 0>, <0 42 0>, <0 42 0>*/;
+	};
#3 lore raw

PATCH 1/8 Documentation: devicetree: Update Exynos MCT bindings description

Quoted 20 lines · On Tuesday 20 of August 2013 11:00:53 Stephen Warren wrote:
Quoted 19 lines · Tomasz Figa

This patch updates description of device tree bindings for Exynos MCT

(multicore timers). Namely:
- added note about simplified specification of local timer interrupts,

when using single per-processor interrupt for all local timers,

- changed first example that was incorrectly suggesting that global

timer interrupts are optional,

- simplified example interrupt map,
- added example showing simplified local timer interrupt specification.

diff --git a/Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt b/Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt

Quoted 9 lines
Quoted 8 lines

-Example 1: In this example, the system uses only the first global timer

Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +1 -3
-	   interrupt generated by MCT and the remaining three global timer
-	   interrupts are unused. Two local timer interrupts have been
-	   specified.
+  For MCT block that uses a per-processor interrupt for local timers,

such + as ones compatible with "samusng,exynos4412-mct", only one local timer

samsung is typo'd there.

Oops. ;)

Quoted 21 lines
Quoted 21 lines

+Example 2: In this example, the timer interrupts are connected to two
separate + interrupt controllers. Hence, an interrupt-map is
created to map + the interrupts to the respective interrupt
controllers.

(quoted diff) +1 -4
 	mct at 101C0000 {
 
 		compatible = "samsung,exynos4210-mct";
 		reg = <0x101C0000 0x800>;
 
-		interrupt-controller;
-		#interrups-cells = <2>;
 
 		interrupt-parent = <&mct_map>;
 
-		interrupts = <0 0>, <1 0>, <2 0>, <3 0>,
-			     <4 0>, <5 0>;
+		interrupts = <0>, <1>, <2>, <3>, <4>, <5>;
 
 		mct_map: mct-map {
Quoted 8 lines

Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt Required properties: · line 63

Quoted 5 lines
Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +1 -1
-			#interrupt-cells = <2>;
+			#interrupt-cells = <1>;
 
 			#address-cells = <0>;
 			#size-cells = <0>;

I don't believe you need either of those two properties in a node solely used as an interrupt map.

Well, you don't need #size-cells, as it is not used for interrupt-map property.

As for #address-cell property, you need it, as it defines how many cells are used in interrupt map specifier for unit address. See ePAPR 2.4.3.1 or
[1] for a description of interrupt-map property format.

[1] - http://devicetree.org/Device_Tree_Usage#Advanced_Interrupt_Mapping

Quoted 3 lines

Also, why not put the interrupt-map property directly into the main mct node; I don't believe there's any requirement nor advantage to it being a separate node.

It is more readable, as you don't mix virtual (helper) properties, with those describing the hardware. Otherwise both ways are technically correct, but not for all cases, i.e. only when #address-cells and #interrupt-cells properties aren't used for device's own purposes.

Quoted 21 lines
Quoted 15 lines
Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +7 -3
-			interrupt-map = <0x0 0 &combiner 23 3>,
-					<0x4 0 &gic 0 120 0>,
-					<0x5 0 &gic 0 121 0>;
+			interrupt-map = <0 &gic 0 57 0>,
+					<1 &gic 0 69 0>,
+					<2 &combiner 12 6>,
+					<3 &combiner 12 7>,
+					<4 &gic 0 42 0>,
+					<5 &gic 0 48 0>;
 
 		};
 
 	};
 
+Example 3: In this example, the IP contains four local timers, but
Quoted 3 lines

using + a per-processor interrupt to handle them. Either all the
local + timer interrupts can be specified, with the same interrupt
specifier + value or just the first one.

That sounds like it should be two separate examples.

Quoted 3 lines

Actually, there's already a 2-timer example above using separate interrupts, so why not make this example *just* be for the single-interrupt case?

Well, I wanted to show that both ways of specification would be equivalent here. If you insist on making it a single example, then I can send next version with this changed.

Best regards,
Tomasz

#4 lore raw

PATCH 1/8 Documentation: devicetree: Update Exynos MCT bindings description

Quoted 63 lines · Tomasz Figa
Quoted 20 lines · On Tuesday 20 of August 2013 11:00:53 Stephen Warren wrote:
Quoted 19 lines · Tomasz Figa

This patch updates description of device tree bindings for Exynos MCT

(multicore timers). Namely:
- added note about simplified specification of local timer interrupts,

when using single per-processor interrupt for all local timers,

- changed first example that was incorrectly suggesting that global

timer interrupts are optional,

- simplified example interrupt map,
- added example showing simplified local timer interrupt specification.

diff --git a/Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt b/Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt

Quoted 9 lines
Quoted 8 lines

-Example 1: In this example, the system uses only the first global timer

Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +1 -3
-	   interrupt generated by MCT and the remaining three global timer
-	   interrupts are unused. Two local timer interrupts have been
-	   specified.
+  For MCT block that uses a per-processor interrupt for local timers,

such + as ones compatible with "samusng,exynos4412-mct", only one local timer

samsung is typo'd there.

Oops. ;)

Quoted 21 lines
Quoted 21 lines

+Example 2: In this example, the timer interrupts are connected to two
separate + interrupt controllers. Hence, an interrupt-map is
created to map + the interrupts to the respective interrupt
controllers.

(quoted diff) +1 -4
 	mct at 101C0000 {
 
 		compatible = "samsung,exynos4210-mct";
 		reg = <0x101C0000 0x800>;
 
-		interrupt-controller;
-		#interrups-cells = <2>;
 
 		interrupt-parent = <&mct_map>;
 
-		interrupts = <0 0>, <1 0>, <2 0>, <3 0>,
-			     <4 0>, <5 0>;
+		interrupts = <0>, <1>, <2>, <3>, <4>, <5>;
 
 		mct_map: mct-map {
Quoted 8 lines

Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt Required properties: · line 63

Quoted 5 lines
Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +1 -1
-			#interrupt-cells = <2>;
+			#interrupt-cells = <1>;
 
 			#address-cells = <0>;
 			#size-cells = <0>;

I don't believe you need either of those two properties in a node solely used as an interrupt map.

Quoted 8 lines

Well, you don't need #size-cells, as it is not used for interrupt-map property.

As for #address-cell property, you need it, as it defines how many cells are used in interrupt map specifier for unit address. See ePAPR 2.4.3.1 or
[1] for a description of interrupt-map property format.

[1] - http://devicetree.org/Device_Tree_Usage#Advanced_Interrupt_Mapping

Uggh. Yes, you're right.

Quoted 8 lines
Quoted 3 lines

Also, why not put the interrupt-map property directly into the main mct node; I don't believe there's any requirement nor advantage to it being a separate node.

It is more readable, as you don't mix virtual (helper) properties, with those describing the hardware. Otherwise both ways are technically correct, but not for all cases, i.e. only when #address-cells and #interrupt-cells properties aren't used for device's own purposes.

Hmm. I see the argument.

Quoted 7 lines
Quoted 7 lines
Quoted 4 lines

+Example 3: In this example, the IP contains four local timers, but
using + a per-processor interrupt to handle them. Either all the
local + timer interrupts can be specified, with the same interrupt
specifier + value or just the first one.

That sounds like it should be two separate examples.

Quoted 7 lines
Quoted 3 lines

Actually, there's already a 2-timer example above using separate interrupts, so why not make this example *just* be for the single-interrupt case?

Well, I wanted to show that both ways of specification would be equivalent here. If you insist on making it a single example, then I can send next version with this changed.

Oh! I didn't see the /* */ at all in the third example...

I think it'd be more obvious if you wrote the whole property out twice:

+ interrupts = <0 57 0>, <0 69 0>, <0 70 0>, <0 71 0>,
+ <0 42 0>/*, <0 42 0>, <0 42 0>, <0 42 0>*/;
+ /* or: */
+ interrupts = <0 57 0>, <0 69 0>, <0 70 0>, <0 71 0>,
+ <0 42 0>;

#5 lore raw

PATCH 1/8 Documentation: devicetree: Update Exynos MCT bindings description

Quoted 36 lines · On Tuesday 20 of August 2013 14:41:15 Stephen Warren wrote:
Quoted 35 lines · Tomasz Figa
Quoted 33 lines · On Tuesday 20 of August 2013 11:00:53 Stephen Warren wrote:
Quoted 27 lines · Tomasz Figa

This patch updates description of device tree bindings for Exynos MCT

(multicore timers). Namely:
- added note about simplified specification of local timer interrupts,

when using single per-processor interrupt for all local timers,

- changed first example that was incorrectly suggesting that global

timer interrupts are optional,

- simplified example interrupt map,
- added example showing simplified local timer interrupt specification.

diff --git a/Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt b/Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt

-Example 1: In this example, the system uses only the first global timer

Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +1 -3
-	   interrupt generated by MCT and the remaining three global timer
-	   interrupts are unused. Two local timer interrupts have been
-	   specified.
+  For MCT block that uses a per-processor interrupt for local
Quoted 3 lines

timers,
such + as ones compatible with "samusng,exynos4412-mct", only one local timer

samsung is typo'd there.

Quoted 5 lines
Quoted 5 lines

Oops. ;)

Quoted 3 lines
Quoted 3 lines

+Example 2: In this example, the timer interrupts are connected to two
separate + interrupt controllers. Hence, an interrupt-map

is

Quoted 45 lines
Quoted 31 lines
Quoted 19 lines
Quoted 19 lines

created to map + the interrupts to the respective interrupt
controllers.

(quoted diff) +1 -4
 	mct at 101C0000 {
 
 		compatible = "samsung,exynos4210-mct";
 		reg = <0x101C0000 0x800>;
 
-		interrupt-controller;
-		#interrups-cells = <2>;
 
 		interrupt-parent = <&mct_map>;
 
-		interrupts = <0 0>, <1 0>, <2 0>, <3 0>,
-			     <4 0>, <5 0>;
+		interrupts = <0>, <1>, <2>, <3>, <4>, <5>;
 
 		mct_map: mct-map {
Quoted 8 lines

Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt Required properties: · line 63

Quoted 5 lines
Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +1 -1
-			#interrupt-cells = <2>;
+			#interrupt-cells = <1>;
 
 			#address-cells = <0>;
 			#size-cells = <0>;

I don't believe you need either of those two properties in a node solely used as an interrupt map.

Well, you don't need #size-cells, as it is not used for interrupt-map property.

Quoted 6 lines

As for #address-cell property, you need it, as it defines how many cells are used in interrupt map specifier for unit address. See ePAPR 2.4.3.1 or [1] for a description of interrupt-map property format.

[1] -
http://devicetree.org/Device_Tree_Usage#Advanced_Interrupt_Mapping

Uggh. Yes, you're right.

Quoted 6 lines
Quoted 5 lines

Also, why not put the interrupt-map property directly into the main mct
node; I don't believe there's any requirement nor advantage to it being
a separate node.

Quoted 10 lines
Quoted 5 lines

It is more readable, as you don't mix virtual (helper) properties, with
those describing the hardware. Otherwise both ways are technically correct, but not for all cases, i.e. only when #address-cells and #interrupt-cells properties aren't used for device's own purposes.

Hmm. I see the argument.

Quoted 2 lines
Quoted 2 lines
Quoted 2 lines

+Example 3: In this example, the IP contains four local timers, but
using + a per-processor interrupt to handle them. Either all

the

Quoted 18 lines
Quoted 6 lines
Quoted 6 lines
Quoted 3 lines

local + timer interrupts can be specified, with the same
interrupt
specifier + value or just the first one.

That sounds like it should be two separate examples.

Quoted 7 lines
Quoted 3 lines

Actually, there's already a 2-timer example above using separate interrupts, so why not make this example *just* be for the single-interrupt case?

Well, I wanted to show that both ways of specification would be equivalent here. If you insist on making it a single example, then I can send next version with this changed.

Oh! I didn't see the /* */ at all in the third example...

I think it'd be more obvious if you wrote the whole property out twice:

Review

Quoted 5 lines
(quoted diff) +5 -0
+		interrupts = <0 57 0>, <0 69 0>, <0 70 0>, <0 71 0>,
+			     <0 42 0>/*, <0 42 0>, <0 42 0>, <0 42 0>*/;
+		/* or: */
+		interrupts = <0 57 0>, <0 69 0>, <0 70 0>, <0 71 0>,
+			     <0 42 0>;

That's a good idea. I will send new version with the typo above fixed and this example done the way you proposed.

Best regards,
Tomasz

#6 lore raw

PATCH v2 1/8 Documentation: devicetree: Update Exynos MCT bindings description

In reply to Tomasz Figa

This patch updates description of device tree bindings for Exynos MCT (multicore timers). Namely:
- added note about simplified specification of local timer interrupts, when using single per-processor interrupt for all local timers,
- changed first example that was incorrectly suggesting that global timer interrupts are optional,
- simplified example interrupt map,
- added example showing simplified local timer interrupt specification.

---
 .../bindings/timer/samsung,exynos4210-mct.txt      | 54 +++++++++++++++-------
 1 file changed, 37 insertions(+), 17 deletions(-)

Changes since v1:
- corrected typo reported by Stephen Warren,
- edited last example to use separate properties to represent possible alternatives, as suggested by Stephen Warren.

Documentation/devicetree/bindings/timer/samsung,exynos4210-mct.txt +37 -17
index b5a86d2..167d5da 100644
@@ -31,38 +31,58 @@ Required properties:
 	7: ..
 	i: Local Timer Interrupt n
 
-Example 1: In this example, the system uses only the first global timer
-	   interrupt generated by MCT and the remaining three global timer
-	   interrupts are unused. Two local timer interrupts have been
-	   specified.
+  For MCT block that uses a per-processor interrupt for local timers, such
+  as ones compatible with "samsung,exynos4412-mct", only one local timer
+  interrupt might be specified, meaning that all local timers use the same
+  per processor interrupt.
+
+Example 1: In this example, the IP contains two local timers, using separate
+	   interrupts, so two local timer interrupts have been specified,
+	   in addition to four global timer interrupts.
 
 	mct at 10050000 {
 		compatible = "samsung,exynos4210-mct";
 		reg = <0x10050000 0x800>;
-		interrupts = <0 57 0>, <0 0 0>, <0 0 0>, <0 0 0>,
+		interrupts = <0 57 0>, <0 69 0>, <0 70 0>, <0 71 0>,
 			     <0 42 0>, <0 48 0>;
 	};
 
-Example 2: In this example, the MCT global and local timer interrupts are
-	   connected to two separate interrupt controllers. Hence, an
-	   interrupt-map is created to map the interrupts to the respective
-	   interrupt controllers.
+Example 2: In this example, the timer interrupts are connected to two separate
+	   interrupt controllers. Hence, an interrupt-map is created to map
+	   the interrupts to the respective interrupt controllers.
 
 	mct at 101C0000 {
 		compatible = "samsung,exynos4210-mct";
 		reg = <0x101C0000 0x800>;
-		interrupt-controller;
-		#interrups-cells = <2>;
 		interrupt-parent = <&mct_map>;
-		interrupts = <0 0>, <1 0>, <2 0>, <3 0>,
-			     <4 0>, <5 0>;
+		interrupts = <0>, <1>, <2>, <3>, <4>, <5>;
 
 		mct_map: mct-map {
-			#interrupt-cells = <2>;
+			#interrupt-cells = <1>;
 			#address-cells = <0>;
 			#size-cells = <0>;
-			interrupt-map = <0x0 0 &combiner 23 3>,
-					<0x4 0 &gic 0 120 0>,
-					<0x5 0 &gic 0 121 0>;
+			interrupt-map = <0 &gic 0 57 0>,
+					<1 &gic 0 69 0>,
+					<2 &combiner 12 6>,
+					<3 &combiner 12 7>,
+					<4 &gic 0 42 0>,
+					<5 &gic 0 48 0>;
 		};
 	};
+
+Example 3: In this example, the IP contains four local timers, but using
+	   a per-processor interrupt to handle them. Either all the local
+	   timer interrupts can be specified, with the same interrupt specifier
+	   value or just the first one.
+
+	mct at 10050000 {
+		compatible = "samsung,exynos4412-mct";
+		reg = <0x10050000 0x800>;
+
+		/* Both ways are possible in this case. Either: */
+		interrupts = <0 57 0>, <0 69 0>, <0 70 0>, <0 71 0>,
+			     <0 42 0>;
+		/* or: */
+		interrupts = <0 57 0>, <0 69 0>, <0 70 0>, <0 71 0>,
+			     <0 42 0>, <0 42 0>, <0 42 0>, <0 42 0>;
+	};
Signature · 1 line
1.8.3.2
#7 lore raw

PATCH 2/8 ARM: dts: exynos4: Drop interrupt controller properties from MCT nodes

In reply to Tomasz Figa

MCT is not an interrupt controller and so there is no point for device tree nodes representing it to contain interrupt-controller and #interrupt-cells properties.

---
 arch/arm/boot/dts/exynos4210.dtsi | 2 --
 arch/arm/boot/dts/exynos4212.dtsi | 2 --
 arch/arm/boot/dts/exynos4412.dtsi | 2 --
 3 files changed, 6 deletions(-)
arch/arm/boot/dts/exynos4210.dtsi +0 -2
index 057d682..1a6440ae6 100644
@@ -51,8 +51,6 @@
 	mct at 10050000 {
 		compatible = "samsung,exynos4210-mct";
 		reg = <0x10050000 0x800>;
-		interrupt-controller;
-		#interrups-cells = <2>;
 		interrupt-parent = <&mct_map>;
 		interrupts = <0 0>, <1 0>, <2 0>, <3 0>,
 			     <4 0>, <5 0>;
arch/arm/boot/dts/exynos4212.dtsi +0 -2
index 6f34d7f..028752e 100644
@@ -38,8 +38,6 @@
 	mct at 10050000 {
 		compatible = "samsung,exynos4412-mct";
 		reg = <0x10050000 0x800>;
-		interrupt-controller;
-		#interrups-cells = <2>;
 		interrupt-parent = <&mct_map>;
 		interrupts = <0 0>, <1 0>, <2 0>, <3 0>,
 			     <4 0>, <5 0>;
arch/arm/boot/dts/exynos4412.dtsi +0 -2
index e743e67..85d2c26 100644
@@ -38,8 +38,6 @@
 	mct at 10050000 {
 		compatible = "samsung,exynos4412-mct";
 		reg = <0x10050000 0x800>;
-		interrupt-controller;
-		#interrups-cells = <2>;
 		interrupt-parent = <&mct_map>;
 		interrupts = <0 0>, <1 0>, <2 0>, <3 0>,
 			     <4 0>, <5 0>, <6 0>, <7 0>;
Signature · 1 line
1.8.3.2
#8 lore raw

PATCH 3/8 ARM: dts: exynos4x12: Move MCT node to exynos4x12.dtsi

In reply to Tomasz Figa

For MCT block compatible with "samsung,exynos4412-mct", that uses PPI interrupts for local timers, only one local interrupt needs to be specified, since it is a per-processor interrupt.

This allows moving MCT node of Exynos4x12 SoCs back to common exynos4x12.dtsi, since they have the same set of interrupts to be specified, which was the only difference.

---
 arch/arm/boot/dts/exynos4212.dtsi | 20 --------------------
 arch/arm/boot/dts/exynos4412.dtsi | 24 ------------------------
 arch/arm/boot/dts/exynos4x12.dtsi | 20 ++++++++++++++++++++
 3 files changed, 20 insertions(+), 44 deletions(-)
arch/arm/boot/dts/exynos4212.dtsi +0 -20
index 028752e..443b8a2 100644
@@ -34,24 +34,4 @@
 			     <0 12 0>, <0 13 0>, <0 14 0>, <0 15 0>,
 			     <0 107 0>, <0 108 0>;
 	};
-
-	mct at 10050000 {
-		compatible = "samsung,exynos4412-mct";
-		reg = <0x10050000 0x800>;
-		interrupt-parent = <&mct_map>;
-		interrupts = <0 0>, <1 0>, <2 0>, <3 0>,
-			     <4 0>, <5 0>;
-
-		mct_map: mct-map {
-			#interrupt-cells = <2>;
-			#address-cells = <0>;
-			#size-cells = <0>;
-			interrupt-map = <0x0 0 &gic 0 57 0>,
-					<0x1 0 &combiner 12 5>,
-					<0x2 0 &combiner 12 6>,
-					<0x3 0 &combiner 12 7>,
-					<0x4 0 &gic 1 12 0>,
-					<0x5 0 &gic 1 12 0>;
-		};
-	};
 };
arch/arm/boot/dts/exynos4412.dtsi +0 -24
index 85d2c26..1388ce0 100644
@@ -35,30 +35,6 @@
 			     <0 107 0>, <0 108 0>, <0 48 0>, <0 42 0>;
 	};
 
-	mct at 10050000 {
-		compatible = "samsung,exynos4412-mct";
-		reg = <0x10050000 0x800>;
-		interrupt-parent = <&mct_map>;
-		interrupts = <0 0>, <1 0>, <2 0>, <3 0>,
-			     <4 0>, <5 0>, <6 0>, <7 0>;
-		clocks = <&clock 3>, <&clock 344>;
-		clock-names = "fin_pll", "mct";
-
-		mct_map: mct-map {
-			#interrupt-cells = <2>;
-			#address-cells = <0>;
-			#size-cells = <0>;
-			interrupt-map = <0x0 0 &gic 0 57 0>,
-					<0x1 0 &combiner 12 5>,
-					<0x2 0 &combiner 12 6>,
-					<0x3 0 &combiner 12 7>,
-					<0x4 0 &gic 1 12 0>,
-					<0x5 0 &gic 1 12 0>,
-					<0x6 0 &gic 1 12 0>,
-					<0x7 0 &gic 1 12 0>;
-		};
-	};
-
 	mshc at 12550000 {
 		compatible = "samsung,exynos4412-dw-mshc";
 		reg = <0x12550000 0x1000>;
arch/arm/boot/dts/exynos4x12.dtsi +20 -0
index ad531fe..5012bc8 100644
@@ -41,6 +41,26 @@
 		#clock-cells = <1>;
 	};
 
+	mct at 10050000 {
+		compatible = "samsung,exynos4412-mct";
+		reg = <0x10050000 0x800>;
+		interrupt-parent = <&mct_map>;
+		interrupts = <0 0>, <1 0>, <2 0>, <3 0>, <4 0>;
+		clocks = <&clock 3>, <&clock 344>;
+		clock-names = "fin_pll", "mct";
+
+		mct_map: mct-map {
+			#interrupt-cells = <2>;
+			#address-cells = <0>;
+			#size-cells = <0>;
+			interrupt-map = <0x0 0 &gic 0 57 0>,
+					<0x1 0 &combiner 12 5>,
+					<0x2 0 &combiner 12 6>,
+					<0x3 0 &combiner 12 7>,
+					<0x4 0 &gic 1 12 0>;
+		};
+	};
+
 	pinctrl_0: pinctrl at 11400000 {
 		compatible = "samsung,exynos4x12-pinctrl";
 		reg = <0x11400000 0x1000>;
Signature · 1 line
1.8.3.2
#9 lore raw

PATCH 4/8 ARM: dts: exynos4: Simplify MCT interrupt map

In reply to Tomasz Figa

There is no need to use two cells for interrupt specifiers inside the MCT interrupt map, so this patch simplifies the map to use one cell.

---
 arch/arm/boot/dts/exynos4210.dtsi | 17 ++++++++---------
 arch/arm/boot/dts/exynos4x12.dtsi | 14 +++++++-------
 2 files changed, 15 insertions(+), 16 deletions(-)
arch/arm/boot/dts/exynos4210.dtsi +8 -9
index 1a6440ae6..b0fee69 100644
@@ -52,21 +52,20 @@
 		compatible = "samsung,exynos4210-mct";
 		reg = <0x10050000 0x800>;
 		interrupt-parent = <&mct_map>;
-		interrupts = <0 0>, <1 0>, <2 0>, <3 0>,
-			     <4 0>, <5 0>;
+		interrupts = <0>, <1>, <2>, <3>, <4>, <5>;
 		clocks = <&clock 3>, <&clock 344>;
 		clock-names = "fin_pll", "mct";
 
 		mct_map: mct-map {
-			#interrupt-cells = <2>;
+			#interrupt-cells = <1>;
 			#address-cells = <0>;
 			#size-cells = <0>;
-			interrupt-map = <0x0 0 &gic 0 57 0>,
-					<0x1 0 &gic 0 69 0>,
-					<0x2 0 &combiner 12 6>,
-					<0x3 0 &combiner 12 7>,
-					<0x4 0 &gic 0 42 0>,
-					<0x5 0 &gic 0 48 0>;
+			interrupt-map = <0 &gic 0 57 0>,
+					<1 &gic 0 69 0>,
+					<2 &combiner 12 6>,
+					<3 &combiner 12 7>,
+					<4 &gic 0 42 0>,
+					<5 &gic 0 48 0>;
 		};
 	};
 
arch/arm/boot/dts/exynos4x12.dtsi +7 -7
index 5012bc8..3d7182a 100644
@@ -45,19 +45,19 @@
 		compatible = "samsung,exynos4412-mct";
 		reg = <0x10050000 0x800>;
 		interrupt-parent = <&mct_map>;
-		interrupts = <0 0>, <1 0>, <2 0>, <3 0>, <4 0>;
+		interrupts = <0>, <1>, <2>, <3>, <4>;
 		clocks = <&clock 3>, <&clock 344>;
 		clock-names = "fin_pll", "mct";
 
 		mct_map: mct-map {
-			#interrupt-cells = <2>;
+			#interrupt-cells = <1>;
 			#address-cells = <0>;
 			#size-cells = <0>;
-			interrupt-map = <0x0 0 &gic 0 57 0>,
-					<0x1 0 &combiner 12 5>,
-					<0x2 0 &combiner 12 6>,
-					<0x3 0 &combiner 12 7>,
-					<0x4 0 &gic 1 12 0>;
+			interrupt-map = <0 &gic 0 57 0>,
+					<1 &combiner 12 5>,
+					<2 &combiner 12 6>,
+					<3 &combiner 12 7>,
+					<4 &gic 1 12 0>;
 		};
 	};
 
Signature · 1 line
1.8.3.2
#10 lore raw

PATCH 5/8 ARM: dts: exynos4x12: Move mshc node to exynos4x12.dtsi

In reply to Tomasz Figa

All SoCs from Exynos4x12 series contain the MSHC block, so its node can be located in exynos4x12.dtsi.

---
 arch/arm/boot/dts/exynos4412.dtsi | 8 --------
 arch/arm/boot/dts/exynos4x12.dtsi | 8 ++++++++
 2 files changed, 8 insertions(+), 8 deletions(-)
arch/arm/boot/dts/exynos4412.dtsi +0 -8
index 1388ce0..6b0184f 100644
@@ -34,12 +34,4 @@
 			     <0 12 0>, <0 13 0>, <0 14 0>, <0 15 0>,
 			     <0 107 0>, <0 108 0>, <0 48 0>, <0 42 0>;
 	};
-
-	mshc at 12550000 {
-		compatible = "samsung,exynos4412-dw-mshc";
-		reg = <0x12550000 0x1000>;
-		interrupts = <0 77 0>;
-		#address-cells = <1>;
-		#size-cells = <0>;
-	};
 };
arch/arm/boot/dts/exynos4x12.dtsi +8 -0
index 3d7182a..06cef96 100644
@@ -196,4 +196,12 @@
 			};
 		};
 	};
+
+	mshc at 12550000 {
+		compatible = "samsung,exynos4412-dw-mshc";
+		reg = <0x12550000 0x1000>;
+		interrupts = <0 77 0>;
+		#address-cells = <1>;
+		#size-cells = <0>;
+	};
 };
Signature · 1 line
1.8.3.2
#11 lore raw

PATCH 6/8 ARM: dts: exynos4x12: Keep mshc node disabled by default

In reply to Tomasz Figa

MSHC node requires additional board-specific data, so it should be disabled by default. Board dts files already have status override for it, so only the change in exynso4x12.dtsi is needed.

---
 arch/arm/boot/dts/exynos4x12.dtsi | 1 +
 1 file changed, 1 insertion(+)
arch/arm/boot/dts/exynos4x12.dtsi +1 -0
index 06cef96..2f243c2 100644
@@ -203,5 +203,6 @@
 		interrupts = <0 77 0>;
 		#address-cells = <1>;
 		#size-cells = <0>;
+		status = "disabled";
 	};
 };
Signature · 1 line
1.8.3.2
#12 lore raw

PATCH 7/8 ARM: dts: exynos: Fix missing spaces after labels

In reply to Tomasz Figa

For consistency with other device tree nodes, this patch adds missing spaces after node labels.

---
 arch/arm/boot/dts/exynos4.dtsi            | 4 ++--
 arch/arm/boot/dts/exynos4210.dtsi         | 4 ++--
 arch/arm/boot/dts/exynos4212.dtsi         | 2 +-
 arch/arm/boot/dts/exynos4412.dtsi         | 2 +-
 arch/arm/boot/dts/exynos5.dtsi            | 4 ++--
 arch/arm/boot/dts/exynos5250-smdk5250.dts | 6 +++---
 arch/arm/boot/dts/exynos5440.dtsi         | 2 +-
 7 files changed, 12 insertions(+), 12 deletions(-)
arch/arm/boot/dts/exynos4.dtsi +2 -2
index 93c2501..892d5ea 100644
@@ -79,14 +79,14 @@
 		reg = <0x10023CE0 0x20>;
 	};
 
-	gic:interrupt-controller at 10490000 {
+	gic: interrupt-controller at 10490000 {
 		compatible = "arm,cortex-a9-gic";
 		#interrupt-cells = <3>;
 		interrupt-controller;
 		reg = <0x10490000 0x1000>, <0x10480000 0x100>;
 	};
 
-	combiner:interrupt-controller at 10440000 {
+	combiner: interrupt-controller at 10440000 {
 		compatible = "samsung,exynos4210-combiner";
 		#interrupt-cells = <2>;
 		interrupt-controller;
arch/arm/boot/dts/exynos4210.dtsi +2 -2
index b0fee69..48ecd7a 100644
@@ -36,11 +36,11 @@
 		reg = <0x10023CA0 0x20>;
 	};
 
-	gic:interrupt-controller at 10490000 {
+	gic: interrupt-controller at 10490000 {
 		cpu-offset = <0x8000>;
 	};
 
-	combiner:interrupt-controller at 10440000 {
+	combiner: interrupt-controller at 10440000 {
 		samsung,combiner-nr = <16>;
 		interrupts = <0 0 0>, <0 1 0>, <0 2 0>, <0 3 0>,
 			     <0 4 0>, <0 5 0>, <0 6 0>, <0 7 0>,
arch/arm/boot/dts/exynos4212.dtsi +1 -1
index 443b8a2..94a43f9 100644
@@ -22,7 +22,7 @@
 / {
 	compatible = "samsung,exynos4212";
 
-	gic:interrupt-controller at 10490000 {
+	gic: interrupt-controller at 10490000 {
 		cpu-offset = <0x8000>;
 	};
 
arch/arm/boot/dts/exynos4412.dtsi +1 -1
index 6b0184f..5a82f67 100644
@@ -22,7 +22,7 @@
 / {
 	compatible = "samsung,exynos4412";
 
-	gic:interrupt-controller at 10490000 {
+	gic: interrupt-controller at 10490000 {
 		cpu-offset = <0x4000>;
 	};
 
arch/arm/boot/dts/exynos5.dtsi +2 -2
index 6afa57d..a25c5ac 100644
@@ -23,7 +23,7 @@
 		reg = <0x10000000 0x100>;
 	};
 
-	combiner:interrupt-controller at 10440000 {
+	combiner: interrupt-controller at 10440000 {
 		compatible = "samsung,exynos4210-combiner";
 		#interrupt-cells = <2>;
 		interrupt-controller;
@@ -39,7 +39,7 @@
 				<0 28 0>, <0 29 0>, <0 30 0>, <0 31 0>;
 	};
 
-	gic:interrupt-controller at 10481000 {
+	gic: interrupt-controller at 10481000 {
 		compatible = "arm,cortex-a15-gic", "arm,cortex-a9-gic";
 		#interrupt-cells = <3>;
 		interrupt-controller;
arch/arm/boot/dts/exynos5250-smdk5250.dts +3 -3
index 2538b32..56334d8 100644
@@ -37,7 +37,7 @@
 		};
 	};
 
-	vdd:fixed-regulator at 0 {
+	vdd: fixed-regulator at 0 {
 		compatible = "regulator-fixed";
 		regulator-name = "vdd-supply";
 		regulator-min-microvolt = <1800000>;
@@ -45,7 +45,7 @@
 		regulator-always-on;
 	};
 
-	dbvdd:fixed-regulator at 1 {
+	dbvdd: fixed-regulator at 1 {
 		compatible = "regulator-fixed";
 		regulator-name = "dbvdd-supply";
 		regulator-min-microvolt = <3300000>;
@@ -53,7 +53,7 @@
 		regulator-always-on;
 	};
 
-	spkvdd:fixed-regulator at 2 {
+	spkvdd: fixed-regulator at 2 {
 		compatible = "regulator-fixed";
 		regulator-name = "spkvdd-supply";
 		regulator-min-microvolt = <5000000>;
arch/arm/boot/dts/exynos5440.dtsi +1 -1
index 5d6cf49..799cb77 100644
@@ -29,7 +29,7 @@
 		#clock-cells = <1>;
 	};
 
-	gic:interrupt-controller at 2E0000 {
+	gic: interrupt-controller at 2E0000 {
 		compatible = "arm,cortex-a15-gic";
 		#interrupt-cells = <3>;
 		interrupt-controller;
Signature · 1 line
1.8.3.2
#13 lore raw

PATCH 8/8 ARM: dts: exynos4: Add missing unit-address of sysreg node

In reply to Tomasz Figa

The node contains reg property, so unit-address suffix should be present in its name.

---
 arch/arm/boot/dts/exynos4.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm/boot/dts/exynos4.dtsi +1 -1
index 892d5ea..92c9d24 100644
@@ -93,7 +93,7 @@
 		reg = <0x10440000 0x1000>;
 	};
 
-	sys_reg: sysreg {
+	sys_reg: sysreg at 10010000 {
 		compatible = "samsung,exynos4-sysreg", "syscon";
 		reg = <0x10010000 0x400>;
 	};
Signature · 1 line
1.8.3.2
#14 lore raw

cover Exynos device tree clean-up for 3.12

In reply to Tomasz Figa
Quoted 16 lines · Tomasz Figa

This series intends to fix small problems with Exynos device tree sources that I spotted during my work on other things. The fixes are mostly stylistic, without any funtional changes introduced, except patch 6/8, which makes the mshc node disabled by default, but for all affected boards it is enabled at board level.

Tomasz Figa (8):
Documentation: devicetree: Update Exynos MCT bindings description
ARM: dts: exynos4: Drop interrupt controller properties from MCT nodes
ARM: dts: exynos4x12: Move MCT node to exynos4x12.dtsi
ARM: dts: exynos4: Simplify MCT interrupt map
ARM: dts: exynos4x12: Move mshc node to exynos4x12.dtsi
ARM: dts: exynos4x12: Keep mshc node disabled by default
ARM: dts: exynos: Fix missing spaces after labels
ARM: dts: exynos4: Add missing unit-address of sysreg node

Quoted 10 lines
 .../bindings/timer/samsung,exynos4210-mct.txt      | 49 ++++++++++++++--------
 arch/arm/boot/dts/exynos4.dtsi                     |  6 +--
 arch/arm/boot/dts/exynos4210.dtsi                  | 23 +++++-----
 arch/arm/boot/dts/exynos4212.dtsi                  | 24 +----------
 arch/arm/boot/dts/exynos4412.dtsi                  | 36 +---------------
 arch/arm/boot/dts/exynos4x12.dtsi                  | 29 +++++++++++++
 arch/arm/boot/dts/exynos5.dtsi                     |  4 +-
 arch/arm/boot/dts/exynos5250-smdk5250.dts          |  6 +--
 arch/arm/boot/dts/exynos5440.dtsi                  |  2 +-
 9 files changed, 82 insertions(+), 97 deletions(-)

Thanks Tomasz, for the whole series:

Regards,

Signature · 2 lines
Sylwester Nawrocki
Samsung R&D Institute Poland