diff mbox series

[1/2] ARM: dts: am3517-evm: Sync DTS with Linux 5.17-rc5

Message ID 20220226211724.742506-1-aford173@gmail.com
State Accepted
Commit 72ce7818f9ebc9b01f90c174a797901f8b0840a9
Delegated to: Tom Rini
Headers show
Series [1/2] ARM: dts: am3517-evm: Sync DTS with Linux 5.17-rc5 | expand

Commit Message

Adam Ford Feb. 26, 2022, 9:17 p.m. UTC
Sync the am3517-evm device tree files with those from Linux
5.17-rc5 with some additional fixes for pinmuxing Ethernet and
moving the pinmux references to the respective peripherals.

Signed-off-by: Adam Ford <aford173@gmail.com>

Comments

Derald Woods Feb. 27, 2022, 1:55 a.m. UTC | #1
On Sat, Feb 26, 2022 at 3:17 PM Adam Ford <aford173@gmail.com> wrote:

> Sync the am3517-evm device tree files with those from Linux
> 5.17-rc5 with some additional fixes for pinmuxing Ethernet and
> moving the pinmux references to the respective peripherals.
>
> Signed-off-by: Adam Ford <aford173@gmail.com>
>
> diff --git a/arch/arm/dts/am3517-evm-u-boot.dtsi
> b/arch/arm/dts/am3517-evm-u-boot.dtsi
> index d5a4ce97d1..1a70630322 100644
> --- a/arch/arm/dts/am3517-evm-u-boot.dtsi
> +++ b/arch/arm/dts/am3517-evm-u-boot.dtsi
> @@ -37,7 +37,18 @@
>         /delete-property/ u-boot,dm-spl;
>  };
>
> -/delete-node/ &uart1;
> -/delete-node/ &uart2;
> -/delete-node/ &mmc2;
> -/delete-node/ &mmc3;
> +&mmc2 {
> +       /delete-property/ u-boot,dm-spl;
> +};
> +
> +&mmc3 {
> +       /delete-property/ u-boot,dm-spl;
> +};
> +
> +&uart1 {
> +       /delete-property/ u-boot,dm-spl;
> +};
> +
> +&uart2 {
> +       /delete-property/ u-boot,dm-spl;
> +};
> diff --git a/arch/arm/dts/am3517-evm-ui.dtsi
> b/arch/arm/dts/am3517-evm-ui.dtsi
> index 54aa2522aa..7d8f32bf70 100644
> --- a/arch/arm/dts/am3517-evm-ui.dtsi
> +++ b/arch/arm/dts/am3517-evm-ui.dtsi
> @@ -1,9 +1,6 @@
> +// SPDX-License-Identifier: GPL-2.0-only
>  /*
> - * Copyright (C) 2018 Logic PD, Inc - http://www.logicpd.com/
> - *
> - * 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.
> + * Copyright (C) 2018 Logic PD, Inc - https://www.logicpd.com/
>   */
>
>  #include <dt-bindings/input/input.h>
> diff --git a/arch/arm/dts/am3517-evm.dts b/arch/arm/dts/am3517-evm.dts
> index 935c471c97..a01f9cf047 100644
> --- a/arch/arm/dts/am3517-evm.dts
> +++ b/arch/arm/dts/am3517-evm.dts
> @@ -1,9 +1,6 @@
> +// SPDX-License-Identifier: GPL-2.0-only
>  /*
> - * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/
> - *
> - * 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.
> + * Copyright (C) 2011 Texas Instruments Incorporated -
> https://www.ti.com/
>   */
>  /dts-v1/;
>
> @@ -127,10 +124,11 @@
>         };
>
>         lcd0: display@0 {
> -               compatible = "panel-dpi";
> +               /* This isn't the exact LCD, but the timings meet spec */
> +               /* To make it work, set CONFIG_OMAP2_DSS_MIN_FCK_PER_PCK=4
> */
> +               compatible = "newhaven,nhd-4.3-480272ef-atxl";
>                 label = "15";
> -               status = "okay";
> -               pinctrl-names = "default";
> +               backlight = <&bl>;
>                 enable-gpios = <&gpio6 16 GPIO_ACTIVE_HIGH>;    /*
> gpio176, lcd INI */
>                 vcc-supply = <&vdd_io_reg>;
>
> @@ -139,22 +137,6 @@
>                                 remote-endpoint = <&dpi_out>;
>                         };
>                 };
> -
> -               panel-timing {
> -                       clock-frequency = <9000000>;
> -                       hactive = <480>;
> -                       vactive = <272>;
> -                       hfront-porch = <3>;
> -                       hback-porch = <2>;
> -                       hsync-len = <42>;
> -                       vback-porch = <3>;
> -                       vfront-porch = <4>;
> -                       vsync-len = <11>;
> -                       hsync-active = <0>;
> -                       vsync-active = <0>;
> -                       de-active = <1>;
> -                       pixelclk-active = <1>;
> -               };
>         };
>
>         bl: backlight {
> @@ -174,10 +156,13 @@
>                 pinctrl-0 = <&pwm_pins>;
>                 ti,timers = <&timer11>;
>                 #pwm-cells = <3>;
> +               ti,clock-source = <0x01>;
>         };
>
>         /* HS USB Host PHY on PORT 1 */
>         hsusb1_phy: hsusb1_phy {
> +               pinctrl-names = "default";
> +               pinctrl-0 = <&hsusb1_rst_pins>;
>                 compatible = "usb-nop-xceiv";
>                 reset-gpios = <&gpio2 25 GPIO_ACTIVE_LOW>; /* gpio_57 */
>                 #phy-cells = <0>;
> @@ -185,7 +170,9 @@
>  };
>
>  &davinci_emac {
> -            status = "okay";
> +       pinctrl-names = "default";
> +       pinctrl-0 = <&ethernet_pins>;
> +       status = "okay";
>  };
>
>  &davinci_mdio {
> @@ -240,6 +227,8 @@
>  };
>
>  &usbhshost {
> +       pinctrl-names = "default";
> +       pinctrl-0 = <&hsusb1_pins>;
>         port1-mode = "ehci-phy";
>  };
>
> @@ -248,8 +237,21 @@
>  };
>
>  &omap3_pmx_core {
> -       pinctrl-names = "default";
> -       pinctrl-0 = <&hsusb1_rst_pins>;
> +
> +       ethernet_pins: pinmux_ethernet_pins {
> +               pinctrl-single,pins = <
> +                       OMAP3_CORE1_IOPAD(0x21fe, PIN_INPUT | MUX_MODE0)
> /* rmii_mdio_data */
> +                       OMAP3_CORE1_IOPAD(0x2200, MUX_MODE0) /*
> rmii_mdio_clk */
> +                       OMAP3_CORE1_IOPAD(0x2202, PIN_INPUT_PULLDOWN |
> MUX_MODE0) /* rmii_rxd0 */
> +                       OMAP3_CORE1_IOPAD(0x2204, PIN_INPUT_PULLDOWN |
> MUX_MODE0) /* rmii_rxd1 */
> +                       OMAP3_CORE1_IOPAD(0x2206, PIN_INPUT_PULLDOWN |
> MUX_MODE0) /* rmii_crs_dv */
> +                       OMAP3_CORE1_IOPAD(0x2208, PIN_OUTPUT_PULLDOWN |
> MUX_MODE0) /* rmii_rxer */
> +                       OMAP3_CORE1_IOPAD(0x220a, PIN_OUTPUT_PULLDOWN |
> MUX_MODE0) /* rmii_txd0 */
> +                       OMAP3_CORE1_IOPAD(0x220c, PIN_OUTPUT_PULLDOWN |
> MUX_MODE0) /* rmii_txd1 */
> +                       OMAP3_CORE1_IOPAD(0x220e, PIN_OUTPUT_PULLDOWN
> |MUX_MODE0) /* rmii_txen */
> +                       OMAP3_CORE1_IOPAD(0x2210, PIN_INPUT_PULLDOWN |
> MUX_MODE0) /* rmii_50mhz_clk */
> +               >;
> +       };
>
>         leds_pins: pinmux_leds_pins {
>                 pinctrl-single,pins = <
> @@ -317,8 +319,6 @@
>  };
>
>  &omap3_pmx_core2 {
> -       pinctrl-names = "default";
> -       pinctrl-0 = <&hsusb1_pins>;
>
>         hsusb1_pins: pinmux_hsusb1_pins {
>                 pinctrl-single,pins = <
> diff --git a/arch/arm/dts/am3517-som.dtsi b/arch/arm/dts/am3517-som.dtsi
> index b1c988eed8..8b669e2eaf 100644
> --- a/arch/arm/dts/am3517-som.dtsi
> +++ b/arch/arm/dts/am3517-som.dtsi
> @@ -1,11 +1,8 @@
> +// SPDX-License-Identifier: GPL-2.0-only
>  /*
>   * Copyright (C) 2016 Derald D. Woods <woods.technical@gmail.com>
>   *
>   * Based on am3517-evm.dts
> - *
> - * 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.
>   */
>
>  / {
> --
> 2.34.1
>
>
Works on AM3517 Zoom eXperimenter.

Tested-by: Derald D. Woods <woods.technical@gmail.com>
Tom Rini March 14, 2022, 1:08 p.m. UTC | #2
On Sat, Feb 26, 2022 at 03:17:23PM -0600, Adam Ford wrote:

> Sync the am3517-evm device tree files with those from Linux
> 5.17-rc5 with some additional fixes for pinmuxing Ethernet and
> moving the pinmux references to the respective peripherals.
> 
> Signed-off-by: Adam Ford <aford173@gmail.com>
> Tested-by: Derald D. Woods <woods.technical@gmail.com>
> 
> diff --git a/arch/arm/dts/am3517-evm-u-boot.dtsi b/arch/arm/dts/am3517-evm-u-boot.dtsi
> index d5a4ce97d1..1a70630322 100644

Applied to u-boot/next, thanks!
diff mbox series

Patch

diff --git a/arch/arm/dts/am3517-evm-u-boot.dtsi b/arch/arm/dts/am3517-evm-u-boot.dtsi
index d5a4ce97d1..1a70630322 100644
--- a/arch/arm/dts/am3517-evm-u-boot.dtsi
+++ b/arch/arm/dts/am3517-evm-u-boot.dtsi
@@ -37,7 +37,18 @@ 
 	/delete-property/ u-boot,dm-spl;
 };
 
-/delete-node/ &uart1;
-/delete-node/ &uart2;
-/delete-node/ &mmc2;
-/delete-node/ &mmc3;
+&mmc2 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&mmc3 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&uart1 {
+	/delete-property/ u-boot,dm-spl;
+};
+
+&uart2 {
+	/delete-property/ u-boot,dm-spl;
+};
diff --git a/arch/arm/dts/am3517-evm-ui.dtsi b/arch/arm/dts/am3517-evm-ui.dtsi
index 54aa2522aa..7d8f32bf70 100644
--- a/arch/arm/dts/am3517-evm-ui.dtsi
+++ b/arch/arm/dts/am3517-evm-ui.dtsi
@@ -1,9 +1,6 @@ 
+// SPDX-License-Identifier: GPL-2.0-only
 /*
- * Copyright (C) 2018 Logic PD, Inc - http://www.logicpd.com/
- *
- * 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.
+ * Copyright (C) 2018 Logic PD, Inc - https://www.logicpd.com/
  */
 
 #include <dt-bindings/input/input.h>
diff --git a/arch/arm/dts/am3517-evm.dts b/arch/arm/dts/am3517-evm.dts
index 935c471c97..a01f9cf047 100644
--- a/arch/arm/dts/am3517-evm.dts
+++ b/arch/arm/dts/am3517-evm.dts
@@ -1,9 +1,6 @@ 
+// SPDX-License-Identifier: GPL-2.0-only
 /*
- * Copyright (C) 2011 Texas Instruments Incorporated - http://www.ti.com/
- *
- * 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.
+ * Copyright (C) 2011 Texas Instruments Incorporated - https://www.ti.com/
  */
 /dts-v1/;
 
@@ -127,10 +124,11 @@ 
 	};
 
 	lcd0: display@0 {
-		compatible = "panel-dpi";
+		/* This isn't the exact LCD, but the timings meet spec */
+		/* To make it work, set CONFIG_OMAP2_DSS_MIN_FCK_PER_PCK=4 */
+		compatible = "newhaven,nhd-4.3-480272ef-atxl";
 		label = "15";
-		status = "okay";
-		pinctrl-names = "default";
+		backlight = <&bl>;
 		enable-gpios = <&gpio6 16 GPIO_ACTIVE_HIGH>;	/* gpio176, lcd INI */
 		vcc-supply = <&vdd_io_reg>;
 
@@ -139,22 +137,6 @@ 
 				remote-endpoint = <&dpi_out>;
 			};
 		};
-
-		panel-timing {
-			clock-frequency = <9000000>;
-			hactive = <480>;
-			vactive = <272>;
-			hfront-porch = <3>;
-			hback-porch = <2>;
-			hsync-len = <42>;
-			vback-porch = <3>;
-			vfront-porch = <4>;
-			vsync-len = <11>;
-			hsync-active = <0>;
-			vsync-active = <0>;
-			de-active = <1>;
-			pixelclk-active = <1>;
-		};
 	};
 
 	bl: backlight {
@@ -174,10 +156,13 @@ 
 		pinctrl-0 = <&pwm_pins>;
 		ti,timers = <&timer11>;
 		#pwm-cells = <3>;
+		ti,clock-source = <0x01>;
 	};
 
 	/* HS USB Host PHY on PORT 1 */
 	hsusb1_phy: hsusb1_phy {
+		pinctrl-names = "default";
+		pinctrl-0 = <&hsusb1_rst_pins>;
 		compatible = "usb-nop-xceiv";
 		reset-gpios = <&gpio2 25 GPIO_ACTIVE_LOW>; /* gpio_57 */
 		#phy-cells = <0>;
@@ -185,7 +170,9 @@ 
 };
 
 &davinci_emac {
-	     status = "okay";
+	pinctrl-names = "default";
+	pinctrl-0 = <&ethernet_pins>;
+	status = "okay";
 };
 
 &davinci_mdio {
@@ -240,6 +227,8 @@ 
 };
 
 &usbhshost {
+	pinctrl-names = "default";
+	pinctrl-0 = <&hsusb1_pins>;
 	port1-mode = "ehci-phy";
 };
 
@@ -248,8 +237,21 @@ 
 };
 
 &omap3_pmx_core {
-	pinctrl-names = "default";
-	pinctrl-0 = <&hsusb1_rst_pins>;
+
+	ethernet_pins: pinmux_ethernet_pins {
+		pinctrl-single,pins = <
+			OMAP3_CORE1_IOPAD(0x21fe, PIN_INPUT | MUX_MODE0) /* rmii_mdio_data */
+			OMAP3_CORE1_IOPAD(0x2200, MUX_MODE0) /* rmii_mdio_clk */
+			OMAP3_CORE1_IOPAD(0x2202, PIN_INPUT_PULLDOWN | MUX_MODE0) /* rmii_rxd0 */
+			OMAP3_CORE1_IOPAD(0x2204, PIN_INPUT_PULLDOWN | MUX_MODE0) /* rmii_rxd1 */
+			OMAP3_CORE1_IOPAD(0x2206, PIN_INPUT_PULLDOWN | MUX_MODE0) /* rmii_crs_dv */
+			OMAP3_CORE1_IOPAD(0x2208, PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* rmii_rxer */
+			OMAP3_CORE1_IOPAD(0x220a, PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* rmii_txd0 */
+			OMAP3_CORE1_IOPAD(0x220c, PIN_OUTPUT_PULLDOWN | MUX_MODE0) /* rmii_txd1 */
+			OMAP3_CORE1_IOPAD(0x220e, PIN_OUTPUT_PULLDOWN |MUX_MODE0) /* rmii_txen */
+			OMAP3_CORE1_IOPAD(0x2210, PIN_INPUT_PULLDOWN | MUX_MODE0) /* rmii_50mhz_clk */
+		>;
+	};
 
 	leds_pins: pinmux_leds_pins {
 		pinctrl-single,pins = <
@@ -317,8 +319,6 @@ 
 };
 
 &omap3_pmx_core2 {
-	pinctrl-names = "default";
-	pinctrl-0 = <&hsusb1_pins>;
 
 	hsusb1_pins: pinmux_hsusb1_pins {
 		pinctrl-single,pins = <
diff --git a/arch/arm/dts/am3517-som.dtsi b/arch/arm/dts/am3517-som.dtsi
index b1c988eed8..8b669e2eaf 100644
--- a/arch/arm/dts/am3517-som.dtsi
+++ b/arch/arm/dts/am3517-som.dtsi
@@ -1,11 +1,8 @@ 
+// SPDX-License-Identifier: GPL-2.0-only
 /*
  * Copyright (C) 2016 Derald D. Woods <woods.technical@gmail.com>
  *
  * Based on am3517-evm.dts
- *
- * 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.
  */
 
 / {