Skip to content

Commit

Permalink
kirkwood: apply minor DTS style improvements
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
adschm committed Feb 27, 2020
1 parent 16965a0 commit 845093e
Show file tree
Hide file tree
Showing 4 changed files with 48 additions and 20 deletions.
Expand Up @@ -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";

Expand All @@ -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";

Expand All @@ -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>;
};
};

Expand All @@ -118,6 +128,7 @@

&eth0 {
status = "okay";

ethernet0-port@0 {
phy-handle = <&ethphy0>;
};
Expand Down
Expand Up @@ -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 {
Expand All @@ -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 {
Expand Down Expand Up @@ -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";
Expand All @@ -144,6 +148,7 @@

&nand {
status = "okay";

pinctrl-0 = <&pmx_nand>;
pinctrl-names = "default";

Expand Down Expand Up @@ -197,7 +202,6 @@
label = "unused";
reg = <0x88000 0x178000>;
};

};
};

Expand Down Expand Up @@ -226,6 +230,7 @@
*/
&eth0 {
status = "okay";

ethernet0-port@0 {
speed = <1000>;
duplex = <1>;
Expand All @@ -237,6 +242,7 @@
*/
&eth1 {
status = "okay";

ethernet1-port@0 {
speed = <1000>;
duplex = <1>;
Expand Down
Expand Up @@ -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>;
Expand Down
Expand Up @@ -25,8 +25,9 @@
stdout-path = "serial0:115200n8";
};

gpio_keys {
gpio-keys {
compatible = "gpio-keys";

pinctrl-0 = <&pmx_btn_reset>;
pinctrl-names = "default";

Expand All @@ -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>;
};
Expand Down Expand Up @@ -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";
};
Expand Down

0 comments on commit 845093e

Please sign in to comment.