From a92a1bb2e4ca2c2a865cddb9c8ee5230ad034462 Mon Sep 17 00:00:00 2001 From: Tapani Utriainen Date: Fri, 2 Mar 2018 18:05:18 +0800 Subject: [PATCH] ARM: dts: add support for TechNexion EDM-IMX6 with EDM1-FAIRY baseboard --- arch/arm/boot/dts/Makefile | 3 + arch/arm/boot/dts/baseboard_edm1_fairy.dtsi | 200 ++++++++++++++++++++ arch/arm/boot/dts/imx6dl-edm1_fairy.dts | 33 ++++ arch/arm/boot/dts/imx6q-edm1_fairy.dts | 34 ++++ arch/arm/boot/dts/imx6qp-edm1_fairy.dts | 50 +++++ 5 files changed, 320 insertions(+) create mode 100644 arch/arm/boot/dts/baseboard_edm1_fairy.dtsi create mode 100644 arch/arm/boot/dts/imx6dl-edm1_fairy.dts create mode 100644 arch/arm/boot/dts/imx6q-edm1_fairy.dts create mode 100644 arch/arm/boot/dts/imx6qp-edm1_fairy.dts diff --git a/arch/arm/boot/dts/Makefile b/arch/arm/boot/dts/Makefile index 421a69e66fb626..3df6d33f6b79c1 100644 --- a/arch/arm/boot/dts/Makefile +++ b/arch/arm/boot/dts/Makefile @@ -331,6 +331,7 @@ dtb-$(CONFIG_SOC_IMX6Q) += \ imx6dl-aristainetos2_4.dtb \ imx6dl-aristainetos2_7.dtb \ imx6dl-cubox-i.dtb \ + imx6dl-edm1_fairy.dtb \ imx6dl-dfi-fs700-m60.dtb \ imx6dl-gw51xx.dtb \ imx6dl-gw52xx.dtb \ @@ -396,6 +397,7 @@ dtb-$(CONFIG_SOC_IMX6Q) += \ imx6q-dfi-fs700-m60.dtb \ imx6q-dmo-edmqmx6.dtb \ imx6q-evi.dtb \ + imx6q-edm1_fairy.dtb \ imx6q-gk802.dtb \ imx6q-gw51xx.dtb \ imx6q-gw52xx.dtb \ @@ -443,6 +445,7 @@ dtb-$(CONFIG_SOC_IMX6Q) += \ imx6q-utilite-pro.dtb \ imx6q-wandboard.dtb \ imx6q-wandboard-revb1.dtb \ + imx6qp-edm1_fairy.dtb \ imx6qp-nitrogen6_max.dtb \ imx6qp-sabreauto.dtb \ imx6qp-sabreauto-ecspi.dtb \ diff --git a/arch/arm/boot/dts/baseboard_edm1_fairy.dtsi b/arch/arm/boot/dts/baseboard_edm1_fairy.dtsi new file mode 100644 index 00000000000000..af923ec337cc79 --- /dev/null +++ b/arch/arm/boot/dts/baseboard_edm1_fairy.dtsi @@ -0,0 +1,200 @@ +/* + * Copyright 2018 Technexion Ltd. + * + * Author: Tapani Utriainen + * Richard Hu + * + * 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 + +/ { + gpio-edm { + compatible = "gpio-edm"; + + gpio_p256 { + label = "GPIO_P256"; + gpios = <&EDM_EXT_GPIO_P256 GPIO_ACTIVE_HIGH>; + dir = "out"; + }; + + gpio_p257 { + label = "GPIO_P257"; + gpios = <&EDM_EXT_GPIO_P257 GPIO_ACTIVE_HIGH>; + dir = "out"; + }; + + gpio_p258 { + label = "GPIO_P258"; + gpios = <&EDM_EXT_GPIO_P258 GPIO_ACTIVE_HIGH>; + dir = "out"; + }; + + gpio_p260 { + label = "GPIO_P260"; + gpios = <&EDM_EXT_GPIO_P260 GPIO_ACTIVE_HIGH>; + dir = "out"; + }; + + gpio_p261 { + label = "GPIO_P261"; + gpios = <&EDM_EXT_GPIO_P261 GPIO_ACTIVE_HIGH>; + dir = "out"; + }; + + gpio_p262 { + label = "GPIO_P262"; + gpios = <&EDM_EXT_GPIO_P262 GPIO_ACTIVE_HIGH>; + dir = "out"; + }; + + gpio_p264 { + label = "GPIO_P264"; + gpios = <&EDM_EXT_GPIO_P264 GPIO_ACTIVE_HIGH>; + dir = "out"; + }; + }; + + sound { + compatible = "fsl,imx-sgtl5000", + "fsl,imx-audio-sgtl5000"; + model = "audio-sgtl5000"; + ssi-controller = <&EDM_AUDA_I2S_CHANNEL>; + audio-codec = <&codec>; + audio-routing = + "MIC_IN", "Mic Jack", + "Mic Jack", "Mic Bias", + "Headphone Jack", "HP_OUT"; +#if defined(EDM_AUDA_MUX_INT) && defined(EDM_AUDA_MUX_EXT) + mux-int-port = ; + mux-ext-port = ; +#else + fsl,no-audmux = "true"; +#endif + }; +}; + +&EDM_I2CA { + status = "okay"; +}; + +&EDM_I2CB { + status = "okay"; + + codec: sgtl5000@0a { + compatible = "fsl,sgtl5000"; + reg = <0x0a>; + clocks = <&EDM_AUDA_CLK_SRC>; + VDDA-supply = <®_2p5v>; + VDDIO-supply = <®_3p3v>; + }; + + egalax: egalax_i2c@2a { + compatible = "eeti,egalax_i2c"; + reg = <0x2a>; + interrupt-parent = <&GPIO_BANK(EDM_EXT_GPIO_P259)>; + interrupts = ; + int-gpios = <&EDM_EXT_GPIO_P259 GPIO_ACTIVE_LOW>; + }; +}; + +&EDM_I2CC { + status = "okay"; + + mag3110@0e { + compatible = "fsl,mag3110"; + reg = <0x0e>; + position = <2>; + vdd-supply = <®_3p3v>; + vddio-supply = <®_3p3v>; + }; + + lis331dlh: lis331dlh@18 { + compatible = "st,lis331dlh", "st,lis3lv02d"; + reg = <0x18>; + Vdd-supply = <®_3p3v>; + Vdd_IO-supply = <®_3p3v>; + + st,click-single-x; + st,click-single-y; + st,click-single-z; + st,click-thresh-x = <10>; + st,click-thresh-y = <10>; + st,click-thresh-z = <10>; + st,irq1-click; + st,irq2-click; + st,wakeup-x-lo; + st,wakeup-x-hi; + st,wakeup-y-lo; + st,wakeup-y-hi; + st,wakeup-z-lo; + st,wakeup-z-hi; + st,min-limit-x = <120>; + st,min-limit-y = <120>; + st,min-limit-z = <140>; + st,max-limit-x = <550>; + st,max-limit-y = <550>; + st,max-limit-z = <750>; + }; + + isl29023@44 { + compatible = "fsl,isl29023"; + reg = <0x44>; + rext = <499>; + }; + + ds1337: rtc@68 { + compatible = "mxim,ds1337"; + reg = <0x68>; + }; +}; + +&EDM_CANA { + status = "okay"; +}; + +&EDM_CANB { + status = "okay"; +}; + +&EDM_SPIB { + status = "okay"; + + ads7846@0 { + reg = <0>; /* CS0 */ + compatible = "ti,ads7846"; + interrupt-parent = <&GPIO_BANK(EDM_EXT_GPIO_P263)>; + interrupts = ; + spi-max-frequency = <1000000>; + pendown-gpio = <&EDM_EXT_GPIO_P263 0>; + vcc-supply = <®_3p3v>; + + ti,x-min = /bits/ 16 <0>; + ti,x-max = /bits/ 16 <4095>; + ti,y-min = /bits/ 16 <0>; + ti,y-max = /bits/ 16 <4095>; + ti,pressure-max = /bits/ 16 <1024>; + ti,x-plate-ohms = /bits/ 16 <90>; + ti,y-plate-ohms = /bits/ 16 <90>; + ti,debounce-max = /bits/ 16 <70>; + ti,debounce-tol = /bits/ 16 <3>; + ti,debounce-rep = /bits/ 16 <2>; + ti,settle-delay-usec = /bits/ 16 <150>; + + linux,wakeup; + }; +}; + +#ifdef EDM_PCIEA +&EDM_PCIEA { + #ifdef EDM_PCIEA_RESET_GPIO + reset-gpio = <&EDM_PCIEA_RESET_GPIO GPIO_ACTIVE_HIGH>; + #endif + status = "okay"; +}; +#endif + diff --git a/arch/arm/boot/dts/imx6dl-edm1_fairy.dts b/arch/arm/boot/dts/imx6dl-edm1_fairy.dts new file mode 100644 index 00000000000000..b4d6396b997289 --- /dev/null +++ b/arch/arm/boot/dts/imx6dl-edm1_fairy.dts @@ -0,0 +1,33 @@ +/* + * Copyright 2018 Technexion Ltd. + * + * Author: Tapani Utriainen + * Richard Hu + * + * 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 +#include "imx6dl.dtsi" +#include "imx6qdl-edm.dtsi" +#include "baseboard_edm1_fairy.dtsi" + +/ { + model = "TechNexion EDM1-IMX6 DualLite/Solo and FAIRY baseboard"; + compatible = "fsl,edm-imx6dl", "fsl,imx6dl"; +}; + +&ldb { + lvds-channel@0 { + crtc = "ipu1-di0"; + }; +}; + +&epdc { + status = "disabled"; +}; + diff --git a/arch/arm/boot/dts/imx6q-edm1_fairy.dts b/arch/arm/boot/dts/imx6q-edm1_fairy.dts new file mode 100644 index 00000000000000..3e8c2424afe9bb --- /dev/null +++ b/arch/arm/boot/dts/imx6q-edm1_fairy.dts @@ -0,0 +1,34 @@ +/* + * Copyright 2018 Technexion Ltd. + * + * Author: Tapani Utriainen + * Richard Hu + * + * The code contained herein is licensed under the GNU General Public + * License. You may obtain a copy of the GNU General Public License + * Version 2 or later at the following locations: + * + * http://www.opensource.org/licenses/gpl-license.html + * http://www.gnu.org/copyleft/gpl.html + */ + +/dts-v1/; +#include +#include "imx6q.dtsi" +#include "imx6qdl-edm.dtsi" +#include "baseboard_edm1_fairy.dtsi" + +/ { + model = "TechNexion EDM1-IMX6 Quad/Dual and FAIRY baseboard"; + compatible = "fsl,edm-imx6q", "fsl,imx6q"; +}; + +&ldb { + lvds-channel@0 { + crtc = "ipu2-di0"; + }; +}; + +&sata { + status = "okay"; +}; diff --git a/arch/arm/boot/dts/imx6qp-edm1_fairy.dts b/arch/arm/boot/dts/imx6qp-edm1_fairy.dts new file mode 100644 index 00000000000000..cc22764239bcd6 --- /dev/null +++ b/arch/arm/boot/dts/imx6qp-edm1_fairy.dts @@ -0,0 +1,50 @@ +/* + * Copyright 2016 Technexion Ltd. + * + * Author: Tapani Utriainen + * Richard Hu + * + * The code contained herein is licensed under the GNU General Public + * License. You may obtain a copy of the GNU General Public License + * Version 2 or later at the following locations: + * + * http://www.opensource.org/licenses/gpl-license.html + * http://www.gnu.org/copyleft/gpl.html + */ + +#include "imx6q-edm1_fairy.dts" +#include "imx6qp.dtsi" + +/ { + model = "TechNexion EDM1-IMX6 Quad Plus and FAIRY baseboard"; +}; + +&pre1 { + status = "okay"; +}; + +&pre2 { + status = "okay"; +}; + +&pre3 { + status = "okay"; +}; + +&pre4 { + status = "okay"; +}; + +&prg1 { + memory-region = <&memory>; + status = "okay"; +}; + +&prg2 { + memory-region = <&memory>; + status = "okay"; +}; + +&fec { + /delete-property/ phy-reset-gpios; +};