/* * Copyright (C) 2012 Texas Instruments Incorporated - http://www.ti.com/ * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as * published by the Free Software Foundation. */ #include / { model = "xxxxxxxxxx"; compatible = "ti,am335x-bone", "ti,am33xx"; wlan_en_reg: fixedregulator@1 { compatible = "regulator-fixed"; regulator-name = "wlan-en-regulator"; regulator-min-microvolt = <1800000>; regulator-max-microvolt = <1800000>; /* WLAN_PWR_EN GPIO for this board - Bank2, pin24 */ gpio = <&gpio2 24 GPIO_ACTIVE_HIGH>; startup-delay-us = <70000>; enable-active-high; // regulator-always-on; }; reg_1p8v: 1p8v { compatible = "regulator-fixed"; regulator-name = "1p8v"; regulator-min-microvolt = <1800000>; regulator-max-microvolt = <1800000>; }; kim { compatible = "kim"; /* BT_EN for this board - Bank2, pin22 */ nshutdown_gpio = <86>; // dev_name = "/dev/ttyS3"; dev_name = "/dev/ttyO3"; // flow_cntrl = <1>; flow_cntrl = <0>; // baud_rate = <1000000>; baud_rate = <115200>; // baud_rate = <9600>; }; btwilink { compatible = "btwilink"; }; }; &am33xx_pinmux { pinctrl-names = "default", "sleep"; //pinctrl-0 = <&wlan_pins_default>; //pinctrl-1 = <&wlan_pins_sleep>; /* wl18xx uses SDIO port mmc0 alias mmc1 in dts */ mmc1_pins_default: pinmux_mmc1_pins { pinctrl-single,pins = < 0x0F0 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc0_dat3.mmc0_dat3 */ 0x0F4 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc0_dat2.mmc0_dat2 */ 0x0F8 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc0_dat1.mmc0_dat1 */ 0x0FC (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc0_dat0.mmc0_dat0 */ 0x100 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc0_clk.mmc0_clk */ 0x104 (PIN_INPUT_PULLUP | MUX_MODE0) /* mmc0_cmd.mmc0_cmd */ >; }; mmc1_pins_sleep: pinmux_mmc1_pins_sleep { pinctrl-single,pins = < 0x0F0 (PIN_INPUT_PULLDOWN | MUX_MODE7) 0x0F4 (PIN_INPUT_PULLDOWN | MUX_MODE7) 0x0F8 (PIN_INPUT_PULLDOWN | MUX_MODE7) 0x0FC (PIN_INPUT_PULLDOWN | MUX_MODE7) 0x100 (PIN_INPUT_PULLDOWN | MUX_MODE7) 0x104 (PIN_INPUT_PULLDOWN | MUX_MODE7) >; }; /* wl18xx card enable/irq GPIOs. */ /* In addition to the MMC, UART interfaces, the WiLink module needs three additional GPIO lines: */ /* WLAN Power Enable (GPIO2_10): Set as an output pin */ /* WLAN Irq (GPIO0_6): Set as a GPIO input pin */ /* BT Irq (GPIO0_7): Set as a GPIO input pin */ /* BT/GPS Enable (GPIO2_22): Set as a GPIO output pin with pull-up enabled. */ /* The pullup is needed for keeping the chip enabled when system is suspending so we would not need */ /* to releoad the firmware after each suspend/resume cycle.*/ wlan_pins_default: pinmux_wlan_pins_default { pinctrl-single,pins = < 0xe8 ( PIN_OUTPUT_PULLDOWN /*PIN_OUTPUT_PULLUP */ | MUX_MODE7 ) /* (U5 = WL_ENABLE ) lcd_dat3.gpio2[24] */ 0x160 ( PIN_INPUT_PULLUP | MUX_MODE7 ) /* (C15 = WL_IRQ/MMC0_CD) spi0_cs1.gpio0[6] */ 0xb0 ( PIN_OUTPUT_PULLUP | MUX_MODE7 ) /* (T1 = WIFI_PWR_ENABLE) lcd_data4.gpio2[10] */ 0xe0 ( PIN_OUTPUT_PULLUP | MUX_MODE7 ) /* (U5 = BT_ENABLE ) lcd_vsync.gpio2[22] */ 0x164 ( PIN_INPUT_PULLUP | MUX_MODE7 ) /* (C18 = BT_IRQ) eCAP0_in_PWM0_out.gpio0[7] */ 0x1b4 ( PIN_INPUT_PULLUP | MUX_MODE7 ) /* (B15)= xdma_event_intr1.gpio0[20] also connected to UART3 RX*/ >; }; wlan_pins_sleep: pinmux_wlan_pins_sleep { pinctrl-single,pins = < 0xe8 ( PIN_OUTPUT_PULLDOWN/* PIN_OUTPUT_PULLUP */ | MUX_MODE7 ) /* (U5 = WL_ENABLE ) lcd_dat3.gpio2[24] */ 0x160 ( PIN_INPUT_PULLUP | MUX_MODE7 ) /* (C15 = WL_IRQ/MMC0_CD) spi0_cs1.gpio0[6] */ 0xb0 ( PIN_OUTPUT_PULLUP | MUX_MODE7 ) /* (T1 = WIFI_PWR_ENABLE) lcd_data4.gpio2[10] */ 0xe0 ( PIN_OUTPUT_PULLUP | MUX_MODE7 ) /* (U5 = BT_ENABLE ) lcd_vsync.gpio2[22] */ 0x164 ( PIN_INPUT_PULLUP | MUX_MODE7 ) /* (C18 = BT_IRQ) eCAP0_in_PWM0_out.gpio0[7] */ 0x1b4 ( PIN_INPUT_PULLUP | MUX_MODE7 ) /* (B15)= xdma_event_intr1.gpio0[20] also connected to UART3 RX*/ >; }; }; /* For USB1 to UART3 for the BT Module*/ &uart3 { status = "okay"; }; /* wl18xx card Bluetooth UART on uart3 which is UART over USB special PHY mode requiring mods to drivers/usb/phy/phy-am335x-control.c*/ &usb1_phy{ status = "okay"; }; &usb1 { status = "okay"; // dr_mode = "host"; // enable PHY for USB1 to UART3 }; &mmc1{ status = "okay"; vmmc-supply = <&wlan_en_reg>; vqmmc-supply = <®_1p8v>; voltage-ranges = <1800 1800>; bus-width = <4>; pinctrl-names = "default", "sleep"; pinctrl-0 = <&mmc1_pins_default &wlan_pins_default>; pinctrl-1 = <&mmc1_pins_sleep &wlan_pins_sleep>; ti,non-removable; ti,needs-special-hs-handling; cap-power-off-card; keep-power-in-suspend; enable-sdio-wakeup; #address-cells = <1>; #size-cells = <0>; wlcore: wlcore@0 { compatible = "ti,wl1831"; reg = <2>; interrupt-parent = <&gpio0>; interrupts = <6 IRQ_TYPE_EDGE_FALLING>; /* WL_IRQ gpio0[6] has an inverting levelshift on baseboard */ pwr-enable = <&gpio2 24 0>; }; };