rk3128-box.dts: only change ddr freq when suspend.
[firefly-linux-kernel-4.4.55.git] / arch / arm / boot / dts / rk3128-box.dts
1 #include "rk312x-sdk.dtsi"
2 #include "lcd-box.dtsi"
3
4 / {
5          compatible = "rockchip,rk3128";
6         wireless-wlan {
7                 compatible = "wlan-platdata";
8
9                 wifi_chip_type = "esp8089";
10                 sdio_vref = <0>; //1800mv or 3300mv
11
12                 //power_ctrl_by_pmu;
13                 //power_pmu_regulator = "act_ldo3";
14                 //power_pmu_enable_level = <1>; //1->HIGH, 0->LOW
15
16                 //vref_ctrl_enable;
17                 //vref_ctrl_gpio = <&gpio0 GPIO_A2 GPIO_ACTIVE_HIGH>;
18                 //vref_pmu_regulator = "act_ldo3";
19                 //vref_pmu_enable_level = <1>; //1->HIGH, 0->LOW
20
21                 WIFI,poweren_gpio = <&gpio0 GPIO_D6 GPIO_ACTIVE_HIGH>;
22                 WIFI,host_wake_irq = <&gpio0 GPIO_A2 GPIO_ACTIVE_HIGH>;
23                 //WIFI,reset_gpio = <&gpio0 GPIO_A2 GPIO_ACTIVE_LOW>;
24
25                 status = "okay";
26         };
27
28                 wireless-bluetooth {
29                 compatible = "bluetooth-platdata";
30
31                 //wifi-bt-power-toggle;
32
33                 uart_rts_gpios = <&gpio1 GPIO_B3 GPIO_ACTIVE_LOW>;
34                 pinctrl-names = "default","rts_gpio";
35                 pinctrl-0 = <&uart1_rts>;
36                 pinctrl-1 = <&uart1_rts_gpio>;
37
38                 //BT,power_gpio = <&gpio4 GPIO_D3 GPIO_ACTIVE_HIGH>;
39                 BT,reset_gpio = <&gpio3 GPIO_C5 GPIO_ACTIVE_HIGH>;
40                 BT,wake_gpio = <&gpio1 GPIO_B4 GPIO_ACTIVE_HIGH>;
41                 BT,wake_host_irq = <&gpio0 GPIO_C6 GPIO_ACTIVE_LOW>;
42
43         status = "okay";
44     };
45         usb_control {
46                 compatible = "rockchip,rk3126-usb-control";
47                 host_drv_gpio = <&gpio3 GPIO_C4 GPIO_ACTIVE_LOW>;
48                 otg_drv_gpio = <&gpio3 GPIO_C1 GPIO_ACTIVE_LOW>;
49
50                 rockchip,remote_wakeup;
51                 rockchip,usb_irq_wakeup;
52         };
53 };
54
55
56 &clk_core_dvfs_table {
57         operating-points = <
58                 /* KHz    uV */
59                 /*408000 1250000
60                 600000 1250000
61                 696000 1250000
62                 */
63                 816000 1250000
64                 1008000 1250000
65                 >;
66         status="okay";
67 };
68
69 &clk_gpu_dvfs_table {
70         operating-points = <
71                 /* KHz    uV */
72                 200000 1250000
73                 300000 1250000
74                 >;
75         status="okay";
76 };
77
78 &clk_ddr_dvfs_table {
79         operating-points = <
80                 /* KHz    uV */
81                 200000 950000
82                 300000 950000
83                 400000 1000000
84                 533000 1050000
85                 >;
86
87         freq-table = <
88                 /*status                freq(KHz)*/
89                 SYS_STATUS_NORMAL       533000
90                 SYS_STATUS_SUSPEND      200000
91                 /*
92                 SYS_STATUS_VIDEO_1080P  240000
93                 SYS_STATUS_VIDEO_4K     400000
94                 SYS_STATUS_PERFORMANCE  528000
95                 SYS_STATUS_DUALVIEW     400000
96                 SYS_STATUS_BOOST        324000
97                 SYS_STATUS_ISP          533000
98                 */
99                 >;
100         auto-freq-table = <
101                 240000
102                 324000
103                 396000
104                 528000
105                 >;
106         auto-freq=<0>;
107         status="okay";
108 };
109
110 &pwm_regulator1 {
111         status = "okay";
112 };
113
114 &pwm_regulator2 {
115         status = "okay";
116 };
117
118 &pwm1 {
119         status = "okay";
120 };
121
122 &uart1{
123         status = "okay";
124         dma-names = "!tx", "!rx";
125         pinctrl-0 = <&uart1_xfer &uart1_cts>;
126 };
127
128 &pwm2 {
129         status = "okay";
130 };
131
132 &disp_timings {
133         native-mode = <&timing1>;
134 };
135
136 &rk_screen {
137         display-timings = <&disp_timings>;
138 };
139
140 &fb {
141         rockchip,disp-mode = <NO_DUAL>;
142 };
143
144 &lcdc {
145         status = "okay";
146         rockchip,fb-win-map = <FB0_WIN1_FB1_WIN0_FB2_WIN2>;
147 };
148
149 &tve {
150         status = "okay";
151 };
152
153 &i2c2 {
154         status = "disabled";
155 };
156
157 &gmac {
158         //pmu_regulator = "act_ldo5";
159         //pmu_enable_level = <1>; //1->HIGH, 0->LOW
160         //power-gpio = <&gpio0 GPIO_A6 GPIO_ACTIVE_HIGH>;
161         reset-gpio = <&gpio2 GPIO_D0 GPIO_ACTIVE_LOW>;
162         phy-mode = "rgmii";
163         clock_in_out = "input";
164         tx_delay = <0x30>;
165         rx_delay = <0x10>;
166 };
167
168 &codec {
169         spk_ctl_io = <&gpio1 GPIO_A3 GPIO_ACTIVE_HIGH>;
170         spk-mute-delay = <200>;
171         hp-mute-delay = <100>;
172         rk312x_for_mid = <1>;
173         is_rk3128 = <0>;
174         spk_volume = <25>;
175         hp_volume = <25>;
176         capture_volume = <26>;
177         gpio_debug = <1>;
178         codec_hp_det = <0>;
179 };
180
181 &dwc_control_usb {
182         usb_uart {
183                 status = "disabled";
184         };
185 };