oxnas: fix gpio-fan on kd20
[openwrt/svn-archive/archive.git] / target / linux / oxnas / files / arch / arm / boot / dts / ox820-kd20.dts
1 /*
2 * Copyright (C) 2014 Daniel Golle <daniel@makrotopia.org>
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License version 2 as
6 * published by the Free Software Foundation.
7 */
8
9 /dts-v1/;
10 #include "ox820.dtsi"
11
12 / {
13 model = "Shuttle KD20";
14
15 chosen {
16 bootargs = "console=ttyS0,115200n8 earlyprintk=serial";
17 };
18
19 pcie-controller@47C00000 {
20 status = "okay";
21 };
22
23 uart@44200000 {
24 status = "okay";
25 };
26
27 sata@45900000 {
28 status = "okay";
29 nr-ports = <2>;
30 };
31
32 nand@41000000 {
33 status = "okay";
34
35 partition@0 {
36 label = "boot";
37 reg = <0x00000000 0x00e00000>;
38 /*read-only;*/
39 };
40
41 partition@e00000 {
42 label = "ubi";
43 reg = <0x00e00000 0x07200000>;
44 };
45 };
46
47 ethernet@40400000 {
48 status = "okay";
49 snps,phy-addr = <1>;
50 phy-mode = "rgmii-id";
51 };
52
53 ehci@40200100 {
54 status = "okay";
55 };
56
57 i2c-gpio {
58 compatible = "i2c-gpio";
59 gpios = <&GPIOB 9 0 &GPIOB 10 0>;
60 i2c-gpio,delay-us = <10>;
61 #address-cells = <1>;
62 #size-cells = <0>;
63 pcf8563: rtc@51 {
64 compatible = "nxp,pcf8563";
65 reg = <0x51>;
66 };
67 };
68
69 gpio-keys-polled {
70 compatible = "gpio-keys-polled";
71 #address-cells = <1>;
72 #size-cells = <0>;
73 poll-interval = <100>;
74
75 power {
76 label = "power";
77 gpios = <&GPIOA 10 1>;
78 linux,code = <116>;
79 };
80 reset {
81 label = "reset";
82 gpios = <&GPIOA 11 1>;
83 linux,code = <0x198>;
84 };
85 eject1 {
86 label = "eject1";
87 gpios = <&GPIOA 5 1>;
88 linux,code = <161>;
89 };
90 eject2 {
91 label = "eject2";
92 gpios = <&GPIOA 6 1>;
93 linux,code = <162>;
94 };
95 };
96
97 gpio-leds {
98 compatible = "gpio-leds";
99 status {
100 label = "kd20:blue:status";
101 gpios = <&GPIOB 16 0>;
102 };
103 status2 {
104 label = "kd20:red:status";
105 gpios = <&GPIOB 17 0>;
106 };
107 hdd1blue {
108 label = "kd20:blue:hdd1";
109 gpios = <&GPIOA 27 0>;
110 linux,default-trigger = "ata1";
111 };
112 hdd1red {
113 label = "kd20:red:hdd1";
114 gpios = <&GPIOB 4 0>;
115 };
116 hdd2blue {
117 label = "kd20:blue:hdd2";
118 gpios = <&GPIOB 6 0>;
119 linux,default-trigger = "ata2";
120 };
121 hdd2red {
122 label = "kd20:red:hdd2";
123 gpios = <&GPIOB 7 0>;
124 };
125 usb {
126 label = "kd20:blue:usb";
127 gpios = <&GPIOB 8 0>;
128 };
129 };
130
131 beeper: beeper {
132 compatible = "gpio-beeper";
133 gpios = <&GPIOB 11 0>;
134 };
135
136 gpio-fan {
137 compatible = "gpio-fan";
138 gpios = <&GPIOA 2 1>;
139 gpio-fan,speed-map = <0 0
140 3000 1>;
141 };
142
143 gpio-poweroff {
144 compatible = "gpio-poweroff";
145 gpios = <&GPIOA 9 0>;
146 };
147 };