Commit f4026ad2 authored by Adrian Schmutzler's avatar Adrian Schmutzler

ath79: DTS file style update and harmonization

This applies several style adjustments that have been requested in
recent reviews to older DTS files. Despite making the code base more
consistent, this will also help to reduce review time when DTSes
are copy/pasted.

Applied changes:
- Rename gpio-keys/gpio-leds to keys/leds
- Remove node labels that are not used
- Use label property for partitions
- Prefix led node labels with "led_"
- Remove redundant includes
- Harmonize new lines after status property
- Several smaller style fixes
Signed-off-by: default avatarAdrian Schmutzler <freifunk@adrianschmutzler.de>
parent 763914ef
......@@ -11,16 +11,16 @@
model = "I-O DATA WN-AG300DGR";
aliases {
led-boot = &router;
led-failsafe = &router;
led-running = &router;
led-upgrade = &router;
led-boot = &led_router;
led-failsafe = &led_router;
led-running = &led_router;
led-upgrade = &led_router;
};
leds {
compatible = "gpio-leds";
router: router {
led_router: router {
label = "wn-ag300dgr:green:router";
gpios = <&gpio 14 GPIO_ACTIVE_LOW>;
default-state = "on";
......@@ -108,9 +108,10 @@
};
&spi {
num-cs = <1>;
status = "okay";
num-cs = <1>;
flash@0 {
compatible = "jedec,spi-nor";
reg = <0>;
......@@ -212,5 +213,6 @@
&wmac {
status = "okay";
qca,no-eeprom;
};
......@@ -11,10 +11,10 @@
compatible = "sitecom,wlr-7100", "qca,ar9344";
aliases {
led-boot = &power;
led-failsafe = &power;
led-running = &power;
led-upgrade = &power;
led-boot = &led_power;
led-failsafe = &led_power;
led-running = &led_power;
led-upgrade = &led_power;
};
keys {
......@@ -41,7 +41,7 @@
gpios = <&gpio 12 GPIO_ACTIVE_LOW>;
};
power: power {
led_power: power {
label = "wlr-7100:amber:power";
gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
default-state = "on";
......@@ -100,9 +100,10 @@
};
&spi {
num-cs = <1>;
status = "okay";
num-cs = <1>;
flash@0 {
compatible = "jedec,spi-nor";
reg = <0>;
......
......@@ -12,10 +12,10 @@
};
aliases {
led-boot = &led_green_status;
led-failsafe = &led_yellow_status;
led-running = &led_green_status;
led-upgrade = &led_yellow_status;
led-boot = &led_status_green;
led-failsafe = &led_status_yellow;
led-running = &led_status_green;
led-upgrade = &led_status_yellow;
};
leds {
......@@ -33,12 +33,12 @@
linux,default-trigger = "phy0tpt";
};
led_green_status: green_status {
led_status_green: status_green {
label = "bluesocket:green:status";
gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
};
led_yellow_status: yellow_status {
led_status_yellow: status_yellow {
label = "bluesocket:yellow:status";
gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
};
......@@ -79,6 +79,7 @@
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
......
......@@ -15,10 +15,10 @@
};
aliases {
led-boot = &power_green;
led-failsafe = &power_red;
led-running = &power_green;
led-upgrade = &power_green;
led-boot = &led_power_green;
led-failsafe = &led_power_red;
led-running = &led_power_green;
led-upgrade = &led_power_green;
label-mac-device = &eth0;
};
......@@ -32,23 +32,23 @@
leds {
compatible = "gpio-leds";
power_green: power_green {
led_power_green: power_green {
label = "ap-105:green:power";
gpios = <&gpio 3 GPIO_ACTIVE_LOW>;
};
power_red: power_red {
led_power_red: power_red {
label = "ap-105:red:power";
gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
panic-indicator;
};
wifi_2g_red: wifi_2g_red {
wifi_2g_red {
label = "ap-105:red:wlan2g";
gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
};
wifi_5g_red: wifi_5g_red {
wifi_5g_red {
label = "ap-105:red:wlan5g";
gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
};
......@@ -151,6 +151,7 @@
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
......
......@@ -11,9 +11,9 @@
model = "Buffalo WZR-HP-AG300H/WZR-600DHP";
aliases {
led-boot = &diag;
led-failsafe = &diag;
led-upgrade = &diag;
led-boot = &led_diag;
led-failsafe = &led_diag;
led-upgrade = &led_diag;
};
chosen {
......@@ -27,19 +27,18 @@
clock-frequency = <40000000>;
};
gpio-leds {
leds {
compatible = "gpio-leds";
diag: diag {
led_diag: diag {
label = "buffalo:red:diag";
gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
};
};
ath9k-leds {
// those leds are indeed attached to the wifi chips
compatible = "gpio-leds";
band2g_a {
label = "buffalo:amber:band2g";
gpios = <&ath9k0 1 GPIO_ACTIVE_LOW>;
......@@ -228,6 +227,7 @@
&spi {
status = "okay";
num-cs = <2>;
cs-gpios = <0>, <0>;
......
......@@ -11,10 +11,10 @@
model = "D-Link DIR825B1";
aliases {
led-boot = &orange_power;
led-failsafe = &orange_power;
led-running = &blue_power;
led-upgrade = &orange_power;
led-boot = &led_power_orange;
led-failsafe = &led_power_orange;
led-running = &led_power_blue;
led-upgrade = &led_power_orange;
};
chosen {
......@@ -30,35 +30,36 @@
leds {
compatible = "gpio-leds";
blue_usb {
usb {
label = "d-link:blue:usb";
gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
trigger-sources = <&usb_ochi_port>, <&usb_echi_port>;
linux,default-trigger = "usbport";
};
orange_power: orange_power {
led_power_orange: power_orange {
label = "d-link:orange:power";
gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
default-state = "on";
};
blue_power: blue_power {
led_power_blue: power_blue {
label = "d-link:blue:power";
gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
};
blue_wps {
wps {
label = "d-link:blue:wps";
gpios = <&gpio 4 GPIO_ACTIVE_LOW>;
};
orange_planet {
planet_orange {
label = "d-link:orange:planet";
gpios = <&gpio 6 GPIO_ACTIVE_LOW>;
};
blue_planet {
planet_blue {
label = "d-link:blue:planet";
gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
};
......@@ -173,6 +174,7 @@
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
......@@ -220,6 +222,7 @@
&eth0 {
status = "okay";
pll-data = <0x11110000 0x00001099 0x00991099>;
fixed-link {
......@@ -230,6 +233,7 @@
&eth1 {
status = "okay";
pll-data = <0x11110000 0x00001099 0x00991099>;
phy-handle = <&phy4>;
......
......@@ -20,10 +20,10 @@
};
aliases {
led-boot = &d2;
led-failsafe = &d2;
led-running = &d2;
led-upgrade = &d2;
led-boot = &led_d2;
led-failsafe = &led_d2;
led-running = &led_d2;
led-upgrade = &led_d2;
};
extosc: ref {
......@@ -36,7 +36,7 @@
leds {
compatible = "gpio-leds";
d2: d2 {
led_d2: d2 {
label = "ja76pf2:green:d2";
gpios = <&gpio 5 GPIO_ACTIVE_LOW>;
};
......@@ -105,6 +105,7 @@
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
......
......@@ -8,10 +8,10 @@
/ {
aliases {
led-boot = &power_orange;
led-failsafe = &power_orange;
led-running = &power_green;
led-upgrade = &power_orange;
led-boot = &led_power_orange;
led-failsafe = &led_power_orange;
led-running = &led_power_green;
led-upgrade = &led_power_orange;
label-mac-device = &eth0;
};
......@@ -37,7 +37,7 @@
};
};
gpio-leds {
leds {
compatible = "gpio-leds";
wps {
......@@ -45,12 +45,12 @@
gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
};
power_green: power_green {
led_power_green: power_green {
label = "netgear:green:power";
gpios = <&gpio 2 GPIO_ACTIVE_LOW>;
};
power_orange: power_orange {
led_power_orange: power_orange {
label = "netgear:orange:power";
gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
default-state = "on";
......@@ -69,6 +69,7 @@
ath9k-leds {
compatible = "gpio-leds";
wlan2g {
label = "netgear:green:wlan2g";
gpios = <&ath9k0 5 GPIO_ACTIVE_LOW>;
......@@ -105,6 +106,7 @@
rtl8366s {
compatible = "realtek,rtl8366s";
gpio-sda = <&gpio 5 GPIO_ACTIVE_HIGH>;
gpio-sck = <&gpio 7 GPIO_ACTIVE_HIGH>;
......@@ -177,6 +179,7 @@
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
......
......@@ -12,10 +12,10 @@
};
aliases {
led-boot = &rf;
led-failsafe = &rf;
led-running = &rf;
led-upgrade = &rf;
led-boot = &led_rf;
led-failsafe = &led_rf;
led-running = &led_rf;
led-upgrade = &led_rf;
};
extosc: ref {
......@@ -28,7 +28,7 @@
leds {
compatible = "gpio-leds";
rf: rf_green {
led_rf: rf_green {
label = "ubnt:green:rf";
gpios = <&gpio 2 GPIO_ACTIVE_HIGH>;
};
......
......@@ -11,9 +11,9 @@
model = "Buffalo WHR-G301N";
aliases {
led-boot = &diag;
led-failsafe = &diag;
led-upgrade = &diag;
led-boot = &led_diag;
led-failsafe = &led_diag;
led-upgrade = &led_diag;
};
keys {
......@@ -50,7 +50,7 @@
};
};
gpio-leds {
leds {
compatible = "gpio-leds";
pinctrl-names = "default";
pinctrl-0 = <&switch_led_pins>;
......@@ -60,7 +60,7 @@
gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
};
diag: diag {
led_diag: diag {
label = "whr-g301n:red:diag";
gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
};
......@@ -109,6 +109,7 @@
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
......
......@@ -15,10 +15,10 @@
};
aliases {
led-boot = &power_amber;
led-failsafe = &power_amber;
led-running = &power_green;
led-upgrade = &power_amber;
led-boot = &led_power_amber;
led-failsafe = &led_power_amber;
led-running = &led_power_green;
led-upgrade = &led_power_amber;
label-mac-device = &eth1;
};
......@@ -54,12 +54,12 @@
pinctrl-names = "default";
pinctrl-0 = <&jtag_disable_pins &switch_led_disable_pins &clks_disable_pins>;
power_green: power_green {
led_power_green: power_green {
label = "netgear:green:power";
gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
};
power_amber: power_amber {
led_power_amber: power_amber {
label = "netgear:amber:power";
gpios = <&gpio 1 GPIO_ACTIVE_LOW>;
default-state = "keep";
......@@ -134,6 +134,7 @@
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
......
......@@ -8,10 +8,10 @@
/ {
aliases {
led-boot = &power;
led-failsafe = &power;
led-running = &power;
led-upgrade = &power;
led-boot = &led_power;
led-failsafe = &led_power;
led-running = &led_power;
led-upgrade = &led_power;
label-mac-device = &eth1;
};
......@@ -33,7 +33,7 @@
pinctrl-names = "default";
pinctrl-0 = <&jtag_disable_pins &switch_led_disable_pins &clks_disable_pins>;
power: power {
led_power: power {
label = "netgear:green:power";
gpios = <&gpio 11 GPIO_ACTIVE_LOW>;
};
......@@ -57,7 +57,7 @@
ath9k-leds {
compatible = "gpio-leds";
wlan: wlan {
wlan {
label = "netgear:green:wlan";
gpios = <&ath9k 1 GPIO_ACTIVE_LOW>;
linux,default-trigger = "phy0tpt";
......@@ -67,6 +67,7 @@
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
......
......@@ -32,7 +32,7 @@
};
};
gpio-leds {
leds {
compatible = "gpio-leds";
pinctrl-names = "default";
pinctrl-0 = <&switch_led_pins>;
......@@ -86,6 +86,7 @@
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
......
......@@ -15,10 +15,10 @@
};
aliases {
led-boot = &power_amber;
led-failsafe = &power_amber;
led-running = &power_green;
led-upgrade = &power_amber;
led-boot = &led_power_amber;
led-failsafe = &led_power_amber;
led-running = &led_power_green;
led-upgrade = &led_power_amber;
label-mac-device = &eth1;
};
......@@ -116,12 +116,12 @@
ath9k-leds {
compatible = "gpio-leds";
power_green: power_green {
led_power_green: power_green {
label = "netgear:green:power";
gpios = <&ath9k 3 GPIO_ACTIVE_LOW>;
};
power_amber: power_amber {
led_power_amber: power_amber {
label = "netgear:amber:power";
gpios = <&ath9k 2 GPIO_ACTIVE_LOW>;
default-state = "keep";
......@@ -137,6 +137,7 @@
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
......
......@@ -12,10 +12,10 @@
};
aliases {
led-boot = &power_amber;
led-failsafe = &power_amber;
led-running = &power_green;
led-upgrade = &power_amber;
led-boot = &led_power_amber;
led-failsafe = &led_power_amber;
led-running = &led_power_green;
led-upgrade = &led_power_amber;
label-mac-device = &eth1;
};
......@@ -117,12 +117,12 @@
ath9k-leds {
compatible = "gpio-leds";
power_green: power_green {
led_power_green: power_green {
label = "netgear:green:power";
gpios = <&ath9k 2 GPIO_ACTIVE_LOW>;
};
power_amber: power_amber {
led_power_amber: power_amber {
label = "netgear:amber:power";
gpios = <&ath9k 1 GPIO_ACTIVE_LOW>;
default-state = "keep";
......
......@@ -32,7 +32,7 @@
};
};
gpio_leds: gpio-leds {
leds: leds {
compatible = "gpio-leds";
led_system: system {
......@@ -49,6 +49,7 @@
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
......
......@@ -15,7 +15,7 @@
};
};
&gpio_leds {
&leds {
led3g {
label = "tp-link:green:3g";
gpios = <&gpio 8 GPIO_ACTIVE_LOW>;
......
......@@ -36,7 +36,7 @@
};
};
gpio-leds {
leds {
compatible = "gpio-leds";
led_system: system {
......@@ -95,6 +95,7 @@
&spi {
status = "okay";
num-cs = <1>;
flash@0 {
......
......@@ -8,17 +8,17 @@
model = "Ubiquiti AirRouter";
aliases {
led-boot = &globe;
led-failsafe = &globe;
led-running = &globe;
led-upgrade = &globe;
led-boot = &led_globe;
led-failsafe = &led_globe;
led-running = &led_globe;
led-upgrade = &led_globe;
label-mac-device = &wifi;
};
airrouter-leds {
compatible = "gpio-leds";
globe: globe {
led_globe: globe {
label = "ubnt:green:globe";
gpios = <&gpio 0 GPIO_ACTIVE_LOW>;
};
......
......@@ -11,10 +11,10 @@
model = "Ubiquiti UniFi AP";
aliases {
led-boot = &dome_green;
led-failsafe = &dome_green;
led-running = &dome_green;
led-upgrade = &dome_green;
led-boot = &led_dome_green;
led-failsafe = &led_dome_green;
led-running = &led_dome_green;
led-