[PATCH v2 1/3] ARM: dts: imx6: Add Savageboard common file

2016-12-05 Thread Milo Kim
* Memory
  memblock for DDR3 1GB

* Regulator
  3.3V for panel and backlight.

* Display
  Enable HDMI and LVDS panel. Savageboard supports AVIC TM097TDH02 panel
  which is compatible with Hannstar HSD100PXN1, so reuse it.

* Clock
  The commit d28be499c45e6 is applied to support LVDS and HDMI output
  simultaneously.

* Pinmux
  eMMC, ethernet, HDMI, I2C, power button, PWM, SD card and UART.

* Others
  Enable ethernet, UART1 debug, USB host, USDHC3 for microSD card and
  USDHC4 for built-in eMMC storage.

Signed-off-by: Milo Kim 
---
 arch/arm/boot/dts/imx6qdl-savageboard.dtsi | 262 +
 1 file changed, 262 insertions(+)
 create mode 100644 arch/arm/boot/dts/imx6qdl-savageboard.dtsi

diff --git a/arch/arm/boot/dts/imx6qdl-savageboard.dtsi 
b/arch/arm/boot/dts/imx6qdl-savageboard.dtsi
new file mode 100644
index 000..a7a7e1d
--- /dev/null
+++ b/arch/arm/boot/dts/imx6qdl-savageboard.dtsi
@@ -0,0 +1,262 @@
+/*
+ * Copyright (C) 2016 Milo Kim 
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file 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.
+ *
+ * This file is distributed in the hope that it will be useful
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED , WITHOUT WARRANTY OF ANY KIND
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+#include 
+#include 
+
+/ {
+   chosen {
+   stdout-path = 
+   };
+
+   memory@1000 {
+   device_type = "memory";
+   reg = <0x1000 0x4000>;
+   };
+
+   backlight: panel_bl {
+   compatible = "pwm-backlight";
+   brightness-levels = <0 4 8 16 32 64 128 255>;
+   default-brightness-level = <4>;
+   power-supply = <_3p3v>;
+   pwms = < 0 1>;
+   };
+
+   gpio-keys {
+   compatible = "gpio-keys";
+   pinctrl-names = "default";
+   pinctrl-0 = <_gpio_keys>;
+
+   power {
+   gpios = < 7 GPIO_ACTIVE_LOW>;
+   label = "Power Button";
+   linux,code = ;
+   wakeup-source;
+   };
+   };
+
+   panel {
+   compatible = "avic, tm097tdh02", "hannstar,hsd100pxn1";
+   backlight = <>;
+   power-supply = <_3p3v>;
+
+   port {
+   panel_in: endpoint {
+   remote-endpoint = <_out>;
+   };
+   };
+   };
+
+   reg_3p3v: regulator-3p3v {
+   compatible = "regulator-fixed";
+   regulator-name = "3P3V";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   regulator-always-on;
+   };
+};
+
+ {
+   assigned-clocks = < IMX6QDL_CLK_LDB_DI0_SEL>,
+ < IMX6QDL_CLK_LDB_DI1_SEL>;
+   assigned-clock-parents = < IMX6QDL_CLK_PLL3_USB_OTG>,
+< IMX6QDL_CLK_PLL3_USB_OTG>;
+};
+
+ {
+   phy-mode = "rgmii";
+   phy-reset-gpios = < 25 GPIO_ACTIVE_LOW>;
+   pinctrl-names = "default";
+   pinctrl-0 = <_enet>;
+   status = "okay";
+};
+
+ {
+   ddc-i2c-bus = <>;
+   pinctrl-names = "default";
+   pinctrl-0 = <_hdmi_tx_cec>;
+   status = "okay";
+};
+
+ {
+   

[PATCH v2 1/3] ARM: dts: imx6: Add Savageboard common file

2016-12-05 Thread Milo Kim
* Memory
  memblock for DDR3 1GB

* Regulator
  3.3V for panel and backlight.

* Display
  Enable HDMI and LVDS panel. Savageboard supports AVIC TM097TDH02 panel
  which is compatible with Hannstar HSD100PXN1, so reuse it.

* Clock
  The commit d28be499c45e6 is applied to support LVDS and HDMI output
  simultaneously.

* Pinmux
  eMMC, ethernet, HDMI, I2C, power button, PWM, SD card and UART.

* Others
  Enable ethernet, UART1 debug, USB host, USDHC3 for microSD card and
  USDHC4 for built-in eMMC storage.

Signed-off-by: Milo Kim 
---
 arch/arm/boot/dts/imx6qdl-savageboard.dtsi | 262 +
 1 file changed, 262 insertions(+)
 create mode 100644 arch/arm/boot/dts/imx6qdl-savageboard.dtsi

diff --git a/arch/arm/boot/dts/imx6qdl-savageboard.dtsi 
b/arch/arm/boot/dts/imx6qdl-savageboard.dtsi
new file mode 100644
index 000..a7a7e1d
--- /dev/null
+++ b/arch/arm/boot/dts/imx6qdl-savageboard.dtsi
@@ -0,0 +1,262 @@
+/*
+ * Copyright (C) 2016 Milo Kim 
+ *
+ * This file is dual-licensed: you can use it either under the terms
+ * of the GPL or the X11 license, at your option. Note that this dual
+ * licensing only applies to this file, and not this project as a
+ * whole.
+ *
+ *  a) This file 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.
+ *
+ * This file is distributed in the hope that it will be useful
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * Or, alternatively
+ *
+ *  b) Permission is hereby granted, free of charge, to any person
+ * obtaining a copy of this software and associated documentation
+ * files (the "Software"), to deal in the Software without
+ * restriction, including without limitation the rights to use
+ * copy, modify, merge, publish, distribute, sublicense, and/or
+ * sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following
+ * conditions:
+ *
+ * The above copyright notice and this permission notice shall be
+ * included in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED , WITHOUT WARRANTY OF ANY KIND
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+ * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+ * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+ * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+#include 
+#include 
+
+/ {
+   chosen {
+   stdout-path = 
+   };
+
+   memory@1000 {
+   device_type = "memory";
+   reg = <0x1000 0x4000>;
+   };
+
+   backlight: panel_bl {
+   compatible = "pwm-backlight";
+   brightness-levels = <0 4 8 16 32 64 128 255>;
+   default-brightness-level = <4>;
+   power-supply = <_3p3v>;
+   pwms = < 0 1>;
+   };
+
+   gpio-keys {
+   compatible = "gpio-keys";
+   pinctrl-names = "default";
+   pinctrl-0 = <_gpio_keys>;
+
+   power {
+   gpios = < 7 GPIO_ACTIVE_LOW>;
+   label = "Power Button";
+   linux,code = ;
+   wakeup-source;
+   };
+   };
+
+   panel {
+   compatible = "avic, tm097tdh02", "hannstar,hsd100pxn1";
+   backlight = <>;
+   power-supply = <_3p3v>;
+
+   port {
+   panel_in: endpoint {
+   remote-endpoint = <_out>;
+   };
+   };
+   };
+
+   reg_3p3v: regulator-3p3v {
+   compatible = "regulator-fixed";
+   regulator-name = "3P3V";
+   regulator-min-microvolt = <330>;
+   regulator-max-microvolt = <330>;
+   regulator-always-on;
+   };
+};
+
+ {
+   assigned-clocks = < IMX6QDL_CLK_LDB_DI0_SEL>,
+ < IMX6QDL_CLK_LDB_DI1_SEL>;
+   assigned-clock-parents = < IMX6QDL_CLK_PLL3_USB_OTG>,
+< IMX6QDL_CLK_PLL3_USB_OTG>;
+};
+
+ {
+   phy-mode = "rgmii";
+   phy-reset-gpios = < 25 GPIO_ACTIVE_LOW>;
+   pinctrl-names = "default";
+   pinctrl-0 = <_enet>;
+   status = "okay";
+};
+
+ {
+   ddc-i2c-bus = <>;
+   pinctrl-names = "default";
+   pinctrl-0 = <_hdmi_tx_cec>;
+   status = "okay";
+};
+
+ {
+   clock-frequency = <10>;
+   pinctrl-names =