You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
freifunkist-firmware/target/linux/brcm2708/patches-4.14/950-0206-overlays-Allow-mul...

77 lines
2.9 KiB

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
};
};