ARM: dts: rk3288: support AP6212 wifi for Fennec
authorNickey Yang <nickey.yang@rock-chips.com>
Thu, 4 Aug 2016 08:13:26 +0000 (16:13 +0800)
committerHuang, Tao <huangtao@rock-chips.com>
Fri, 5 Aug 2016 02:30:11 +0000 (10:30 +0800)
This patch add and enable AP6212 wifi node for rk3288-fennec

Signed-off-by: Nickey Yang <nickey.yang@rock-chips.com>
Change-Id: I0bc77758869665992595c46471fc9bc7f9dff12c

arch/arm/boot/dts/rk3288-fennec.dts

index a6e8ec82250ca6a75a496bb0bc42e73949298a62..610304c45dec031b9ff592d61f4daf9bf0ddefab 100644 (file)
@@ -40,6 +40,7 @@
 
 /dts-v1/;
 
+#include <dt-bindings/clock/rockchip,rk808.h>
 #include "rk3288.dtsi"
 
 / {
                clock-output-names = "ext_gmac";
        };
 
+       io-domains {
+               compatible = "rockchip,rk3288-io-voltage-domain";
+               rockchip,grf = <&grf>;
+               wifi-supply = <&vcc_wl>;
+       };
+
+       sdio_pwrseq: sdio-pwrseq {
+               compatible = "mmc-pwrseq-simple";
+               clocks = <&rk808 RK808_CLKOUT1>;
+               clock-names = "ext_clock";
+               pinctrl-names = "default";
+               pinctrl-0 = <&wifi_enable_h>;
+
+               /*
+                * On the module itself this is one of these (depending
+                * on the actual card populated):
+                * - SDIO_RESET_L_WL_REG_ON
+                * - PDN (power down when low)
+                */
+               reset-gpios = <&gpio4 28 GPIO_ACTIVE_LOW>;
+       };
+
        sound {
                compatible = "simple-audio-card";
                simple-audio-card,format = "i2s";
                regulator-max-microvolt = <5000000>;
                regulator-always-on;
        };
+
+       wireless-wlan {
+               compatible = "wlan-platdata";
+               rockchip,grf = <&grf>;
+               wifi_chip_type = "ap6212";
+               sdio_vref = <1800>;
+               WIFI,host_wake_irq = <&gpio4 30 GPIO_ACTIVE_HIGH>;
+               status = "okay";
+       };
 };
 
 &cpu0 {
        status = "okay";
 };
 
+&sdio0 {
+       status = "okay";
+       clock-frequency = <50000000>;
+       clock-freq-min-max = <200000 50000000>;
+       bus-width = <4>;
+       cap-sd-highspeed;
+       cap-sdio-irq;
+       disable-wp;
+       keep-power-in-suspend;
+       mmc-pwrseq = <&sdio_pwrseq>;
+       non-removable;
+       num-slots = <1>;
+       pinctrl-names = "default";
+       pinctrl-0 = <&sdio0_bus4 &sdio0_cmd &sdio0_clk>;
+       sd-uhs-sdr104;
+       supports-sdio;
+};
+
 &pinctrl {
        pcfg_output_high: pcfg-output-high {
                output-high;
                };
        };
 
+       sdio-pwrseq {
+               wifi_enable_h: wifi-enable-h {
+                       rockchip,pins = <4 28 RK_FUNC_GPIO &pcfg_pull_none>;
+               };
+       };
+
        sdmmc {
                sdmmc_bus4: sdmmc-bus4 {
                        rockchip,pins = <6 16 RK_FUNC_1 &pcfg_pull_up_drv_8ma>,