kirkwood: apply minor DTS style improvements

This applies some minor DTS style improvements to the files kept
in OpenWrt at the moment:

- harmonize/improve LED/pinmux node names
- harmonize empty lines between nodes
- change "ok" to "okay"
- some other minor formatting adjustments

Since changes are only cosmetical, they are only applied to the
"newer" DTS files for kernel 4.19.

Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
This commit is contained in:
Adrian Schmutzler 2020-02-27 13:05:51 +01:00
parent 16965a0f3f
commit 845093e8a0
4 changed files with 48 additions and 20 deletions

View File

@ -30,29 +30,33 @@
marvell,pins = "mpp29";
marvell,function = "gpio";
};
pmx_led_white: pmx-led-white {
marvell,pins = "mpp40";
marvell,function = "gpio";
};
pmx_led_green: pmx-led_green {
marvell,pins = "mpp46";
marvell,function = "gpio";
};
pmx_led_orange: pmx-led-orange {
marvell,pins = "mpp47";
marvell,function = "gpio";
};
};
serial@12000 {
status = "ok";
status = "okay";
};
sata@80000 {
status = "okay";
nr-ports = <2>;
};
};
gpio-leds {
compatible = "gpio-leds";
@ -61,20 +65,25 @@
gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
default-state = "on";
};
led_fault: fault {
label = "status:orange:fault";
gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
misc {
label = "status:white:misc";
gpios = <&gpio1 8 GPIO_ACTIVE_LOW>;
linux,default-trigger = "disk-activity";
};
};
regulators {
compatible = "simple-bus";
#address-cells = <1>;
#size-cells = <0>;
pinctrl-0 = <&pmx_usb_power_enable>;
pinctrl-names = "default";
@ -93,18 +102,19 @@
};
&nand {
chip-delay = <40>;
status = "okay";
chip-delay = <40>;
partition@0 {
label = "u-boot";
reg = <0x0000000 0x100000>;
reg = <0x0000000 0x0100000>;
read-only;
};
partition@100000 {
label = "ubi";
reg = <0x100000 0x0ff00000>;
reg = <0x0100000 0xff00000>;
};
};
@ -118,6 +128,7 @@
&eth0 {
status = "okay";
ethernet0-port@0 {
phy-handle = <&ethphy0>;
};

View File

@ -35,9 +35,10 @@
stdout-path = "serial0:115200n8";
};
gpio_keys {
gpio-keys {
compatible = "gpio-keys";
pinctrl-0 = < &pmx_btn_wps &pmx_btn_reset >;
pinctrl-0 = <&pmx_btn_wps &pmx_btn_reset>;
pinctrl-names = "default";
wps {
@ -55,7 +56,8 @@
gpio-leds {
compatible = "gpio-leds";
pinctrl-0 = < &pmx_led_green_power >;
pinctrl-0 = <&pmx_led_green_power>;
pinctrl-names = "default";
led_power: power {
@ -132,10 +134,12 @@
marvell,pins = "mpp7";
marvell,function = "gpo";
};
pmx_btn_wps: pmx-btn-wps {
marvell,pins = "mpp47";
marvell,function = "gpio";
};
pmx_btn_reset: pmx-btn-reset {
marvell,pins = "mpp48";
marvell,function = "gpio";
@ -144,6 +148,7 @@
&nand {
status = "okay";
pinctrl-0 = <&pmx_nand>;
pinctrl-names = "default";
@ -197,7 +202,6 @@
label = "unused";
reg = <0x88000 0x178000>;
};
};
};
@ -226,6 +230,7 @@
*/
&eth0 {
status = "okay";
ethernet0-port@0 {
speed = <1000>;
duplex = <1>;
@ -237,6 +242,7 @@
*/
&eth1 {
status = "okay";
ethernet1-port@0 {
speed = <1000>;
duplex = <1>;

View File

@ -92,38 +92,47 @@
gpios = <&gpio0 28 GPIO_ACTIVE_HIGH>;
default-state = "on";
};
led_red_sys: red-sys {
label = "nsa310:red:sys";
gpios = <&gpio0 29 GPIO_ACTIVE_HIGH>;
};
green-hdd {
label = "nsa310:green:hdd";
gpios = <&gpio1 9 GPIO_ACTIVE_HIGH>;
};
red-hdd {
label = "nsa310:red:hdd";
gpios = <&gpio1 10 GPIO_ACTIVE_HIGH>;
};
green-esata {
label = "nsa310:green:esata";
gpios = <&gpio0 12 GPIO_ACTIVE_HIGH>;
};
red-esata {
label = "nsa310:red:esata";
gpios = <&gpio0 13 GPIO_ACTIVE_HIGH>;
};
green-usb {
label = "nsa310:green:usb";
gpios = <&gpio0 15 GPIO_ACTIVE_HIGH>;
};
red-usb {
label = "nsa310:red:usb";
gpios = <&gpio0 16 GPIO_ACTIVE_HIGH>;
};
green-copy {
label = "nsa310:green:copy";
gpios = <&gpio1 7 GPIO_ACTIVE_HIGH>;
};
red-copy {
label = "nsa310:red:copy";
gpios = <&gpio1 8 GPIO_ACTIVE_HIGH>;

View File

@ -25,8 +25,9 @@
stdout-path = "serial0:115200n8";
};
gpio_keys {
gpio-keys {
compatible = "gpio-keys";
pinctrl-0 = <&pmx_btn_reset>;
pinctrl-names = "default";
@ -39,26 +40,27 @@
gpio-leds {
compatible = "gpio-leds";
pinctrl-0 = < &pmx_led_health_r &pmx_led_health_g >;
pinctrl-0 = <&pmx_led_health_red &pmx_led_health_green>;
pinctrl-names = "default";
led_health_green: health_green {
led_health_green: health-green {
label = "on100:green:health";
gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
default-state = "on";
};
led_health_red: health_red {
led_health_red: health-red {
label = "on100:red:health";
gpios = <&gpio1 13 GPIO_ACTIVE_LOW>;
};
health2_green {
health2-green {
label = "on100:green:health2";
gpios = <&gpio1 14 GPIO_ACTIVE_LOW>;
};
health2_red {
health2-red {
label = "on100:red:health2";
gpios = <&gpio1 15 GPIO_ACTIVE_LOW>;
};
@ -128,27 +130,27 @@
};
&pinctrl {
pmx_led_health_r: pmx-led-health-r {
pmx_led_health_red: pmx-led-health-red {
marvell,pins = "mpp45";
marvell,function = "gpio";
};
pmx_led_health_g: pmx-led-health-g {
pmx_led_health_green: pmx-led-health-green {
marvell,pins = "mpp44";
marvell,function = "gpio";
};
pmx_led_health2_r: pmx-led-health2-r {
pmx_led_health2_red: pmx-led-health2-red {
marvell,pins = "mpp47";
marvell,function = "gpio";
};
pmx_led_health2_g: pmx-led-health2-g {
pmx_led_health2_green: pmx-led-health2-green {
marvell,pins = "mpp46";
marvell,function = "gpio";
};
pmx_btn_reset: pmx-led-reset {
pmx_btn_reset: pmx-btn-reset {
marvell,pins = "mpp31";
marvell,function = "gpio";
};