aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ath79/dts
diff options
context:
space:
mode:
authorMauri Sandberg <maukka@ext.kapsi.fi>2022-02-06 01:07:10 +0200
committerPetr Štetiar <ynezz@true.cz>2022-02-19 13:10:01 +0100
commitb99aee5080c05edd1681018c95f4ebdd762c8bae (patch)
tree46f5410ec22394acb1b608e9e731e14d034bfedf /target/linux/ath79/dts
parent2f50d6516125209cd37200ae48cf2b56a83d3822 (diff)
downloadupstream-b99aee5080c05edd1681018c95f4ebdd762c8bae.tar.gz
upstream-b99aee5080c05edd1681018c95f4ebdd762c8bae.tar.bz2
upstream-b99aee5080c05edd1681018c95f4ebdd762c8bae.zip
ath79: use gpio-cascade for Buffalo WZR-HP-G300NH
Switch to a generic GPIO cascade driver. Signed-off-by: Mauri Sandberg <maukka@ext.kapsi.fi> Signed-off-by: Petr Štetiar <ynezz@true.cz> [missing commit description]
Diffstat (limited to 'target/linux/ath79/dts')
-rw-r--r--target/linux/ath79/dts/ar9132_buffalo_wzr-hp-g300nh.dtsi41
1 files changed, 31 insertions, 10 deletions
diff --git a/target/linux/ath79/dts/ar9132_buffalo_wzr-hp-g300nh.dtsi b/target/linux/ath79/dts/ar9132_buffalo_wzr-hp-g300nh.dtsi
index ca1eeab449..7b0c09f68e 100644
--- a/target/linux/ath79/dts/ar9132_buffalo_wzr-hp-g300nh.dtsi
+++ b/target/linux/ath79/dts/ar9132_buffalo_wzr-hp-g300nh.dtsi
@@ -17,16 +17,37 @@
clock-frequency = <40000000>;
};
- gpio2: gpio-extender {
- compatible = "nxp,74hc153-gpio";
+ /* There is a GPIO driven NXP 74HC153 dual 4-way multiplexer on board
+ * used for buttons that are on top of the the device.
+ */
+ mux: mux-controller {
+ compatible = "gpio-mux";
+ #mux-control-cells = <0>;
+
+ mux-gpios = <&gpio 9 GPIO_ACTIVE_HIGH>, /* s0 */
+ <&gpio 11 GPIO_ACTIVE_HIGH>; /* s1 */
+ };
+
+ gpio2: key-mux1 {
+ compatible = "gpio-cascade";
+ mux-controls = <&mux>;
+
+ gpio-controller;
+ #gpio-cells = <2>;
+
+ // GPIOs used by this node, the mux pin
+ upstream-gpios = <&gpio 12 GPIO_ACTIVE_HIGH>; /* 1y */
+ };
+
+ gpio3: key-mux2 {
+ compatible = "gpio-cascade";
+ mux-controls = <&mux>;
+
gpio-controller;
#gpio-cells = <2>;
- // GPIOs used by this node
- gpio-s0 = <&gpio 9 GPIO_ACTIVE_HIGH>;
- gpio-s1 = <&gpio 11 GPIO_ACTIVE_HIGH>;
- gpio-1y = <&gpio 12 GPIO_ACTIVE_HIGH>;
- gpio-2y = <&gpio 14 GPIO_ACTIVE_HIGH>;
+ // GPIOs used by this node, the mux pin
+ upstream-gpios = <&gpio 14 GPIO_ACTIVE_HIGH>; /* 2y */
};
keys {
@@ -64,21 +85,21 @@
usb {
label = "usb";
linux,code = <BTN_2>;
- gpios = <&gpio2 5 GPIO_ACTIVE_LOW>;
+ gpios = <&gpio3 1 GPIO_ACTIVE_LOW>;
debounce-interval = <60>;
};
router_auto {
label = "router_auto";
linux,code = <BTN_6>;
- gpios = <&gpio2 6 GPIO_ACTIVE_HIGH>;
+ gpios = <&gpio3 2 GPIO_ACTIVE_HIGH>;
debounce-interval = <60>;
};
movie_on {
label = "movie_on";
linux,code = <BTN_4>;
- gpios = <&gpio2 7 GPIO_ACTIVE_HIGH>;
+ gpios = <&gpio3 3 GPIO_ACTIVE_HIGH>;
debounce-interval = <60>;
};
};