diff options
author | Arnaud Ebalard <arno@natisbad.org> | 2013-11-29 15:27:38 -0500 |
---|---|---|
committer | Jason Cooper <jason@lakedaemon.net> | 2013-12-01 17:09:38 -0500 |
commit | b8f18162402005e8f954641abee2a16248750595 (patch) | |
tree | b1d38e487458414a80448e60df05886cbd719f57 /arch/arm/boot/dts/armada-370-netgear-rn102.dts | |
parent | 261e7735d0ed0f0916b3edc528e206af5196688d (diff) |
ARM: mvebu: NETGEAR ReadyNAS 102 .dts cleanup
The patch does some cleanup work on NETGEAR ReadyNAS 102 .dts
file. Changes are listed below
- Added missing button mpp in pinctrl
- Converted from value to macros for GPIO voltage level
- Converted all numeric input key values to macros
- Added GPIO keys pins to pinctrl
- Made button names more explicit
- Document ethernet PHY (Marvell 88E1318) via a comment
- Made G762 clock node name unique by including g762 in it
- Fixed all node names and labels to use respectively '-' and '_'
- Changed order of included files from general to local
- Removed useless clocks and gpio-keys properties
Signed-off-by: Arnaud Ebalard <arno@natisbad.org>
Signed-off-by: Jason Cooper <jason@lakedaemon.net>
Diffstat (limited to 'arch/arm/boot/dts/armada-370-netgear-rn102.dts')
-rw-r--r-- | arch/arm/boot/dts/armada-370-netgear-rn102.dts | 81 |
1 files changed, 48 insertions, 33 deletions
diff --git a/arch/arm/boot/dts/armada-370-netgear-rn102.dts b/arch/arm/boot/dts/armada-370-netgear-rn102.dts index df1a1e0e9236..41c54b130d5a 100644 --- a/arch/arm/boot/dts/armada-370-netgear-rn102.dts +++ b/arch/arm/boot/dts/armada-370-netgear-rn102.dts | |||
@@ -11,6 +11,8 @@ | |||
11 | 11 | ||
12 | /dts-v1/; | 12 | /dts-v1/; |
13 | 13 | ||
14 | #include <dt-bindings/input/input.h> | ||
15 | #include <dt-bindings/gpio/gpio.h> | ||
14 | #include "armada-370.dtsi" | 16 | #include "armada-370.dtsi" |
15 | 17 | ||
16 | / { | 18 | / { |
@@ -77,6 +79,21 @@ | |||
77 | marvell,function = "gpio"; | 79 | marvell,function = "gpio"; |
78 | }; | 80 | }; |
79 | 81 | ||
82 | backup_button_pin: backup-button-pin { | ||
83 | marvell,pins = "mpp58"; | ||
84 | marvell,function = "gpio"; | ||
85 | }; | ||
86 | |||
87 | power_button_pin: power-button-pin { | ||
88 | marvell,pins = "mpp62"; | ||
89 | marvell,function = "gpio"; | ||
90 | }; | ||
91 | |||
92 | reset_button_pin: reset-button-pin { | ||
93 | marvell,pins = "mpp6"; | ||
94 | marvell,function = "gpio"; | ||
95 | }; | ||
96 | |||
80 | poweroff: poweroff { | 97 | poweroff: poweroff { |
81 | marvell,pins = "mpp8"; | 98 | marvell,pins = "mpp8"; |
82 | marvell,function = "gpio"; | 99 | marvell,function = "gpio"; |
@@ -84,7 +101,7 @@ | |||
84 | }; | 101 | }; |
85 | 102 | ||
86 | mdio { | 103 | mdio { |
87 | phy0: ethernet-phy@0 { | 104 | phy0: ethernet-phy@0 { /* Marvell 88E1318 */ |
88 | reg = <0>; | 105 | reg = <0>; |
89 | }; | 106 | }; |
90 | }; | 107 | }; |
@@ -117,78 +134,76 @@ | |||
117 | }; | 134 | }; |
118 | 135 | ||
119 | clocks { | 136 | clocks { |
120 | #address-cells = <1>; | 137 | g762_clk: g762-oscillator { |
121 | #size-cells = <0>; | ||
122 | |||
123 | g762_clk: fixedclk { | ||
124 | compatible = "fixed-clock"; | 138 | compatible = "fixed-clock"; |
125 | #clock-cells = <0>; | 139 | #clock-cells = <0>; |
126 | clock-frequency = <8192>; | 140 | clock-frequency = <8192>; |
127 | }; | 141 | }; |
128 | }; | 142 | }; |
129 | 143 | ||
130 | gpio_leds { | 144 | gpio-leds { |
131 | compatible = "gpio-leds"; | 145 | compatible = "gpio-leds"; |
132 | pinctrl-0 = < &power_led_pin | 146 | pinctrl-0 = <&power_led_pin |
133 | &sata1_led_pin | 147 | &sata1_led_pin |
134 | &sata2_led_pin | 148 | &sata2_led_pin |
135 | &backup_led_pin >; | 149 | &backup_led_pin>; |
136 | pinctrl-names = "default"; | 150 | pinctrl-names = "default"; |
137 | 151 | ||
138 | blue_power_led { | 152 | blue-power-led { |
139 | label = "rn102:blue:pwr"; | 153 | label = "rn102:blue:pwr"; |
140 | gpios = <&gpio1 25 1>; /* GPIO 57 Active Low */ | 154 | gpios = <&gpio1 25 GPIO_ACTIVE_LOW>; |
141 | default-state = "keep"; | 155 | default-state = "keep"; |
142 | }; | 156 | }; |
143 | 157 | ||
144 | green_sata1_led { | 158 | green-sata1-led { |
145 | label = "rn102:green:sata1"; | 159 | label = "rn102:green:sata1"; |
146 | gpios = <&gpio0 15 1>; /* GPIO 15 Active Low */ | 160 | gpios = <&gpio0 15 GPIO_ACTIVE_LOW>; |
147 | default-state = "on"; | 161 | default-state = "on"; |
148 | }; | 162 | }; |
149 | 163 | ||
150 | green_sata2_led { | 164 | green-sata2-led { |
151 | label = "rn102:green:sata2"; | 165 | label = "rn102:green:sata2"; |
152 | gpios = <&gpio0 14 1>; /* GPIO 14 Active Low */ | 166 | gpios = <&gpio0 14 GPIO_ACTIVE_LOW>; |
153 | default-state = "on"; | 167 | default-state = "on"; |
154 | }; | 168 | }; |
155 | 169 | ||
156 | green_backup_led { | 170 | green-backup-led { |
157 | label = "rn102:green:backup"; | 171 | label = "rn102:green:backup"; |
158 | gpios = <&gpio1 24 1>; /* GPIO 56 Active Low */ | 172 | gpios = <&gpio1 24 GPIO_ACTIVE_LOW>; |
159 | default-state = "on"; | 173 | default-state = "on"; |
160 | }; | 174 | }; |
161 | }; | 175 | }; |
162 | 176 | ||
163 | gpio_keys { | 177 | gpio-keys { |
164 | compatible = "gpio-keys"; | 178 | compatible = "gpio-keys"; |
165 | #address-cells = <1>; | 179 | pinctrl-0 = <&power_button_pin |
166 | #size-cells = <0>; | 180 | &reset_button_pin |
181 | &backup_button_pin>; | ||
182 | pinctrl-names = "default"; | ||
167 | 183 | ||
168 | button@1 { | 184 | power-button { |
169 | label = "Power Button"; | 185 | label = "Power Button"; |
170 | linux,code = <116>; /* KEY_POWER */ | 186 | linux,code = <KEY_POWER>; |
171 | gpios = <&gpio1 30 0>; | 187 | gpios = <&gpio1 30 GPIO_ACTIVE_HIGH>; |
172 | }; | 188 | }; |
173 | 189 | ||
174 | button@2 { | 190 | reset-button { |
175 | label = "Reset Button"; | 191 | label = "Reset Button"; |
176 | linux,code = <0x198>; /* KEY_RESTART */ | 192 | linux,code = <KEY_RESTART>; |
177 | gpios = <&gpio0 6 1>; | 193 | gpios = <&gpio0 6 GPIO_ACTIVE_LOW>; |
178 | }; | 194 | }; |
179 | 195 | ||
180 | button@3 { | 196 | backup-button { |
181 | label = "Backup Button"; | 197 | label = "Backup Button"; |
182 | linux,code = <133>; /* KEY_COPY */ | 198 | linux,code = <KEY_COPY>; |
183 | gpios = <&gpio1 26 1>; | 199 | gpios = <&gpio1 26 GPIO_ACTIVE_LOW>; |
184 | }; | 200 | }; |
185 | }; | 201 | }; |
186 | 202 | ||
187 | gpio_poweroff { | 203 | gpio-poweroff { |
188 | compatible = "gpio-poweroff"; | 204 | compatible = "gpio-poweroff"; |
189 | pinctrl-0 = <&poweroff>; | 205 | pinctrl-0 = <&poweroff>; |
190 | pinctrl-names = "default"; | 206 | pinctrl-names = "default"; |
191 | gpios = <&gpio0 8 1>; | 207 | gpios = <&gpio0 8 GPIO_ACTIVE_LOW>; |
192 | }; | 208 | }; |
193 | |||
194 | }; | 209 | }; |