aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/brcm2708/patches-4.14/950-0206-overlays-Allow-multiple-instances-of-gpio-ir-tx.patch
blob: a9e58c53f1ff2b9163bc4acfd48f2c080ccee9ad (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
From 00267dfa96c9ac658c0bf7be980f2b72ba774921 Mon Sep 17 00:00:00 2001
From: Phil Elwell <phil@raspberrypi.org>
Date: Thu, 15 Feb 2018 09:36:52 +0000
Subject: [PATCH 206/454] overlays: Allow multiple instances of gpio-ir[-tx]

Signed-off-by: Phil Elwell <phil@raspberrypi.org>
---
 arch/arm/boot/dts/overlays/gpio-ir-overlay.dts    | 10 ++++++----
 arch/arm/boot/dts/overlays/gpio-ir-tx-overlay.dts | 10 ++++++----
 2 files changed, 12 insertions(+), 8 deletions(-)

--- a/arch/arm/boot/dts/overlays/gpio-ir-overlay.dts
+++ b/arch/arm/boot/dts/overlays/gpio-ir-overlay.dts
@@ -8,7 +8,7 @@
         fragment@0 {
                 target-path = "/";
                 __overlay__ {
-                        gpio_ir: ir-receiver {
+                        gpio_ir: ir-receiver@12 {
                                 compatible = "gpio-ir-receiver";
 
                                 // pin number, high or low
@@ -25,7 +25,7 @@
         fragment@1 {
                 target = <&gpio>;
                 __overlay__ {
-                        gpio_ir_pins: gpio_ir_pins {
+                        gpio_ir_pins: gpio_ir_pins@12 {
                                 brcm,pins = <18>;                       // pin 18
                                 brcm,function = <0>;                    // in
                                 brcm,pull = <1>;                        // down
@@ -35,8 +35,10 @@
 
         __overrides__ {
                 // parameters
-                gpio_pin =      <&gpio_ir>,"gpios:4",
-                                        <&gpio_ir_pins>,"brcm,pins:0";  // pin number
+                gpio_pin =      <&gpio_ir>,"gpios:4",           // pin number
+                                <&gpio_ir>,"reg:0",
+                                <&gpio_ir_pins>,"brcm,pins:0",
+                                <&gpio_ir_pins>,"reg:0";
                 gpio_pull = <&gpio_ir_pins>,"brcm,pull:0";              // pull-up/down state
 
                 rc-map-name = <&gpio_ir>,"linux,rc-map-name";           // default rc map
--- a/arch/arm/boot/dts/overlays/gpio-ir-tx-overlay.dts
+++ b/arch/arm/boot/dts/overlays/gpio-ir-tx-overlay.dts
@@ -7,7 +7,7 @@
 	fragment@0 {
 		target = <&gpio>;
 		__overlay__ {
-			gpio_ir_tx_pins: gpio_ir_tx_pins {
+			gpio_ir_tx_pins: gpio_ir_tx_pins@12 {
 				brcm,pins = <18>;
 				brcm,function = <1>;	// out
 			};
@@ -17,7 +17,7 @@
 	fragment@1 {
 		target-path = "/";
 		__overlay__ {
-			gpio_ir_tx: gpio-ir-transmitter {
+			gpio_ir_tx: gpio-ir-transmitter@12 {
 				compatible = "gpio-ir-tx";
 				pinctrl-names = "default";
 				pinctrl-0 = <&gpio_ir_tx_pins>;
@@ -27,8 +27,10 @@
 	};
 
 	__overrides__ {
-		gpio_pin = <&gpio_ir_tx>, "gpios:4",
-			   <&gpio_ir_tx_pins>, "brcm,pins:0";	// pin number
+		gpio_pin = <&gpio_ir_tx>, "gpios:4",           	// pin number
+			   <&gpio_ir_tx>, "reg:0",
+			   <&gpio_ir_tx_pins>, "brcm,pins:0",
+			   <&gpio_ir_tx_pins>, "reg:0";
 		invert = <&gpio_ir_tx>, "gpios:8";		// 1 = active low
 	};
 };