blob: 3719c9f8d801416abc6777b49a2e57908f6fcf50 [file] [log] [blame]
/*
* Copyright (C) 2015 Nest Labs, Inc.
*
* 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.
*/
/dts-v1/;
#include <dt-bindings/gpio/gpio.h>
#include "flintstone-common.dtsi"
/ {
aliases {
serial-ble0 = &uart3;
i2c0 = &i2c1;
i2c1 = &i2c2;
i2c2 = &i2c3;
i2c3 = &i2c4;
};
memory {
reg = <0x80000000 0x20000000>; /* 512 MB */
};
sound {
compatible = "fsl,imx-marley";
model = "imx-audio";
cpu-dai = <&sai1>;
spkr-codec = <&codec_tfa9890>;
dsp = <&dsp_cs47l35>;
clocks = <&pad_clk_24m>;
};
regulators {
compatible = "simple-bus";
/* PP_V3V (via TPS630252YFF Buck Regulator) */
buck_3v3_reg: buck_3v3 {
compatible = "regulator-fixed";
regulator-name = "3v3_buck";
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
regulator-always-on;
};
/* Fake fixed regulator used by audio drivers */
audio_dummy_regulator: fixedregulator@0 {
compatible = "regulator-fixed";
regulator-name = "fixed-supply";
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
};
};
gpio-keys {
compatible = "gpio-keys";
panic-button {
label = "Panic";
gpios = <&gpio7 3 GPIO_ACTIVE_LOW>;
linux,code = <63>; /* KEY_F5 */
gpio-key,wakeup;
};
five-key {
label = "Five Key";
gpios = <&gpio7 0 GPIO_ACTIVE_LOW>;
linux,code = <6>; /* KEY_5 */
gpio-key,wakeup;
};
};
/* GPIO Exporter Nodes */
tamper-gpios {
reg = <0x0 0>;
compatible = "nestlabs,gpio-exporter";
input-names = "usb-id-pin";
input-gpios = <&gpio4 17 GPIO_ACTIVE_HIGH>;
};
brcm_wifi {
reg = <0x0 0>;
compatible = "nestlabs,gpio-exporter";
output-names = "reset";
output-gpios = <&gpio1 4 GPIO_ACTIVE_HIGH>;
};
brcm-wlan {
compatible = "brcm,bcmdhd_wlan";
interrupts-extended = <&gpio5 15 IRQ_TYPE_LEVEL_HIGH>;
};
em35x-gpios {
reg = <0x0 0>;
compatible = "nestlabs,gpio-exporter";
output-names = "reset", "wake";
output-gpios = <&gpio2 0 GPIO_ACTIVE_HIGH
&gpio2 5 GPIO_ACTIVE_HIGH>;
input-names = "irq";
input-gpios = <&gpio2 4 GPIO_ACTIVE_HIGH>;
};
ble0-da14580-gpios {
reg = <0x0 0>;
compatible = "nestlabs,gpio-exporter";
output-names = "reset";
output-gpios = <&gpio5 16 GPIO_ACTIVE_HIGH>;
};
buzzer-gpios {
reg = <0x0 0>;
compatible = "nestlabs,gpio-exporter";
output-names = "power-enable", "enable";
output-gpios = <&gpio5 0 GPIO_ACTIVE_HIGH
&gpio5 1 GPIO_ACTIVE_LOW>;
};
sound-gpios {
reg = <0x0 0>;
compatible = "nestlabs,gpio-exporter";
output-names = "audio-mux-data";
output-gpios = <&gpio7 5 GPIO_ACTIVE_HIGH>;
};
wdog-gpios {
reg = <0x0 0>;
compatible = "nestlabs,gpio-exporter";
output-names = "wdog1-b";
output-gpios = <&gpio1 8 GPIO_ACTIVE_HIGH>;
};
cell-gpios {
reg = <0x0 0>;
compatible = "nestlabs,gpio-exporter";
input-names = "cell-presence", "cell-on";
input-gpios = <&gpio3 12 GPIO_ACTIVE_LOW
&gpio2 1 GPIO_ACTIVE_HIGH>;
output-names = "power-enable", "power-reset";
output-gpios = <&gpio5 12 GPIO_ACTIVE_HIGH
&gpio5 13 GPIO_ACTIVE_HIGH>;
};
pad_clk_24m: pad-clk-24m {
compatible = "padctl-gate-clock";
clocks = <&osc>;
#clock-cells = <0>;
pinctrl-names = "default", "active";
pinctrl-0 = <&pinctrl_24m_disabled>;
pinctrl-1 = <&pinctrl_24m_enabled>;
status = "okay";
};
};
/* Battery Divider Circuit ADC */
&adc1 {
#io-channel-cells = <1>;
vref-supply = <&buck_3v3_reg>;
status = "okay";
};
/* Zigbee SPI */
&ecspi3 {
fsl,spi-num-chipselects = <1>;
cs-gpios = <&gpio4 30 GPIO_ACTIVE_LOW>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_ecspi3_1>;
dmas;
status = "okay";
spidev_em35x@0 {
compatible = "spidev";
spi-max-frequency = <20000000>;
reg = <0>;
};
};
/* Power Controller */
&gpc {
fsl,cpu_pupscr_sw2iso = <0xf>;
fsl,cpu_pupscr_sw = <0xf>;
fsl,cpu_pdnscr_iso2sw = <0x1>;
fsl,cpu_pdnscr_iso = <0x1>;
fsl,wdog-reset = <1>; /* watchdog select of reset source */
};
/* Sensors I2C */
&i2c1 {
clock-frequency = <400000>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_i2c1_3>;
status = "okay";
/* Homekit @ 0x10 */
hk@10 {
compatible = "apple,hk";
reg = <0x10>;
reset-gpio = <&gpio4 19 GPIO_ACTIVE_HIGH>;
};
/* LIS2DH12 (Accel) @ 0x18 */
lis2dh12@18 {
compatible = "st,lis2dh12";
reg = <0x18>;
interrupt-parent = <&gpio1>;
interrupts = <13 GPIO_ACTIVE_HIGH>;
};
/* SHTC1 (Humidity) @ 0x70 */
shtc1@70 {
compatible = "sensirion,shtc1";
reg = <0x70>;
};
/* TMP103B (Temp) @ 0x71 */
tmp103b@71 {
compatible = "ti,tmp103b";
reg = <0x71>;
};
/* TMP103C (Temp) @ 0x72 */
tmp103b@72 {
compatible = "ti,tmp103c";
reg = <0x72>;
};
/* TMP103D (Temp) @ 0x73 */
tmp103b@73 {
compatible = "ti,tmp103d";
reg = <0x73>;
};
};
/* Audio I2C */
&i2c3 {
clock-frequency = <400000>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_i2c3_3>;
status = "okay";
codec_tfa9890: tfa9890@37 {
compatible = "nxp,tfa98xx";
reg = <0x37>;
reset-gpio = <&gpio5 2 0>; /* RESET */
};
codec_wm8940: wm8940@1a {
compatible = "wlf,wm8940";
reg = <0x1a>;
};
};
/* PMIC and Charger I2C */
&i2c4 {
clock-frequency = <400000>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_i2c4_3>;
status = "okay";
/* MMPF0200 (PMIC) @ 0x08 */
pmic: pfuze200@08 {
compatible = "fsl,pfuze200";
reg = <0x08>;
regulators {
/* PP_VDDCORE */
sw1a_reg: sw1ab {
regulator-min-microvolt = <1350000>;
regulator-max-microvolt = <1350000>;
regulator-boot-on;
regulator-always-on;
regulator-ramp-delay = <6250>;
};
/* STANDBY PP_VDDCORE */
sw1astby_reg: sw1abstby {
regulator-min-microvolt = <975000>;
regulator-max-microvolt = <975000>;
regulator-boot-on;
regulator-always-on;
};
/* PP_VDDSOC */
sw2_reg: sw2 {
regulator-min-microvolt = <1350000>;
regulator-max-microvolt = <1350000>;
regulator-boot-on;
regulator-always-on;
};
/* STANDBY PP_VDDSOC */
sw2stby_reg: sw2stby {
regulator-min-microvolt = <1125000>;
regulator-max-microvolt = <1125000>;
regulator-boot-on;
regulator-always-on;
};
/* PP_1V8 */
sw3a_reg: sw3a {
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
regulator-boot-on;
regulator-always-on;
};
/* STANDBY PP1V8 */
sw3astby_reg: sw3astby {
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
regulator-boot-on;
regulator-always-on;
};
/* PP_1V2_DDR */
sw3b_reg: sw3b {
regulator-min-microvolt = <1200000>;
regulator-max-microvolt = <1200000>;
regulator-boot-on;
regulator-always-on;
};
/* STANDBY PP_1V2_DDR */
sw3bstby_reg: sw3bstby {
regulator-min-microvolt = <1200000>;
regulator-max-microvolt = <1200000>;
regulator-boot-on;
regulator-always-on;
};
/* PP_5V_PMIC */
swbst_reg: swbst {
regulator-min-microvolt = <5000000>;
regulator-max-microvolt = <5000000>;
};
/* PP_VSNVS_3V0 */
snvs_reg: vsnvs {
regulator-min-microvolt = <3000000>;
regulator-max-microvolt = <3000000>;
regulator-boot-on;
regulator-always-on;
};
/* PP_DDR_VREF */
vref_reg: vrefddr {
regulator-boot-on;
regulator-always-on;
};
/* SWBST_EN_H: */
vgen3_reg: vgen3 {
regulator-min-microvolt = <3000000>;
regulator-max-microvolt = <3000000>;
regulator-always-on;
};
/* PP_3V0_LDO: */
vgen4_reg: vgen4 {
regulator-min-microvolt = <3000000>;
regulator-max-microvolt = <3000000>;
regulator-always-on;
};
/* PP1V8_LDO: */
vgen5_reg: vgen5 {
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
regulator-always-on;
};
};
};
/* BQ24251RGE (Charger Chip) @ 0x6A */
bq24251rge@6a {
compatible = "ti,bq24251-charger";
reg = <0x6a>;
stat-gpio = <&gpio4 21 GPIO_ACTIVE_HIGH>;
battery-regulation-voltage = <4200000>;
charge-current = <500000>;
term-current-sense-threshold = <50000>;
vindpm-threshold = <4200000>;
ovp-voltage = <6500000>;
io-channels = <&adc1 0>;
divider-r1-ohm = <100000>;
divider-r2-ohm = <301000>;
power-supplies = <&usbotg1>;
};
};
/* Pinmux Controller */
&iomuxc {
i2c1 {
pinctrl_i2c1_3: i2c1grp-3 {
fsl,pins = <
MX6SX_PAD_GPIO1_IO01__I2C1_SDA 0x4001b899
MX6SX_PAD_GPIO1_IO00__I2C1_SCL 0x4001b899
>;
};
};
i2c3 {
pinctrl_i2c3_3: i2c3grp-3 {
fsl,pins = <
MX6SX_PAD_KEY_ROW4__I2C3_SDA 0x4001f899
MX6SX_PAD_KEY_COL4__I2C3_SCL 0x4001f899
>;
};
};
i2c4 {
pinctrl_i2c4_3: i2c4grp-3 {
fsl,pins = <
MX6SX_PAD_USB_H_DATA__I2C4_SDA 0x4001b899
MX6SX_PAD_USB_H_STROBE__I2C4_SCL 0x4001b899
>;
};
};
sai1 {
pinctrl_sai1_3: sai1grp_3 {
fsl,pins = <
MX6SX_PAD_RGMII2_TD3__SAI1_TX_BCLK 0x1b030
MX6SX_PAD_RGMII2_TD2__SAI1_TX_SYNC 0x1b030
MX6SX_PAD_RGMII2_TXC__SAI1_TX_DATA_0 0x1b030
MX6SX_PAD_RGMII2_TX_CTL__SAI1_RX_DATA_0 0x1b030
>;
};
};
uart1 {
pinctrl_uart1_2: uart1grp-2 {
fsl,pins = <
MX6SX_PAD_ENET2_COL__UART1_RX 0x1b0b1
MX6SX_PAD_ENET2_CRS__UART1_TX 0x1b0b1
>;
};
};
uart3 {
pinctrl_uart3_2: uart3grp-2 {
fsl,pins = <
MX6SX_PAD_SD3_DATA4__UART3_RX 0x0041b0b1
MX6SX_PAD_SD3_DATA5__UART3_TX 0x0041b0b1
MX6SX_PAD_SD3_DATA7__UART3_CTS_B 0x0041b0b1
MX6SX_PAD_SD3_DATA6__UART3_RTS_B 0x0041b0b1
>;
};
};
hog {
mlb_hogs: mlb-hogs {
fsl,pins = <
MX6SX_PAD_SD3_DATA1__GPIO7_IO_3 0x0041b0b0 /* Panic Button */
MX6SX_PAD_SD3_CLK__GPIO7_IO_0 0x004100b0 /* 5 Key Button */
MX6SX_PAD_RGMII2_RD3__GPIO5_IO_15 0x400010b0 /* wifi OOB: interrupt to cpu */
MX6SX_PAD_GPIO1_IO04__GPIO1_IO_4 0x400010b0 /* wifi OOB: reset from cpu */
MX6SX_PAD_ENET1_RX_CLK__GPIO2_IO_4 0x400010b0 /* zb OOB: IRQ from zb */
MX6SX_PAD_ENET1_COL__GPIO2_IO_0 0x400010b0 /* zb OOB: Reset from cpu */
MX6SX_PAD_ENET1_TX_CLK__GPIO2_IO_5 0x400010b0 /* zb OOB: Wake from cpu */
MX6SX_PAD_RGMII2_RX_CTL__GPIO5_IO_16 0x400010b0 /* BLE_RST */
MX6SX_PAD_RGMII1_RD0__GPIO5_IO_0 0x400000b0 /* HORN_PWR_EN */
MX6SX_PAD_RGMII1_RD1__GPIO5_IO_1 0x400000b0 /* HORN_EN_L */
MX6SX_PAD_RGMII1_TD0__GPIO5_IO_6 0x400010b0 /* Audio DSP Reset */
MX6SX_PAD_RGMII1_TD1__GPIO5_IO_7 0x400010b0 /* Audio DSP Interrupt */
MX6SX_PAD_ENET2_TX_CLK__GPIO2_IO_9 0x400010b0 /* Audio DSP Busy */
MX6SX_PAD_QSPI1B_DQS__GPIO4_IO_28 0x400010b0 /* ecspi5 SS0 cs GPIO */
MX6SX_PAD_RGMII1_RD2__GPIO5_IO_2 0x400010b0 /* TFA9890 Reset */
MX6SX_PAD_SD3_DATA3__GPIO7_IO_5 0x004000b0 /* Audio mux data */
MX6SX_PAD_QSPI1B_SS0_B__GPIO4_IO_30 0x400010b0 /* ecspi3 SS0 cs GPIO */
MX6SX_PAD_GPIO1_IO13__GPIO1_IO_13 0x400000b0 /* lis2dh12 interrupt */
MX6SX_PAD_RGMII1_RD2__GPIO5_IO_2 0x400010b0 /* tfa9890 reset */
MX6SX_PAD_QSPI1A_SCLK__GPIO4_IO_21 0x000000b0 /* bq24251 stat */
MX6SX_PAD_ENET1_MDIO__OSC32K_32K_OUT 0x000000b0 /* CPU_32K_CLK_OUT */
MX6SX_PAD_RGMII2_RD0__GPIO5_IO_12 0x400000b0 /* CELL_POWER_EN */
MX6SX_PAD_RGMII2_RD1__GPIO5_IO_13 0x400000b0 /* CELL_POWER_RESET */
MX6SX_PAD_LCD1_DATA11__GPIO3_IO_12 0x400010b0 /* CELL_PRESENCE */
MX6SX_PAD_ENET1_CRS__GPIO2_IO_1 0x400010b0 /* CELL_ON */
MX6SX_PAD_QSPI1A_DATA1__GPIO4_IO_17 0x0001b8b1 /* USB ID Pin used as tamper */
MX6SX_PAD_RGMII2_TD0__GPIO5_IO_18 0x000000b0 /* Warm Reset */
MX6SX_PAD_QSPI1A_DATA3__GPIO4_IO_19 0x000010b0 /* HK reset */
>;
};
};
ecspi3 {
pinctrl_ecspi3_1: ecspi3grp-1 {
fsl,pins = <
MX6SX_PAD_QSPI1B_DATA1__ECSPI3_MISO 0x100b1
MX6SX_PAD_QSPI1B_DATA0__ECSPI3_MOSI 0x100b1
MX6SX_PAD_QSPI1B_SCLK__ECSPI3_SCLK 0x100b1
>;
};
};
ecspi5 {
pinctrl_ecspi5_1: ecspi5grp-1 {
fsl,pins = <
MX6SX_PAD_QSPI1A_SS1_B__ECSPI5_MISO 0x100b1
MX6SX_PAD_QSPI1A_DQS__ECSPI5_MOSI 0x100b1
MX6SX_PAD_QSPI1B_SS1_B__ECSPI5_SCLK 0x100b1
>;
};
};
24m-clk {
pinctrl_24m_enabled: 24m-enabled {
fsl,pins = <
MX6SX_PAD_ENET1_MDC__ANATOP_24M_OUT 0x000010b0 /* CPU_24M_CLK_OUT */
>;
};
pinctrl_24m_disabled: 24m-disabled {
fsl,pins = <
MX6SX_PAD_ENET1_MDC__ANATOP_24M_OUT 0x00001000 /* CPU_24M_CLK_OUT */
>;
};
};
usdhc2 {
pinctrl_usdhc2_1: usdhc2grp-1 {
fsl,pins = <
MX6SX_PAD_SD2_CMD__USDHC2_CMD 0x17059
MX6SX_PAD_SD2_CLK__USDHC2_CLK 0x10059
MX6SX_PAD_SD2_DATA0__USDHC2_DATA0 0x17059
MX6SX_PAD_SD2_DATA1__USDHC2_DATA1 0x17059
MX6SX_PAD_SD2_DATA2__USDHC2_DATA2 0x17059
MX6SX_PAD_SD2_DATA3__USDHC2_DATA3 0x17059
>;
};
};
};
/* A9 Debug UART */
&uart1 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_uart1_2>;
status = "okay";
};
/* Bluetooth UART */
&uart3 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_uart3_2>;
fsl,uart-has-rtscts;
fsl,uart-can-wake;
fsl,uart-cpu-mode;
status = "okay";
};
/* Debug USB (Device) */
&usbotg1 {
dr_mode = "peripheral";
status = "okay";
imx-usb-charger-detection;
};
/* Cellular USB (Host) */
&usbotg2 {
vbus-supply = <&swbst_reg>;
dr_mode = "host";
disable-over-current;
status = "okay";
};
/* WIFI SDIO */
&usdhc2 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_usdhc2_1>;
non-removable;
keep-power-in-suspend;
enable-sdio-wakeup;
status = "okay";
brcm-fmac {
reg = <1>;
compatible = "brcm,bcm4329-fmac";
interrupt-names = "host-wake";
interrupt-parent = <&gpio5>;
interrupts = <15 IRQ_TYPE_LEVEL_HIGH>;
};
};
/* GPMI NAND */
&gpmi {
status = "okay";
nand-on-flash-bbt; /* Need to reserve NAND_BBT_SCAN_MAXBLOCKS at end of NAND */
fsl,legacy-bch-geometry;
partition@0-a {
label = "nand0";
reg = <0x0 0x20000000>;
};
partition@0-b {
label = "u-boot";
reg = <0x0 0x00400000>;
};
partition@00400000 {
label = "ubipart";
reg = <0x00400000 0x1F400000>;
};
partition@1F800000 {
label = "oopsdata";
reg = <0x1F800000 0x780000>;
};
};
/* Smart DMA */
&sdma {
gpr = <&gpr>;
/* SDMA event remap for SAI1 */
fsl,sdma-event-remap = <0 15 1>, <0 16 1>;
};
/* Synchronous Audio Interface */
&sai1 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_sai1_3>;
status = "okay";
};
/* Audio DSP */
&ecspi5 {
fsl,spi-num-chipselects = <1>;
cs-gpios = <&gpio4 28 GPIO_ACTIVE_LOW>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_ecspi5_1>;
dmas;
status = "okay";
dsp_cs47l35: cs47l35@0 {
spi-max-frequency = <19200000>;
compatible = "cirrus,cs47l35";
reg = <0x0>;
interrupt-parent = <&gpio5>;
interrupts = <7 GPIO_ACTIVE_LOW>;
AVDD-supply = <&audio_dummy_regulator>;
DBVDD1-supply = <&audio_dummy_regulator>;
DBVDD2-supply = <&audio_dummy_regulator>;
CPVDD1-supply = <&audio_dummy_regulator>;
CPVDD2-supply = <&audio_dummy_regulator>;
DCVDD-supply = <&audio_dummy_regulator>;
SPKVDD-supply = <&audio_dummy_regulator>;
MICVDD-supply = <&audio_dummy_regulator>;
cirrus,reset = <&gpio5 6 0>;
cirrus,clk32k-src = <3>;
cirrus,micbias1 = <2800 0 1 1 1 1 1 0>;
cirrus,inmode = < 0 0 0 0
0 0 0 0
0 0 0 0
0 0 0 0
0 0 0 0
0 0 0 0 >;
cirrus,gpio-defaults = <
0x00002000 0x0000f000 /* AIF3TXDAT / GPIO1 */
0x00002000 0x0000f000 /* AIF3BCLK / GPIO2 */
0x00002000 0x0000f000 /* AIF3RXDAT / GPIO3 */
0x00002000 0x0000f000 /* AIF3LRCLK / GPIO4 */
0x00002010 0x0000f000 /* FLL1 Output / GPIO5 */
0x00002018 0x0000f000 /* FLL1 Locked? / GPIO6 */
0x00002000 0x0000f000 /* MIF1SDA / GPIO7 */
0x00002000 0x0000f000 /* AIF1RXDAT / GPIO8 */
0x00002000 0x0000f000 /* AIF1BCLK / GPIO9 */
0x00002000 0x0000f000 /* AIF1TXDAT / GPIO10 */
0x00002000 0x0000f000 /* AIF1LRCLK / GPIO11 */
0x00002000 0x0000f000 /* AIF2TXDAT / GPIO12 */
0x00002000 0x0000f000 /* AIF2BCLK / GPIO13 */
0x00002000 0x0000f000 /* AIF2RXDAT / GPIO14 */
0x00002000 0x0000f000 /* AIF2LRCLK / GPIO15 */
0x00002000 0x0000f000 /* MIF1SCLK / GPIO16 */
>;
};
};