Linux Audio

Check our new training course

Embedded Linux training

Mar 31-Apr 8, 2025
Register
Loading...
v4.17
  1// SPDX-License-Identifier: GPL-2.0
  2/*
  3 * Device Tree common file for LaCie 2Big and 5Big Network v2
  4 *
  5 * Copyright (C) 2014
  6 *
  7 * Andrew Lunn <andrew@lunn.ch>
  8 *
  9 * Based on netxbig_v2-setup.c,
 10 * Copyright (C) 2010 Simon Guinot <sguinot@lacie.com>
 11 *
 
 
 
 12*/
 13
 14#include <dt-bindings/leds/leds-netxbig.h>
 15#include "kirkwood.dtsi"
 16#include "kirkwood-6281.dtsi"
 17
 18/ {
 19	chosen {
 20		bootargs = "console=ttyS0,115200n8";
 21		stdout-path = &uart0;
 22	};
 23
 24	ocp@f1000000 {
 25		serial@12000 {
 26			status = "okay";
 27		};
 28
 29		spi@10600 {
 30			status = "okay";
 31
 32			flash@0 {
 33				#address-cells = <1>;
 34				#size-cells = <1>;
 35				compatible = "mxicy,mx25l4005a", "jedec,spi-nor";
 36				reg = <0>;
 37				spi-max-frequency = <20000000>;
 38				mode = <0>;
 39
 40				partition@0 {
 41					reg = <0x0 0x80000>;
 42					label = "u-boot";
 43				};
 44			};
 45		};
 46
 47		sata@80000 {
 48			status = "okay";
 49			nr-ports = <2>;
 50		};
 51
 52	};
 53
 54	gpio-keys {
 55		compatible = "gpio-keys";
 56		#address-cells = <1>;
 57		#size-cells = <0>;
 58
 59		/*
 60		 * esc and power represent a three position rocker
 61		 * switch. Thus the conventional KEY_POWER does not fit
 62		 */
 63		exc {
 64			label = "Back power switch (on|auto)";
 65			linux,code = <KEY_ESC>;
 66			linux,input-type = <5>;
 67			gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
 68		};
 69		power {
 70			label = "Back power switch (auto|off)";
 71			linux,code = <KEY_1>;
 72			linux,input-type = <5>;
 73			gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
 74		};
 75		option {
 76			label = "Function button";
 77			linux,code = <KEY_OPTION>;
 78			gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
 79		};
 80
 81	};
 82
 83	gpio-poweroff {
 84		compatible = "gpio-poweroff";
 85		gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
 86	};
 87
 88	regulators: regulators {
 89		status = "okay";
 90		compatible = "simple-bus";
 91		#address-cells = <1>;
 92		#size-cells = <0>;
 93		pinctrl-names = "default";
 94
 95		regulator@1 {
 96			compatible = "regulator-fixed";
 97			reg = <1>;
 98			regulator-name = "hdd0power";
 99			regulator-min-microvolt = <5000000>;
100			regulator-max-microvolt = <5000000>;
101			enable-active-high;
102			regulator-always-on;
103			regulator-boot-on;
104			gpio = <&gpio0 16 GPIO_ACTIVE_HIGH>;
105		};
106	};
107
108	netxbig_gpio_ext: netxbig-gpio-ext {
109		compatible = "lacie,netxbig-gpio-ext";
110
111		addr-gpios = <&gpio1 15 GPIO_ACTIVE_HIGH
112			      &gpio1 16 GPIO_ACTIVE_HIGH
113			      &gpio1 17 GPIO_ACTIVE_HIGH>;
114		data-gpios = <&gpio1 12 GPIO_ACTIVE_HIGH
115			      &gpio1 13 GPIO_ACTIVE_HIGH
116			      &gpio1 14 GPIO_ACTIVE_HIGH>;
117		enable-gpio = <&gpio0 29 GPIO_ACTIVE_HIGH>;
118	};
119
120	netxbig-leds {
121		compatible = "lacie,netxbig-leds";
122
123		gpio-ext = <&netxbig_gpio_ext>;
124
125		timers = <NETXBIG_LED_TIMER1 500 500
126			  NETXBIG_LED_TIMER2 500 1000>;
127
128		blue-power {
129			label = "netxbig:blue:power";
130			mode-addr = <0>;
131			mode-val = <NETXBIG_LED_OFF 0
132				    NETXBIG_LED_ON 1
133				    NETXBIG_LED_TIMER1 3
134				    NETXBIG_LED_TIMER2 7>;
135			bright-addr = <1>;
136			max-brightness = <7>;
137		};
138		red-power {
139			label = "netxbig:red:power";
140			mode-addr = <0>;
141			mode-val = <NETXBIG_LED_OFF 0
142				    NETXBIG_LED_ON 2
143				    NETXBIG_LED_TIMER1 4>;
144			bright-addr = <1>;
145			max-brightness = <7>;
146		};
147		blue-sata0 {
148			label = "netxbig:blue:sata0";
149			mode-addr = <3>;
150			mode-val = <NETXBIG_LED_OFF 0
151				    NETXBIG_LED_ON 7
152				    NETXBIG_LED_SATA 1
153				    NETXBIG_LED_TIMER1 3>;
154			bright-addr = <2>;
155			max-brightness = <7>;
156		};
157		red-sata0 {
158			label = "netxbig:red:sata0";
159			mode-addr = <3>;
160			mode-val = <NETXBIG_LED_OFF 0
161				    NETXBIG_LED_ON 2
162				    NETXBIG_LED_TIMER1 4>;
163			bright-addr = <2>;
164			max-brightness = <7>;
165		};
166		blue-sata1 {
167			label = "netxbig:blue:sata1";
168			mode-addr = <4>;
169			mode-val = <NETXBIG_LED_OFF 0
170				    NETXBIG_LED_ON 7
171				    NETXBIG_LED_SATA 1
172				    NETXBIG_LED_TIMER1 3>;
173			bright-addr = <2>;
174			max-brightness = <7>;
175		};
176		red-sata1 {
177			label = "netxbig:red:sata1";
178			mode-addr = <4>;
179			mode-val = <NETXBIG_LED_OFF 0
180				    NETXBIG_LED_ON 2
181				    NETXBIG_LED_TIMER1 4>;
182			bright-addr = <2>;
183			max-brightness = <7>;
184		};
185	};
186};
187
188&mdio {
189	status = "okay";
190
191	ethphy0: ethernet-phy@0 {
192		reg = <8>;
193	};
194
195	ethphy1: ethernet-phy@1 {
196		reg = <0>;
197	};
198};
199
200&eth0 {
201	status = "okay";
202	ethernet0-port@0 {
203		phy-handle = <&ethphy0>;
204	};
205};
206
207&pinctrl {
208	pinctrl-names = "default";
209
210	pmx_button_function: pmx-button-function {
211		marvell,pins = "mpp34";
212		marvell,function = "gpio";
213	};
214	pmx_button_power_off: pmx-button-power-off {
215		marvell,pins = "mpp15";
216		marvell,function = "gpio";
217	};
218	pmx_button_power_on: pmx-button-power-on {
219		marvell,pins = "mpp13";
220		marvell,function = "gpio";
221	};
222};
223
224&i2c0 {
225	status = "okay";
226
227	eeprom@50 {
228		compatible = "atmel,24c04";
229		pagesize = <16>;
230		reg = <0x50>;
231	};
232};
v4.10.11
 
  1/*
  2 * Device Tree common file for LaCie 2Big and 5Big Network v2
  3 *
  4 * Copyright (C) 2014
  5 *
  6 * Andrew Lunn <andrew@lunn.ch>
  7 *
  8 * Based on netxbig_v2-setup.c,
  9 * Copyright (C) 2010 Simon Guinot <sguinot@lacie.com>
 10 *
 11 * This file is licensed under the terms of the GNU General Public
 12 * License version 2.  This program is licensed "as is" without any
 13 * warranty of any kind, whether express or implied.
 14*/
 15
 16#include <dt-bindings/leds/leds-netxbig.h>
 17#include "kirkwood.dtsi"
 18#include "kirkwood-6281.dtsi"
 19
 20/ {
 21	chosen {
 22		bootargs = "console=ttyS0,115200n8";
 23		stdout-path = &uart0;
 24	};
 25
 26	ocp@f1000000 {
 27		serial@12000 {
 28			status = "okay";
 29		};
 30
 31		spi@10600 {
 32			status = "okay";
 33
 34			flash@0 {
 35				#address-cells = <1>;
 36				#size-cells = <1>;
 37				compatible = "mxicy,mx25l4005a", "jedec,spi-nor";
 38				reg = <0>;
 39				spi-max-frequency = <20000000>;
 40				mode = <0>;
 41
 42				partition@0 {
 43					reg = <0x0 0x80000>;
 44					label = "u-boot";
 45				};
 46			};
 47		};
 48
 49		sata@80000 {
 50			status = "okay";
 51			nr-ports = <2>;
 52		};
 53
 54	};
 55
 56	gpio-keys {
 57		compatible = "gpio-keys";
 58		#address-cells = <1>;
 59		#size-cells = <0>;
 60
 61		/*
 62		 * esc and power represent a three position rocker
 63		 * switch. Thus the conventional KEY_POWER does not fit
 64		 */
 65		exc {
 66			label = "Back power switch (on|auto)";
 67			linux,code = <KEY_ESC>;
 68			linux,input-type = <5>;
 69			gpios = <&gpio0 13 GPIO_ACTIVE_LOW>;
 70		};
 71		power {
 72			label = "Back power switch (auto|off)";
 73			linux,code = <KEY_1>;
 74			linux,input-type = <5>;
 75			gpios = <&gpio0 15 GPIO_ACTIVE_LOW>;
 76		};
 77		option {
 78			label = "Function button";
 79			linux,code = <KEY_OPTION>;
 80			gpios = <&gpio1 2 GPIO_ACTIVE_LOW>;
 81		};
 82
 83	};
 84
 85	gpio-poweroff {
 86		compatible = "gpio-poweroff";
 87		gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
 88	};
 89
 90	regulators: regulators {
 91		status = "okay";
 92		compatible = "simple-bus";
 93		#address-cells = <1>;
 94		#size-cells = <0>;
 95		pinctrl-names = "default";
 96
 97		regulator@1 {
 98			compatible = "regulator-fixed";
 99			reg = <1>;
100			regulator-name = "hdd0power";
101			regulator-min-microvolt = <5000000>;
102			regulator-max-microvolt = <5000000>;
103			enable-active-high;
104			regulator-always-on;
105			regulator-boot-on;
106			gpio = <&gpio0 16 GPIO_ACTIVE_HIGH>;
107		};
108	};
109
110	netxbig_gpio_ext: netxbig-gpio-ext {
111		compatible = "lacie,netxbig-gpio-ext";
112
113		addr-gpios = <&gpio1 15 GPIO_ACTIVE_HIGH
114			      &gpio1 16 GPIO_ACTIVE_HIGH
115			      &gpio1 17 GPIO_ACTIVE_HIGH>;
116		data-gpios = <&gpio1 12 GPIO_ACTIVE_HIGH
117			      &gpio1 13 GPIO_ACTIVE_HIGH
118			      &gpio1 14 GPIO_ACTIVE_HIGH>;
119		enable-gpio = <&gpio0 29 GPIO_ACTIVE_HIGH>;
120	};
121
122	netxbig-leds {
123		compatible = "lacie,netxbig-leds";
124
125		gpio-ext = <&netxbig_gpio_ext>;
126
127		timers = <NETXBIG_LED_TIMER1 500 500
128			  NETXBIG_LED_TIMER2 500 1000>;
129
130		blue-power {
131			label = "netxbig:blue:power";
132			mode-addr = <0>;
133			mode-val = <NETXBIG_LED_OFF 0
134				    NETXBIG_LED_ON 1
135				    NETXBIG_LED_TIMER1 3
136				    NETXBIG_LED_TIMER2 7>;
137			bright-addr = <1>;
138			max-brightness = <7>;
139		};
140		red-power {
141			label = "netxbig:red:power";
142			mode-addr = <0>;
143			mode-val = <NETXBIG_LED_OFF 0
144				    NETXBIG_LED_ON 2
145				    NETXBIG_LED_TIMER1 4>;
146			bright-addr = <1>;
147			max-brightness = <7>;
148		};
149		blue-sata0 {
150			label = "netxbig:blue:sata0";
151			mode-addr = <3>;
152			mode-val = <NETXBIG_LED_OFF 0
153				    NETXBIG_LED_ON 7
154				    NETXBIG_LED_SATA 1
155				    NETXBIG_LED_TIMER1 3>;
156			bright-addr = <2>;
157			max-brightness = <7>;
158		};
159		red-sata0 {
160			label = "netxbig:red:sata0";
161			mode-addr = <3>;
162			mode-val = <NETXBIG_LED_OFF 0
163				    NETXBIG_LED_ON 2
164				    NETXBIG_LED_TIMER1 4>;
165			bright-addr = <2>;
166			max-brightness = <7>;
167		};
168		blue-sata1 {
169			label = "netxbig:blue:sata1";
170			mode-addr = <4>;
171			mode-val = <NETXBIG_LED_OFF 0
172				    NETXBIG_LED_ON 7
173				    NETXBIG_LED_SATA 1
174				    NETXBIG_LED_TIMER1 3>;
175			bright-addr = <2>;
176			max-brightness = <7>;
177		};
178		red-sata1 {
179			label = "netxbig:red:sata1";
180			mode-addr = <4>;
181			mode-val = <NETXBIG_LED_OFF 0
182				    NETXBIG_LED_ON 2
183				    NETXBIG_LED_TIMER1 4>;
184			bright-addr = <2>;
185			max-brightness = <7>;
186		};
187	};
188};
189
190&mdio {
191	status = "okay";
192
193	ethphy0: ethernet-phy@0 {
194		reg = <8>;
195	};
196
197	ethphy1: ethernet-phy@1 {
198		reg = <0>;
199	};
200};
201
202&eth0 {
203	status = "okay";
204	ethernet0-port@0 {
205		phy-handle = <&ethphy0>;
206	};
207};
208
209&pinctrl {
210	pinctrl-names = "default";
211
212	pmx_button_function: pmx-button-function {
213		marvell,pins = "mpp34";
214		marvell,function = "gpio";
215	};
216	pmx_button_power_off: pmx-button-power-off {
217		marvell,pins = "mpp15";
218		marvell,function = "gpio";
219	};
220	pmx_button_power_on: pmx-button-power-on {
221		marvell,pins = "mpp13";
222		marvell,function = "gpio";
223	};
224};
225
226&i2c0 {
227	status = "okay";
228
229	eeprom@50 {
230		compatible = "atmel,24c04";
231		pagesize = <16>;
232		reg = <0x50>;
233	};
234};