Loading...
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * Device Tree for the ST-Ericsson Nomadik S8815 board
4 * Produced by Calao Systems
5 */
6
7/dts-v1/;
8#include <dt-bindings/interrupt-controller/irq.h>
9#include "ste-nomadik-stn8815.dtsi"
10
11/ {
12 model = "Calao Systems USB-S8815";
13 compatible = "calaosystems,usb-s8815";
14
15 chosen {
16 bootargs = "root=/dev/ram0 console=ttyAMA1,115200n8 earlyprintk";
17 };
18
19 aliases {
20 serial0 = &uart0;
21 serial1 = &uart1;
22 };
23
24 gpio3: gpio@101e7000 {
25 /* This hog will bias the MMC/SD card detect line */
26 mmcsd-gpio {
27 gpio-hog;
28 gpios = <16 0x0>;
29 output-low;
30 line-name = "card detect bias";
31 };
32 };
33
34 src@101e0000 {
35 /* These chrystal drivers are not used on this board */
36 disable-sxtalo;
37 disable-mxtalo;
38 };
39
40 pinctrl {
41 /* Hog CD pins */
42 pinctrl-names = "default";
43 pinctrl-0 = <&cd_default_mode>;
44
45 uart0 {
46 /* Only use RX/TX pins */
47 uart0_s8815_mode: uart0_mux {
48 u0_default_mux {
49 function = "u0";
50 groups = "u0txrx_a_1";
51 };
52 };
53 };
54 mmcsd-cd {
55 cd_default_mode: cd_default {
56 cd_default_cfg1 {
57 /* CD input GPIO */
58 pins = "GPIO111_H21";
59 ste,input = <0>;
60 };
61 cd_default_cfg2 {
62 /* CD GPIO biasing */
63 pins = "GPIO112_J21";
64 ste,output = <0>;
65 };
66 };
67 };
68 gpioi2c {
69 gpioi2c_default_mode: gpioi2c_default {
70 gpioi2c_default_cfg {
71 pins = "GPIO73_C21", "GPIO74_C20";
72 ste,input = <0>;
73 };
74 };
75 };
76 user-led {
77 user_led_default_mode: user_led_default {
78 user_led_default_cfg {
79 pins = "GPIO2_C5";
80 ste,output = <1>;
81 };
82 };
83 };
84 user-button {
85 user_button_default_mode: user_button_default {
86 user_button_default_cfg {
87 pins = "GPIO3_A4";
88 ste,input = <0>;
89 };
90 };
91 };
92 };
93
94 /* Ethernet */
95 external-bus@34000000 {
96 compatible = "simple-bus";
97 reg = <0x34000000 0x1000000>;
98 #address-cells = <1>;
99 #size-cells = <1>;
100 ranges = <0 0x34000000 0x1000000>;
101 ethernet@300 {
102 compatible = "smsc,lan91c111";
103 reg = <0x300 0x0fd00>;
104 interrupt-parent = <&gpio3>;
105 interrupts = <8 IRQ_TYPE_EDGE_RISING>;
106 };
107 };
108
109 i2c1 {
110 lis3lv02dl@1d {
111 /* Accelerometer */
112 compatible = "st,lis3lv02dl-accel";
113 reg = <0x1d>;
114 };
115 };
116
117 /* GPIO I2C connected to the USB portions of the STw4811 only */
118 gpio-i2c {
119 compatible = "i2c-gpio";
120 gpios = <&gpio2 10 0>, /* sda */
121 <&gpio2 9 0>; /* scl */
122 #address-cells = <1>;
123 #size-cells = <0>;
124 pinctrl-names = "default";
125 pinctrl-0 = <&gpioi2c_default_mode>;
126
127 stw4811@2d {
128 compatible = "st,stw4811-usb";
129 reg = <0x2d>;
130 };
131 };
132
133
134 amba {
135 /* Activate RXTX on UART 0 */
136 uart0: uart@101fd000 {
137 pinctrl-names = "default";
138 pinctrl-0 = <&uart0_s8815_mode>;
139 status = "okay";
140 };
141 /* Configure card detect for the uSD slot */
142 mmc@101f6000 {
143 cd-gpios = <&gpio3 15 GPIO_ACTIVE_LOW>;
144 };
145 };
146
147 /* The user LED on the board is set up to be used for heartbeat */
148 leds {
149 compatible = "gpio-leds";
150 user-led {
151 label = "user_led";
152 gpios = <&gpio0 2 0x1>;
153 default-state = "off";
154 linux,default-trigger = "heartbeat";
155 pinctrl-names = "default";
156 pinctrl-0 = <&user_led_default_mode>;
157 };
158 };
159
160 /* User key mapped in as "escape" */
161 gpio-keys {
162 compatible = "gpio-keys";
163 user-button {
164 label = "user_button";
165 gpios = <&gpio0 3 0x1>;
166 linux,code = <1>; /* KEY_ESC */
167 wakeup-source;
168 pinctrl-names = "default";
169 pinctrl-0 = <&user_button_default_mode>;
170 };
171 };
172};
1/*
2 * Device Tree for the ST-Ericsson Nomadik S8815 board
3 * Produced by Calao Systems
4 */
5
6/dts-v1/;
7/include/ "ste-nomadik-stn8815.dtsi"
8
9/ {
10 model = "Calao Systems USB-S8815";
11 compatible = "calaosystems,usb-s8815";
12
13 chosen {
14 bootargs = "root=/dev/ram0 console=ttyAMA1,115200n8 earlyprintk";
15 };
16
17 /* This is where the interrupt is routed on the S8815 board */
18 external-bus@34000000 {
19 ethernet@300 {
20 interrupt-parent = <&gpio3>;
21 interrupts = <8 0x1>;
22 };
23 };
24
25 src@101e0000 {
26 /* These chrystal drivers are not used on this board */
27 disable-sxtalo;
28 disable-mxtalo;
29 };
30
31 pinctrl {
32 /* Hog CD pins */
33 pinctrl-names = "default";
34 pinctrl-0 = <&cd_default_mode>;
35
36 mmcsd-cd {
37 cd_default_mode: cd_default {
38 cd_default_cfg1 {
39 /* CD input GPIO */
40 ste,pins = "GPIO111_H21";
41 ste,input = <0>;
42 };
43 cd_default_cfg2 {
44 /* CD GPIO biasing */
45 ste,pins = "GPIO112_J21";
46 ste,output = <0>;
47 };
48 };
49 };
50 user-led {
51 user_led_default_mode: user_led_default {
52 user_led_default_cfg {
53 ste,pins = "GPIO2_C5";
54 ste,output = <1>;
55 };
56 };
57 };
58 user-button {
59 user_button_default_mode: user_button_default {
60 user_button_default_cfg {
61 ste,pins = "GPIO3_A4";
62 ste,input = <0>;
63 };
64 };
65 };
66 };
67
68 /* Custom board node with GPIO pins to active etc */
69 usb-s8815 {
70 /* This will bias the MMC/SD card detect line */
71 mmcsd-gpio {
72 gpios = <&gpio3 16 0x1>;
73 };
74 };
75
76 /* The user LED on the board is set up to be used for heartbeat */
77 leds {
78 compatible = "gpio-leds";
79 user-led {
80 label = "user_led";
81 gpios = <&gpio0 2 0x1>;
82 default-state = "off";
83 linux,default-trigger = "heartbeat";
84 pinctrl-names = "default";
85 pinctrl-0 = <&user_led_default_mode>;
86 };
87 };
88
89 /* User key mapped in as "escape" */
90 gpio-keys {
91 compatible = "gpio-keys";
92 user-button {
93 label = "user_button";
94 gpios = <&gpio0 3 0x1>;
95 linux,code = <1>; /* KEY_ESC */
96 gpio-key,wakeup;
97 pinctrl-names = "default";
98 pinctrl-0 = <&user_button_default_mode>;
99 };
100 };
101};