mbox series

[0/4] ARM: Add Variscite DART-MX6 SoM and Carrier-board support

Message ID 1511281705-30849-1-git-send-email-narmstrong@baylibre.com
Headers show
Series ARM: Add Variscite DART-MX6 SoM and Carrier-board support | expand

Message

Neil Armstrong Nov. 21, 2017, 4:28 p.m. UTC
This patchset adds support for the Variscite DART-MX6 SoM with :
- i.MX6 Quad or Dual Lite SoC
- 1Gb/2Gb LPDDR2
- 4-64 GB eMMC
- Camera Interface
- HDMI+CEC interface
- LVDS / DSI / Parallel RGB interfaces
- Ethernet RGMII interface
- On-SoM Wi-Fi/Bluetooth with WiLink wl1835 SDIO Module
- SD/MMC/SDIO interface
- USB Host + USB OTG interface
- I2C interfaces
- SPI interfaces
- PCI-Express 2.0 interface
- on-SoM Audio Codec with HP/Line-In interfaces + DMIC interface
- Digital Audio interface
- S/PDIF interface

And the Carrier-Board with the following :
- LVDS interface for the VLCD-CAP-GLD-LVDS 7" LCD 800 x 480 touch display
- HDMI Connector
- USB Host + USB OTG Connector
- 10/100/1000 Mbps Ethernet
- miniPCI-Express slot
- SD Card connector
- Audio Headphone/Line In jack connectors
- On-board DMIC
- CAN bus header
- SPI header
- Camera Interfaces header
- 4xButtons, 2xLeds
- OnBoard RTC with Coin Backup battery socket
- RS232 Header + USB-Serial debug port

First patch contains a missing pinmux define used by the SoM.
Last patch contains configs used by the SoM DT like SERDEV or WL18XX support.

On-Board DMIC and Camera Interfaces are not handled yet.

Neil Armstrong (4):
  ARM: dts: imx6qdl-pinfunc: Add missing
    MX6QDL_PAD_ENET_RXD0__OSC32K_32K_OUT
  ARM: dts: imx6qdl: Add Variscite DART-MX6 SoM support
  ARM: dts: imx6q: Add Variscite DART-MX6 Carrier-board support
  ARM: configs: Add missing config for DART-MX6 SoM

 arch/arm/boot/dts/Makefile                     |   1 +
 arch/arm/boot/dts/imx6dl-pinfunc.h             |   1 +
 arch/arm/boot/dts/imx6q-pinfunc.h              |   1 +
 arch/arm/boot/dts/imx6q-var-dt6customboard.dts | 247 ++++++++++++
 arch/arm/boot/dts/imx6qdl-var-dart.dtsi        | 510 +++++++++++++++++++++++++
 arch/arm/configs/imx_v6_v7_defconfig           |   6 +
 6 files changed, 766 insertions(+)
 create mode 100644 arch/arm/boot/dts/imx6q-var-dt6customboard.dts
 create mode 100644 arch/arm/boot/dts/imx6qdl-var-dart.dtsi

Comments

Fabio Estevam Nov. 21, 2017, 4:45 p.m. UTC | #1
On Tue, Nov 21, 2017 at 2:28 PM, Neil Armstrong <narmstrong@baylibre.com> wrote:

> +       gpio-keys {
> +               compatible = "gpio-keys";
> +               #address-cells = <1>;
> +               #size-cells = <0>;
> +               autorepeat;
> +
> +               button@0 {

If you build this with W=1 it will give you warnings about using a
unit address without its corresponding reg field.

You could just drop the @x.

> +                       gpios = <&gpio4 26 GPIO_ACTIVE_LOW>;
> +                       linux,code = <KEY_BACK>;
> +                       label = "Key Back";
> +                       linux,input-type = <1>;
> +                       debounce-interval = <100>;
> +                       gpio-key,wakeup;
> +               };
> +
> +               button@1 {
> +                       gpios = <&gpio5 11 GPIO_ACTIVE_LOW>;
> +                       linux,code = <KEY_HOME>;
> +                       label = "Key Home";
> +                       linux,input-type = <1>;
> +                       debounce-interval = <100>;
> +                       gpio-key,wakeup;
> +               };
> +
> +               button@2 {
> +                       gpios = <&gpio4 25 GPIO_ACTIVE_LOW>;
> +                       linux,code = <KEY_MENU>;
> +                       label = "Key Menu";
> +                       linux,input-type = <1>;
> +                       debounce-interval = <100>;
> +                       gpio-key,wakeup;
> +               };
> +       };

> +       panel1: lvds-panel {
> +               compatible = "sgd,gktw70sdae4se", "panel-lvds";

sgd,gktw70sdae4se is not defined anywhere.

Documentation/devicetree/bindings/display/panel/panel-lvds.txt says"

"- compatible: Shall contain "panel-lvds" in addition to a mandatory
  panel-specific compatible string defined in individual panel bindings. The
  "panel-lvds" value shall never be used on its own."

> +               backlight = <&backlight_lvds>;
> +
> +               width-mm = <153>;
> +               height-mm = <86>;
> +
> +               label = "gktw70sdae4se";
> +
> +               data-mapping = "jeida-18";
> +
> +               panel-timing {
> +                       clock-frequency = <32000000>;
> +                       hactive = <800>;
> +                       vactive = <480>;
> +                       hback-porch = <39>;
> +                       hfront-porch = <39>;
> +                       vback-porch = <29>;
> +                       vfront-porch = <13>;
> +                       hsync-len = <47>;
> +                       vsync-len = <2>;
> +               };
> +
> +               port {
> +                       panel_in: endpoint {
> +                               remote-endpoint = <&lvds1_out>;
> +                       };
> +               };
> +       };
> +
> +       reg_usb_h1_vbus: regulator-usbh1vbus {
> +               compatible = "regulator-fixed";
> +               regulator-name = "usb_h1_vbus";
> +               regulator-min-microvolt = <5000000>;
> +               regulator-max-microvolt = <5000000>;
> +               gpio = <&gpio1 28 0>;

It would be better to use:
gpio = <&gpio1 28 GPIO_ACTIVE_HIGH>;


> +               enable-active-high;
> +       };
> +
> +       reg_usb_otg_vbus: regulator-usbotgvbus {
> +               compatible = "regulator-fixed";
> +               regulator-name = "usb_otg_vbus";
> +               regulator-min-microvolt = <5000000>;
> +               regulator-max-microvolt = <5000000>;
> +               gpio = <&gpio4 15 0>;

Same here.

> +               enable-active-high;
> +       };
> +

> +
> +&fec {
> +       status = "okay";
> +       phy-mode = "rgmii";
> +       phy-reset-gpios = <&gpio1 25 0>;

GPIO_ACTIVE_LOW please.


> +};
> +
> +&hdmi {
> +       ddc-i2c-bus = <&i2c1>;
> +       status = "okay";
> +};
> +
> +&pcie {
> +       reset-gpio    = <&gpio4 11 0>;

GPIO_ACTIVE_LOW

> +       wake-up-gpio  = <&gpio4 31 1>;

This is not a valid property.

> +       disable-gpio  = <&gpio5 5 0>;

This is not a valid property.
Fabio Estevam Nov. 21, 2017, 4:54 p.m. UTC | #2
On Tue, Nov 21, 2017 at 2:28 PM, Neil Armstrong <narmstrong@baylibre.com> wrote:

> +       reg_wl18xx_vmmc: regulator-wl18xx {
> +               compatible = "regulator-fixed";
> +               regulator-name = "vwl1807";
> +               regulator-min-microvolt = <1800000>;
> +               regulator-max-microvolt = <1800000>;
> +               gpio = <&gpio7 8 0>;

GPIO_ACTIVE_HIGH please.

> +&can2 {
> +       pinctrl-names = "default";
> +       pinctrl-0 = <&pinctrl_flexcan2>;
> +       status = "disabled";
> +};
> +
> +&cpu0 {
> +       arm-supply = <&sw1a_reg>;
> +       soc-supply = <&sw1c_reg>;
> +       operating-points = <
> +               /* kHz    uV */
> +               1200000 1350000
> +               996000  1250000
> +               852000  1250000
> +               792000  1175000
> +               396000  1175000
> +       >;
> +       fsl,soc-operating-points = <
> +               /* ARM kHz  SOC-PU uV */
> +               1200000 1275000
> +               996000  1250000
> +               852000  1250000
> +               792000  1175000
> +               396000  1175000
> +       >;


Don't the standard operating points described at imx6q.dtsi work on this board?

If not, please add a comment explaining why you need custom operating
points here.

> +       pinctrl_flexcan1: flexcan1grp {
> +               fsl,pins = <
> +                       MX6QDL_PAD_GPIO_7__FLEXCAN1_TX          0x80000000
> +                       MX6QDL_PAD_GPIO_8__FLEXCAN1_RX          0x80000000

Please avoid 0x80000000 and use the real IOMUX values instead.

> +               >;
> +       };
> +
> +       pinctrl_flexcan2: flexcan2grp {
> +               fsl,pins = <
> +                       MX6QDL_PAD_KEY_COL4__FLEXCAN2_TX        0x80000000
> +                       MX6QDL_PAD_KEY_ROW4__FLEXCAN2_RX        0x80000000

Please avoid 0x80000000 and use the real IOMUX values instead.
Fabio Estevam Nov. 21, 2017, 4:59 p.m. UTC | #3
On Tue, Nov 21, 2017 at 2:28 PM, Neil Armstrong <narmstrong@baylibre.com> wrote:
> Add missing pinmux entry for OSC32K_32K_OUT on pad ENET_RXD0 used by the
> Variscite DART-MX6 SoM.
>
> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>

Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>
Neil Armstrong Nov. 22, 2017, 9:14 a.m. UTC | #4
Hi Fabio,

On 21/11/2017 17:54, Fabio Estevam wrote:
> On Tue, Nov 21, 2017 at 2:28 PM, Neil Armstrong <narmstrong@baylibre.com> wrote:
> 
>> +       reg_wl18xx_vmmc: regulator-wl18xx {
>> +               compatible = "regulator-fixed";
>> +               regulator-name = "vwl1807";
>> +               regulator-min-microvolt = <1800000>;
>> +               regulator-max-microvolt = <1800000>;
>> +               gpio = <&gpio7 8 0>;
> 
> GPIO_ACTIVE_HIGH please.

OK

> 
>> +&can2 {
>> +       pinctrl-names = "default";
>> +       pinctrl-0 = <&pinctrl_flexcan2>;
>> +       status = "disabled";
>> +};
>> +
>> +&cpu0 {
>> +       arm-supply = <&sw1a_reg>;
>> +       soc-supply = <&sw1c_reg>;
>> +       operating-points = <
>> +               /* kHz    uV */
>> +               1200000 1350000
>> +               996000  1250000
>> +               852000  1250000
>> +               792000  1175000
>> +               396000  1175000
>> +       >;
>> +       fsl,soc-operating-points = <
>> +               /* ARM kHz  SOC-PU uV */
>> +               1200000 1275000
>> +               996000  1250000
>> +               852000  1250000
>> +               792000  1175000
>> +               396000  1175000
>> +       >;
> 
> 
> Don't the standard operating points described at imx6q.dtsi work on this board?
> 
> If not, please add a comment explaining why you need custom operating
> points here.

It should, I will remove them, anyway it will conflict with the ones in imx6dl.dtsi.

> 
>> +       pinctrl_flexcan1: flexcan1grp {
>> +               fsl,pins = <
>> +                       MX6QDL_PAD_GPIO_7__FLEXCAN1_TX          0x80000000
>> +                       MX6QDL_PAD_GPIO_8__FLEXCAN1_RX          0x80000000
> 
> Please avoid 0x80000000 and use the real IOMUX values instead.

Ok, will replace with 0x1b0b0

> 
>> +               >;
>> +       };
>> +
>> +       pinctrl_flexcan2: flexcan2grp {
>> +               fsl,pins = <
>> +                       MX6QDL_PAD_KEY_COL4__FLEXCAN2_TX        0x80000000
>> +                       MX6QDL_PAD_KEY_ROW4__FLEXCAN2_RX        0x80000000
> 
> Please avoid 0x80000000 and use the real IOMUX values instead.
> 

Same here.

Thanks,
Neil
Neil Armstrong Nov. 22, 2017, 10:51 a.m. UTC | #5
Hi Fabio,

On 21/11/2017 17:45, Fabio Estevam wrote:
> On Tue, Nov 21, 2017 at 2:28 PM, Neil Armstrong <narmstrong@baylibre.com> wrote:
> 
>> +       gpio-keys {
>> +               compatible = "gpio-keys";
>> +               #address-cells = <1>;
>> +               #size-cells = <0>;
>> +               autorepeat;
>> +
>> +               button@0 {
> 
> If you build this with W=1 it will give you warnings about using a
> unit address without its corresponding reg field.
> 
> You could just drop the @x.

Ok

> 
>> +                       gpios = <&gpio4 26 GPIO_ACTIVE_LOW>;
>> +                       linux,code = <KEY_BACK>;
>> +                       label = "Key Back";
>> +                       linux,input-type = <1>;
>> +                       debounce-interval = <100>;
>> +                       gpio-key,wakeup;
>> +               };
>> +
>> +               button@1 {
>> +                       gpios = <&gpio5 11 GPIO_ACTIVE_LOW>;
>> +                       linux,code = <KEY_HOME>;
>> +                       label = "Key Home";
>> +                       linux,input-type = <1>;
>> +                       debounce-interval = <100>;
>> +                       gpio-key,wakeup;
>> +               };
>> +
>> +               button@2 {
>> +                       gpios = <&gpio4 25 GPIO_ACTIVE_LOW>;
>> +                       linux,code = <KEY_MENU>;
>> +                       label = "Key Menu";
>> +                       linux,input-type = <1>;
>> +                       debounce-interval = <100>;
>> +                       gpio-key,wakeup;
>> +               };
>> +       };
> 
>> +       panel1: lvds-panel {
>> +               compatible = "sgd,gktw70sdae4se", "panel-lvds";
> 
> sgd,gktw70sdae4se is not defined anywhere.
> 
> Documentation/devicetree/bindings/display/panel/panel-lvds.txt says"
> 
> "- compatible: Shall contain "panel-lvds" in addition to a mandatory
>   panel-specific compatible string defined in individual panel bindings. The
>   "panel-lvds" value shall never be used on its own."
> 

Ok add vendor prefix and bindings.

>> +               backlight = <&backlight_lvds>;
>> +
>> +               width-mm = <153>;
>> +               height-mm = <86>;
>> +
>> +               label = "gktw70sdae4se";
>> +
>> +               data-mapping = "jeida-18";
>> +
>> +               panel-timing {
>> +                       clock-frequency = <32000000>;
>> +                       hactive = <800>;
>> +                       vactive = <480>;
>> +                       hback-porch = <39>;
>> +                       hfront-porch = <39>;
>> +                       vback-porch = <29>;
>> +                       vfront-porch = <13>;
>> +                       hsync-len = <47>;
>> +                       vsync-len = <2>;
>> +               };
>> +
>> +               port {
>> +                       panel_in: endpoint {
>> +                               remote-endpoint = <&lvds1_out>;
>> +                       };
>> +               };
>> +       };
>> +
>> +       reg_usb_h1_vbus: regulator-usbh1vbus {
>> +               compatible = "regulator-fixed";
>> +               regulator-name = "usb_h1_vbus";
>> +               regulator-min-microvolt = <5000000>;
>> +               regulator-max-microvolt = <5000000>;
>> +               gpio = <&gpio1 28 0>;
> 
> It would be better to use:
> gpio = <&gpio1 28 GPIO_ACTIVE_HIGH>;

Ok

> 
> 
>> +               enable-active-high;
>> +       };
>> +
>> +       reg_usb_otg_vbus: regulator-usbotgvbus {
>> +               compatible = "regulator-fixed";
>> +               regulator-name = "usb_otg_vbus";
>> +               regulator-min-microvolt = <5000000>;
>> +               regulator-max-microvolt = <5000000>;
>> +               gpio = <&gpio4 15 0>;
> 
> Same here.

Ok

> 
>> +               enable-active-high;
>> +       };
>> +
> 
>> +
>> +&fec {
>> +       status = "okay";
>> +       phy-mode = "rgmii";
>> +       phy-reset-gpios = <&gpio1 25 0>;
> 
> GPIO_ACTIVE_LOW please.

Ok

> 
> 
>> +};
>> +
>> +&hdmi {
>> +       ddc-i2c-bus = <&i2c1>;
>> +       status = "okay";
>> +};
>> +
>> +&pcie {
>> +       reset-gpio    = <&gpio4 11 0>;
> 
> GPIO_ACTIVE_LOW
> 
>> +       wake-up-gpio  = <&gpio4 31 1>;
> 
> This is not a valid property.
> 
>> +       disable-gpio  = <&gpio5 5 0>;
> 
> This is not a valid property.
> 

I will drop pcie for now until I figure out the requirements for these 2 gpios.

Thanks,
Neil