linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/3] arm64: dts: mt8183: add dpi node to mt8183
@ 2021-11-10 19:24 Fabien Parent
  2021-11-10 19:24 ` [PATCH 2/3] arm64: dts: mediatek: mt8183-pumpkin: add HDMI support Fabien Parent
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Fabien Parent @ 2021-11-10 19:24 UTC (permalink / raw)
  To: Rob Herring, Matthias Brugger
  Cc: Pi-Hsun Shih, Jitao Shi, Fabien Parent, devicetree,
	linux-arm-kernel, linux-mediatek, linux-kernel

From: Pi-Hsun Shih <pihsun@chromium.org>

Add dpi node to mt8183.

Signed-off-by: Jitao Shi <jitao.shi@mediatek.com>
Signed-off-by: Pi-Hsun Shih <pihsun@chromium.org>
Signed-off-by: Fabien Parent <fparent@baylibre.com>
---
 arch/arm64/boot/dts/mediatek/mt8183.dtsi | 11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/arch/arm64/boot/dts/mediatek/mt8183.dtsi b/arch/arm64/boot/dts/mediatek/mt8183.dtsi
index ba4584faca5a..7c283c0b68b5 100644
--- a/arch/arm64/boot/dts/mediatek/mt8183.dtsi
+++ b/arch/arm64/boot/dts/mediatek/mt8183.dtsi
@@ -1443,6 +1443,17 @@ dsi0: dsi@14014000 {
 			phy-names = "dphy";
 		};
 
+		dpi0: dpi@14015000 {
+			compatible = "mediatek,mt8183-dpi";
+			reg = <0 0x14015000 0 0x1000>;
+			interrupts = <GIC_SPI 237 IRQ_TYPE_LEVEL_LOW>;
+			power-domains = <&spm MT8183_POWER_DOMAIN_DISP>;
+			clocks = <&mmsys CLK_MM_DPI_IF>,
+				 <&mmsys CLK_MM_DPI_MM>,
+				 <&apmixedsys CLK_APMIXED_TVDPLL>;
+			clock-names = "pixel", "engine", "pll";
+		};
+
 		mutex: mutex@14016000 {
 			compatible = "mediatek,mt8183-disp-mutex";
 			reg = <0 0x14016000 0 0x1000>;
-- 
2.33.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 2/3] arm64: dts: mediatek: mt8183-pumpkin: add HDMI support
  2021-11-10 19:24 [PATCH 1/3] arm64: dts: mt8183: add dpi node to mt8183 Fabien Parent
@ 2021-11-10 19:24 ` Fabien Parent
  2021-11-10 19:24 ` [PATCH 3/3] arm64: dts: mediatek: mt8183-pumpkin: add USB host support Fabien Parent
  2021-11-17 17:33 ` [PATCH 1/3] arm64: dts: mt8183: add dpi node to mt8183 Matthias Brugger
  2 siblings, 0 replies; 6+ messages in thread
From: Fabien Parent @ 2021-11-10 19:24 UTC (permalink / raw)
  To: Rob Herring, Matthias Brugger
  Cc: Fabien Parent, devicetree, linux-arm-kernel, linux-mediatek,
	linux-kernel

The MT8183 Pumpkin board has a micro-HDMI connector. HDMI support is
provided by an IT66121 DPI <-> HDMI bridge.

This commit enables DPI and add the node for the IT66121 bridge.

Signed-off-by: Fabien Parent <fparent@baylibre.com>
---
 .../boot/dts/mediatek/mt8183-pumpkin.dts      | 115 ++++++++++++++++++
 1 file changed, 115 insertions(+)

diff --git a/arch/arm64/boot/dts/mediatek/mt8183-pumpkin.dts b/arch/arm64/boot/dts/mediatek/mt8183-pumpkin.dts
index ee912825cfc6..d5a6628e9c5b 100644
--- a/arch/arm64/boot/dts/mediatek/mt8183-pumpkin.dts
+++ b/arch/arm64/boot/dts/mediatek/mt8183-pumpkin.dts
@@ -62,6 +62,18 @@ ntc {
 		pulldown-ohm = <0>;
 		io-channels = <&auxadc 0>;
 	};
+
+	connector {
+		compatible = "hdmi-connector";
+		label = "hdmi";
+		type = "d";
+
+		port {
+			hdmi_connector_in: endpoint {
+				remote-endpoint = <&hdmi_connector_out>;
+			};
+		};
+	};
 };
 
 &auxadc {
@@ -120,6 +132,41 @@ &i2c6 {
 	pinctrl-0 = <&i2c6_pins>;
 	status = "okay";
 	clock-frequency = <100000>;
+	#address-cells = <1>;
+	#size-cells = <0>;
+
+	it66121hdmitx: hdmitx@4c {
+		compatible = "ite,it66121";
+		pinctrl-names = "default";
+		pinctrl-0 = <&ite_pins>;
+		vcn33-supply = <&mt6358_vcn33_wifi_reg>;
+		vcn18-supply = <&mt6358_vcn18_reg>;
+		vrf12-supply = <&mt6358_vrf12_reg>;
+		reset-gpios = <&pio 160 GPIO_ACTIVE_LOW>;
+		interrupt-parent = <&pio>;
+		interrupts = <4 IRQ_TYPE_LEVEL_LOW>;
+		reg = <0x4c>;
+
+		ports {
+			#address-cells = <1>;
+			#size-cells = <0>;
+
+			port@0 {
+				reg = <0>;
+				it66121_in: endpoint {
+					bus-width = <12>;
+					remote-endpoint = <&dpi_out>;
+				};
+			};
+
+			port@1 {
+				reg = <1>;
+				hdmi_connector_out: endpoint {
+					remote-endpoint = <&hdmi_connector_in>;
+				};
+			};
+		};
+	};
 };
 
 &mmc0 {
@@ -332,6 +379,61 @@ pins_clk {
 			input-enable;
 		};
 	};
+
+	ite_pins: ite-pins {
+		pins_rst {
+			pinmux = <PINMUX_GPIO160__FUNC_GPIO160>;
+			output-high;
+		};
+	};
+
+	dpi_pins_func: dpi-pins-func {
+		pins_dpi {
+			pinmux = <PINMUX_GPIO12__FUNC_I2S5_BCK>,
+				 <PINMUX_GPIO46__FUNC_I2S5_LRCK>,
+				 <PINMUX_GPIO47__FUNC_I2S5_DO>,
+				 <PINMUX_GPIO13__FUNC_DBPI_D0>,
+				 <PINMUX_GPIO14__FUNC_DBPI_D1>,
+				 <PINMUX_GPIO15__FUNC_DBPI_D2>,
+				 <PINMUX_GPIO16__FUNC_DBPI_D3>,
+				 <PINMUX_GPIO17__FUNC_DBPI_D4>,
+				 <PINMUX_GPIO18__FUNC_DBPI_D5>,
+				 <PINMUX_GPIO19__FUNC_DBPI_D6>,
+				 <PINMUX_GPIO20__FUNC_DBPI_D7>,
+				 <PINMUX_GPIO21__FUNC_DBPI_D8>,
+				 <PINMUX_GPIO22__FUNC_DBPI_D9>,
+				 <PINMUX_GPIO23__FUNC_DBPI_D10>,
+				 <PINMUX_GPIO24__FUNC_DBPI_D11>,
+				 <PINMUX_GPIO25__FUNC_DBPI_HSYNC>,
+				 <PINMUX_GPIO26__FUNC_DBPI_VSYNC>,
+				 <PINMUX_GPIO27__FUNC_DBPI_DE>,
+				 <PINMUX_GPIO28__FUNC_DBPI_CK>;
+		};
+	};
+
+	dpi_pins_idle: dpi-pins-idle {
+		pins_gpio {
+			pinmux = <PINMUX_GPIO12__FUNC_GPIO12>,
+				 <PINMUX_GPIO46__FUNC_GPIO46>,
+				 <PINMUX_GPIO47__FUNC_GPIO47>,
+				 <PINMUX_GPIO13__FUNC_GPIO13>,
+				 <PINMUX_GPIO14__FUNC_GPIO14>,
+				 <PINMUX_GPIO15__FUNC_GPIO15>,
+				 <PINMUX_GPIO16__FUNC_GPIO16>,
+				 <PINMUX_GPIO17__FUNC_GPIO17>,
+				 <PINMUX_GPIO18__FUNC_GPIO18>,
+				 <PINMUX_GPIO19__FUNC_GPIO19>,
+				 <PINMUX_GPIO20__FUNC_GPIO20>,
+				 <PINMUX_GPIO21__FUNC_GPIO21>,
+				 <PINMUX_GPIO22__FUNC_GPIO22>,
+				 <PINMUX_GPIO23__FUNC_GPIO23>,
+				 <PINMUX_GPIO24__FUNC_GPIO24>,
+				 <PINMUX_GPIO25__FUNC_GPIO25>,
+				 <PINMUX_GPIO26__FUNC_GPIO26>,
+				 <PINMUX_GPIO27__FUNC_GPIO27>,
+				 <PINMUX_GPIO28__FUNC_GPIO28>;
+		};
+	};
 };
 
 &mfg {
@@ -381,3 +483,16 @@ &scp {
 &dsi0 {
 	status = "disabled";
 };
+
+&dpi0 {
+	pinctrl-names = "default", "sleep";
+	pinctrl-0 = <&dpi_pins_func>;
+	pinctrl-1 = <&dpi_pins_idle>;
+	status = "okay";
+
+	port {
+		dpi_out: endpoint {
+			remote-endpoint = <&it66121_in>;
+		};
+	};
+};
-- 
2.33.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [PATCH 3/3] arm64: dts: mediatek: mt8183-pumpkin: add USB host support
  2021-11-10 19:24 [PATCH 1/3] arm64: dts: mt8183: add dpi node to mt8183 Fabien Parent
  2021-11-10 19:24 ` [PATCH 2/3] arm64: dts: mediatek: mt8183-pumpkin: add HDMI support Fabien Parent
@ 2021-11-10 19:24 ` Fabien Parent
  2021-11-17 17:33 ` [PATCH 1/3] arm64: dts: mt8183: add dpi node to mt8183 Matthias Brugger
  2 siblings, 0 replies; 6+ messages in thread
From: Fabien Parent @ 2021-11-10 19:24 UTC (permalink / raw)
  To: Rob Herring, Matthias Brugger
  Cc: Fabien Parent, devicetree, linux-arm-kernel, linux-mediatek,
	linux-kernel

The MT8183 Pumpkin board provides USB host support through 2 type-A
ports. In addition the board provides Ethernet support
with the LAN9512 IP connected on the USB bus.

Signed-off-by: Fabien Parent <fparent@baylibre.com>
---
 .../boot/dts/mediatek/mt8183-pumpkin.dts      | 26 +++++++++++++++++++
 1 file changed, 26 insertions(+)

diff --git a/arch/arm64/boot/dts/mediatek/mt8183-pumpkin.dts b/arch/arm64/boot/dts/mediatek/mt8183-pumpkin.dts
index d5a6628e9c5b..541b382c0e81 100644
--- a/arch/arm64/boot/dts/mediatek/mt8183-pumpkin.dts
+++ b/arch/arm64/boot/dts/mediatek/mt8183-pumpkin.dts
@@ -434,6 +434,18 @@ pins_gpio {
 				 <PINMUX_GPIO28__FUNC_GPIO28>;
 		};
 	};
+
+	usb_pins: usb-pins {
+		pins_usb {
+			pinmux = <PINMUX_GPIO42__FUNC_GPIO42>;
+			output-low;
+		};
+
+		pins_hub_rst {
+			pinmux = <PINMUX_GPIO9__FUNC_GPIO9>;
+			output-low;
+		};
+	};
 };
 
 &mfg {
@@ -496,3 +508,17 @@ dpi_out: endpoint {
 		};
 	};
 };
+
+&ssusb {
+	pinctrl-names = "default";
+	pinctrl-0 = <&usb_pins>;
+	maximum-speed = "high-speed";
+	dr_mode = "host";
+	vusb33-supply = <&mt6358_vusb_reg>;
+	status = "okay";
+};
+
+&usb_host {
+	vusb33-supply = <&mt6358_vusb_reg>;
+	status = "okay";
+};
-- 
2.33.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/3] arm64: dts: mt8183: add dpi node to mt8183
  2021-11-10 19:24 [PATCH 1/3] arm64: dts: mt8183: add dpi node to mt8183 Fabien Parent
  2021-11-10 19:24 ` [PATCH 2/3] arm64: dts: mediatek: mt8183-pumpkin: add HDMI support Fabien Parent
  2021-11-10 19:24 ` [PATCH 3/3] arm64: dts: mediatek: mt8183-pumpkin: add USB host support Fabien Parent
@ 2021-11-17 17:33 ` Matthias Brugger
  2021-11-17 18:21   ` Fabien Parent
  2 siblings, 1 reply; 6+ messages in thread
From: Matthias Brugger @ 2021-11-17 17:33 UTC (permalink / raw)
  To: Fabien Parent, Rob Herring
  Cc: Pi-Hsun Shih, Jitao Shi, devicetree, linux-arm-kernel,
	linux-mediatek, linux-kernel



On 10/11/2021 20:24, Fabien Parent wrote:
> From: Pi-Hsun Shih <pihsun@chromium.org>
> 
> Add dpi node to mt8183.
> 
> Signed-off-by: Jitao Shi <jitao.shi@mediatek.com>
> Signed-off-by: Pi-Hsun Shih <pihsun@chromium.org>
> Signed-off-by: Fabien Parent <fparent@baylibre.com>
> ---
>   arch/arm64/boot/dts/mediatek/mt8183.dtsi | 11 +++++++++++
>   1 file changed, 11 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/mediatek/mt8183.dtsi b/arch/arm64/boot/dts/mediatek/mt8183.dtsi
> index ba4584faca5a..7c283c0b68b5 100644
> --- a/arch/arm64/boot/dts/mediatek/mt8183.dtsi
> +++ b/arch/arm64/boot/dts/mediatek/mt8183.dtsi
> @@ -1443,6 +1443,17 @@ dsi0: dsi@14014000 {
>   			phy-names = "dphy";
>   		};
>   
> +		dpi0: dpi@14015000 {
> +			compatible = "mediatek,mt8183-dpi";
> +			reg = <0 0x14015000 0 0x1000>;
> +			interrupts = <GIC_SPI 237 IRQ_TYPE_LEVEL_LOW>;
> +			power-domains = <&spm MT8183_POWER_DOMAIN_DISP>;
> +			clocks = <&mmsys CLK_MM_DPI_IF>,
> +				 <&mmsys CLK_MM_DPI_MM>,
> +				 <&apmixedsys CLK_APMIXED_TVDPLL>;
> +			clock-names = "pixel", "engine", "pll";


We are missing the output port node, don't we?

Regards,
Matthias

> +		};
> +
>   		mutex: mutex@14016000 {
>   			compatible = "mediatek,mt8183-disp-mutex";
>   			reg = <0 0x14016000 0 0x1000>;
> 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/3] arm64: dts: mt8183: add dpi node to mt8183
  2021-11-17 17:33 ` [PATCH 1/3] arm64: dts: mt8183: add dpi node to mt8183 Matthias Brugger
@ 2021-11-17 18:21   ` Fabien Parent
  2021-11-17 18:25     ` Matthias Brugger
  0 siblings, 1 reply; 6+ messages in thread
From: Fabien Parent @ 2021-11-17 18:21 UTC (permalink / raw)
  To: Matthias Brugger
  Cc: Rob Herring, Pi-Hsun Shih, Jitao Shi, DTML, Linux ARM,
	moderated list:ARM/Mediatek SoC support, linux-kernel

Hi Matthias,


On Wed, Nov 17, 2021 at 6:33 PM Matthias Brugger <matthias.bgg@gmail.com> wrote:
>
>
>
> On 10/11/2021 20:24, Fabien Parent wrote:
> > From: Pi-Hsun Shih <pihsun@chromium.org>
> >
> > Add dpi node to mt8183.
> >
> > Signed-off-by: Jitao Shi <jitao.shi@mediatek.com>
> > Signed-off-by: Pi-Hsun Shih <pihsun@chromium.org>
> > Signed-off-by: Fabien Parent <fparent@baylibre.com>
> > ---
> >   arch/arm64/boot/dts/mediatek/mt8183.dtsi | 11 +++++++++++
> >   1 file changed, 11 insertions(+)
> >
> > diff --git a/arch/arm64/boot/dts/mediatek/mt8183.dtsi b/arch/arm64/boot/dts/mediatek/mt8183.dtsi
> > index ba4584faca5a..7c283c0b68b5 100644
> > --- a/arch/arm64/boot/dts/mediatek/mt8183.dtsi
> > +++ b/arch/arm64/boot/dts/mediatek/mt8183.dtsi
> > @@ -1443,6 +1443,17 @@ dsi0: dsi@14014000 {
> >                       phy-names = "dphy";
> >               };
> >
> > +             dpi0: dpi@14015000 {
> > +                     compatible = "mediatek,mt8183-dpi";
> > +                     reg = <0 0x14015000 0 0x1000>;
> > +                     interrupts = <GIC_SPI 237 IRQ_TYPE_LEVEL_LOW>;
> > +                     power-domains = <&spm MT8183_POWER_DOMAIN_DISP>;
> > +                     clocks = <&mmsys CLK_MM_DPI_IF>,
> > +                              <&mmsys CLK_MM_DPI_MM>,
> > +                              <&apmixedsys CLK_APMIXED_TVDPLL>;
> > +                     clock-names = "pixel", "engine", "pll";
>
>
> We are missing the output port node, don't we?

The output port node is defined in: [PATCH 2/3] arm64: dts: mediatek:
mt8183-pumpkin: add HDMI support
Unlike MT8173, there is no HDMI IP in the MT8183 SoC.

>
> Regards,
> Matthias
>
> > +             };
> > +
> >               mutex: mutex@14016000 {
> >                       compatible = "mediatek,mt8183-disp-mutex";
> >                       reg = <0 0x14016000 0 0x1000>;
> >

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH 1/3] arm64: dts: mt8183: add dpi node to mt8183
  2021-11-17 18:21   ` Fabien Parent
@ 2021-11-17 18:25     ` Matthias Brugger
  0 siblings, 0 replies; 6+ messages in thread
From: Matthias Brugger @ 2021-11-17 18:25 UTC (permalink / raw)
  To: Fabien Parent
  Cc: Rob Herring, Pi-Hsun Shih, Jitao Shi, DTML, Linux ARM,
	moderated list:ARM/Mediatek SoC support, linux-kernel



On 17/11/2021 19:21, Fabien Parent wrote:
> Hi Matthias,
> 
> 
> On Wed, Nov 17, 2021 at 6:33 PM Matthias Brugger <matthias.bgg@gmail.com> wrote:
>>
>>
>>
>> On 10/11/2021 20:24, Fabien Parent wrote:
>>> From: Pi-Hsun Shih <pihsun@chromium.org>
>>>
>>> Add dpi node to mt8183.
>>>
>>> Signed-off-by: Jitao Shi <jitao.shi@mediatek.com>
>>> Signed-off-by: Pi-Hsun Shih <pihsun@chromium.org>
>>> Signed-off-by: Fabien Parent <fparent@baylibre.com>
>>> ---
>>>    arch/arm64/boot/dts/mediatek/mt8183.dtsi | 11 +++++++++++
>>>    1 file changed, 11 insertions(+)
>>>
>>> diff --git a/arch/arm64/boot/dts/mediatek/mt8183.dtsi b/arch/arm64/boot/dts/mediatek/mt8183.dtsi
>>> index ba4584faca5a..7c283c0b68b5 100644
>>> --- a/arch/arm64/boot/dts/mediatek/mt8183.dtsi
>>> +++ b/arch/arm64/boot/dts/mediatek/mt8183.dtsi
>>> @@ -1443,6 +1443,17 @@ dsi0: dsi@14014000 {
>>>                        phy-names = "dphy";
>>>                };
>>>
>>> +             dpi0: dpi@14015000 {
>>> +                     compatible = "mediatek,mt8183-dpi";
>>> +                     reg = <0 0x14015000 0 0x1000>;
>>> +                     interrupts = <GIC_SPI 237 IRQ_TYPE_LEVEL_LOW>;
>>> +                     power-domains = <&spm MT8183_POWER_DOMAIN_DISP>;
>>> +                     clocks = <&mmsys CLK_MM_DPI_IF>,
>>> +                              <&mmsys CLK_MM_DPI_MM>,
>>> +                              <&apmixedsys CLK_APMIXED_TVDPLL>;
>>> +                     clock-names = "pixel", "engine", "pll";
>>
>>
>> We are missing the output port node, don't we?
> 
> The output port node is defined in: [PATCH 2/3] arm64: dts: mediatek:
> mt8183-pumpkin: add HDMI support
> Unlike MT8173, there is no HDMI IP in the MT8183 SoC.
> 

Ok, I missed that because the thread is broken. Would you mind to just resend 
the whole series?

Thanks,
Matthias

>>
>> Regards,
>> Matthias
>>
>>> +             };
>>> +
>>>                mutex: mutex@14016000 {
>>>                        compatible = "mediatek,mt8183-disp-mutex";
>>>                        reg = <0 0x14016000 0 0x1000>;
>>>

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2021-11-17 18:27 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-11-10 19:24 [PATCH 1/3] arm64: dts: mt8183: add dpi node to mt8183 Fabien Parent
2021-11-10 19:24 ` [PATCH 2/3] arm64: dts: mediatek: mt8183-pumpkin: add HDMI support Fabien Parent
2021-11-10 19:24 ` [PATCH 3/3] arm64: dts: mediatek: mt8183-pumpkin: add USB host support Fabien Parent
2021-11-17 17:33 ` [PATCH 1/3] arm64: dts: mt8183: add dpi node to mt8183 Matthias Brugger
2021-11-17 18:21   ` Fabien Parent
2021-11-17 18:25     ` Matthias Brugger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).