1*f126890aSEmmanuel Vadot// SPDX-License-Identifier: GPL-2.0-only 2*f126890aSEmmanuel Vadot/* 3*f126890aSEmmanuel Vadot * Copyright (C) 2012 Texas Instruments Incorporated - https://www.ti.com/ 4*f126890aSEmmanuel Vadot */ 5*f126890aSEmmanuel Vadot/dts-v1/; 6*f126890aSEmmanuel Vadot 7*f126890aSEmmanuel Vadot#include "am33xx.dtsi" 8*f126890aSEmmanuel Vadot#include "am335x-bone-common.dtsi" 9*f126890aSEmmanuel Vadot#include "am335x-bonegreen-common.dtsi" 10*f126890aSEmmanuel Vadot#include <dt-bindings/interrupt-controller/irq.h> 11*f126890aSEmmanuel Vadot 12*f126890aSEmmanuel Vadot/ { 13*f126890aSEmmanuel Vadot model = "TI AM335x BeagleBone Green Wireless"; 14*f126890aSEmmanuel Vadot compatible = "ti,am335x-bone-green-wireless", "ti,am335x-bone-green", "ti,am335x-bone-black", "ti,am335x-bone", "ti,am33xx"; 15*f126890aSEmmanuel Vadot 16*f126890aSEmmanuel Vadot wlan_en_reg: fixedregulator@2 { 17*f126890aSEmmanuel Vadot compatible = "regulator-fixed"; 18*f126890aSEmmanuel Vadot regulator-name = "wlan-en-regulator"; 19*f126890aSEmmanuel Vadot regulator-min-microvolt = <1800000>; 20*f126890aSEmmanuel Vadot regulator-max-microvolt = <1800000>; 21*f126890aSEmmanuel Vadot startup-delay-us = <70000>; 22*f126890aSEmmanuel Vadot 23*f126890aSEmmanuel Vadot /* WL_EN */ 24*f126890aSEmmanuel Vadot gpio = <&gpio0 26 0>; 25*f126890aSEmmanuel Vadot enable-active-high; 26*f126890aSEmmanuel Vadot }; 27*f126890aSEmmanuel Vadot}; 28*f126890aSEmmanuel Vadot 29*f126890aSEmmanuel Vadot&am33xx_pinmux { 30*f126890aSEmmanuel Vadot bt_pins: bt-pins { 31*f126890aSEmmanuel Vadot pinctrl-single,pins = < 32*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_GPMC_BEN1, PIN_OUTPUT_PULLUP, MUX_MODE7) /* gpmc_ad12.gpio1_28 BT_EN */ 33*f126890aSEmmanuel Vadot >; 34*f126890aSEmmanuel Vadot }; 35*f126890aSEmmanuel Vadot 36*f126890aSEmmanuel Vadot mmc3_pins: mmc3-pins { 37*f126890aSEmmanuel Vadot pinctrl-single,pins = < 38*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_GPMC_AD12, PIN_INPUT_PULLUP, MUX_MODE3) /* gpmc_ad12.mmc2_dat0 */ 39*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_GPMC_AD13, PIN_INPUT_PULLUP, MUX_MODE3) /* gpmc_ad13.mmc2_dat1 */ 40*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_GPMC_AD14, PIN_INPUT_PULLUP, MUX_MODE3) /* gpmc_ad14.mmc2_dat2 */ 41*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_GPMC_AD15, PIN_INPUT_PULLUP, MUX_MODE3) /* gpmc_ad15.mmc2_dat3 */ 42*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_GPMC_CSN3, PIN_INPUT_PULLUP, MUX_MODE3) /* gpmc_csn3.mmc2_cmd */ 43*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_GPMC_CLK, PIN_INPUT_PULLUP, MUX_MODE3) /* gpmc_clk.mmc2_clk */ 44*f126890aSEmmanuel Vadot >; 45*f126890aSEmmanuel Vadot }; 46*f126890aSEmmanuel Vadot 47*f126890aSEmmanuel Vadot uart3_pins: uart3-pins { 48*f126890aSEmmanuel Vadot pinctrl-single,pins = < 49*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_MII1_RXD3, PIN_INPUT_PULLUP, MUX_MODE1) /* gmii1_rxd3.uart3_rxd */ 50*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_MII1_RXD2, PIN_OUTPUT_PULLDOWN, MUX_MODE1) /* gmii1_rxd2.uart3_txd */ 51*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_MDIO, PIN_INPUT, MUX_MODE3) /* mdio_data.uart3_ctsn */ 52*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_MDC, PIN_OUTPUT_PULLDOWN, MUX_MODE3) /* mdio_clk.uart3_rtsn */ 53*f126890aSEmmanuel Vadot >; 54*f126890aSEmmanuel Vadot }; 55*f126890aSEmmanuel Vadot 56*f126890aSEmmanuel Vadot wl18xx_pins: wl18xx-pins { 57*f126890aSEmmanuel Vadot pinctrl-single,pins = < 58*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_GPMC_AD10, PIN_OUTPUT_PULLDOWN, MUX_MODE7) /* gpmc_ad10.gpio0_26 WL_EN */ 59*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_GPMC_AD11, PIN_INPUT_PULLDOWN, MUX_MODE7) /* gpmc_ad11.gpio0_27 WL_IRQ */ 60*f126890aSEmmanuel Vadot AM33XX_PADCONF(AM335X_PIN_GPMC_CSN0, PIN_OUTPUT_PULLUP, MUX_MODE7) /* gpmc_csn0.gpio1_29 LS_BUF_EN */ 61*f126890aSEmmanuel Vadot >; 62*f126890aSEmmanuel Vadot }; 63*f126890aSEmmanuel Vadot}; 64*f126890aSEmmanuel Vadot 65*f126890aSEmmanuel Vadot&mac_sw { 66*f126890aSEmmanuel Vadot status = "disabled"; 67*f126890aSEmmanuel Vadot}; 68*f126890aSEmmanuel Vadot 69*f126890aSEmmanuel Vadot&mmc3 { 70*f126890aSEmmanuel Vadot dmas = <&edma_xbar 12 0 1 71*f126890aSEmmanuel Vadot &edma_xbar 13 0 2>; 72*f126890aSEmmanuel Vadot dma-names = "tx", "rx"; 73*f126890aSEmmanuel Vadot status = "okay"; 74*f126890aSEmmanuel Vadot vmmc-supply = <&wlan_en_reg>; 75*f126890aSEmmanuel Vadot bus-width = <4>; 76*f126890aSEmmanuel Vadot non-removable; 77*f126890aSEmmanuel Vadot cap-power-off-card; 78*f126890aSEmmanuel Vadot keep-power-in-suspend; 79*f126890aSEmmanuel Vadot pinctrl-names = "default"; 80*f126890aSEmmanuel Vadot pinctrl-0 = <&mmc3_pins &wl18xx_pins>; 81*f126890aSEmmanuel Vadot 82*f126890aSEmmanuel Vadot #address-cells = <1>; 83*f126890aSEmmanuel Vadot #size-cells = <0>; 84*f126890aSEmmanuel Vadot wlcore: wlcore@2 { 85*f126890aSEmmanuel Vadot compatible = "ti,wl1835"; 86*f126890aSEmmanuel Vadot reg = <2>; 87*f126890aSEmmanuel Vadot interrupt-parent = <&gpio0>; 88*f126890aSEmmanuel Vadot interrupts = <27 IRQ_TYPE_EDGE_RISING>; 89*f126890aSEmmanuel Vadot }; 90*f126890aSEmmanuel Vadot}; 91*f126890aSEmmanuel Vadot 92*f126890aSEmmanuel Vadot&uart3 { 93*f126890aSEmmanuel Vadot pinctrl-names = "default"; 94*f126890aSEmmanuel Vadot pinctrl-0 = <&uart3_pins &bt_pins>; 95*f126890aSEmmanuel Vadot status = "okay"; 96*f126890aSEmmanuel Vadot 97*f126890aSEmmanuel Vadot bluetooth { 98*f126890aSEmmanuel Vadot compatible = "ti,wl1835-st"; 99*f126890aSEmmanuel Vadot enable-gpios = <&gpio1 28 GPIO_ACTIVE_HIGH>; 100*f126890aSEmmanuel Vadot }; 101*f126890aSEmmanuel Vadot}; 102*f126890aSEmmanuel Vadot 103*f126890aSEmmanuel Vadot&gpio1 { 104*f126890aSEmmanuel Vadot ls-buf-en-hog { 105*f126890aSEmmanuel Vadot gpio-hog; 106*f126890aSEmmanuel Vadot gpios = <29 GPIO_ACTIVE_HIGH>; 107*f126890aSEmmanuel Vadot output-high; 108*f126890aSEmmanuel Vadot line-name = "LS_BUF_EN"; 109*f126890aSEmmanuel Vadot }; 110*f126890aSEmmanuel Vadot}; 111*f126890aSEmmanuel Vadot 112*f126890aSEmmanuel Vadot/* BT_AUD_OUT from wl1835 has to be pulled low when WL_EN is activated.*/ 113*f126890aSEmmanuel Vadot/* in case it isn't, wilink8 ends up in one of the test modes that */ 114*f126890aSEmmanuel Vadot/* intruces various issues (elp wkaeup timeouts etc.) */ 115*f126890aSEmmanuel Vadot/* On the BBGW this pin is routed through the level shifter (U21) that */ 116*f126890aSEmmanuel Vadot/* introduces a pullup on the line and wilink8 ends up in a bad state. */ 117*f126890aSEmmanuel Vadot/* use a gpio hog to force this pin low. An alternative may be adding */ 118*f126890aSEmmanuel Vadot/* an external pulldown on U21 pin 4. */ 119*f126890aSEmmanuel Vadot 120*f126890aSEmmanuel Vadot&gpio3 { 121*f126890aSEmmanuel Vadot bt-aud-in-hog { 122*f126890aSEmmanuel Vadot gpio-hog; 123*f126890aSEmmanuel Vadot gpios = <16 GPIO_ACTIVE_HIGH>; 124*f126890aSEmmanuel Vadot output-low; 125*f126890aSEmmanuel Vadot line-name = "MCASP0_AHCLKR"; 126*f126890aSEmmanuel Vadot }; 127*f126890aSEmmanuel Vadot}; 128