From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from kirsty.vergenet.net ([202.4.237.240]:35777 "EHLO kirsty.vergenet.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752472AbdLGJyx (ORCPT ); Thu, 7 Dec 2017 04:54:53 -0500 From: Simon Horman To: linux-renesas-soc@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org, Magnus Damm , Vladimir Barinov , Simon Horman Subject: [PATCH 15/54] arm64: dts: renesas: ulcb-kf: enable USB2 PHY of channel 0 Date: Thu, 7 Dec 2017 10:53:18 +0100 Message-Id: <80785024767c03ff28861db0faf274fffb8d713a.1512640145.git.horms+renesas@verge.net.au> In-Reply-To: References: Sender: linux-renesas-soc-owner@vger.kernel.org List-ID: From: Vladimir Barinov This supports USB2 PHY channel #0 on ULCB Kingfisher board The dedicated USB0_PWEN pin is used to control CN13 VBUS source from U43 power supply. MAX3355 can also provide VBUS, hence it should be disabled via OTG_OFFVBUSn node coming from gpio expander TCA9539. Set MAX3355 enabled using OTG_EXTLPn node to be able to read OTG ID of CN13. Signed-off-by: Vladimir Barinov Reviewed-by: Geert Uytterhoeven Signed-off-by: Simon Horman --- arch/arm64/boot/dts/renesas/ulcb-kf.dtsi | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/arch/arm64/boot/dts/renesas/ulcb-kf.dtsi b/arch/arm64/boot/dts/renesas/ulcb-kf.dtsi index 657ad1041965..48a2e8f48e3f 100644 --- a/arch/arm64/boot/dts/renesas/ulcb-kf.dtsi +++ b/arch/arm64/boot/dts/renesas/ulcb-kf.dtsi @@ -67,6 +67,20 @@ output-high; line-name = "HUB rst"; }; + + otg_offvbusn { + gpio-hog; + gpios = <8 GPIO_ACTIVE_HIGH>; + output-low; + line-name = "OTG OFFVBUSn"; + }; + + otg_extlpn { + gpio-hog; + gpios = <9 GPIO_ACTIVE_HIGH>; + output-high; + line-name = "OTG EXTLPn"; + }; }; gpio_exp_75: gpio@75 { @@ -154,6 +168,11 @@ groups = "scif1_data_b", "scif1_ctrl"; function = "scif1"; }; + + usb0_pins: usb0 { + groups = "usb0"; + function = "usb0"; + }; }; &scif1 { @@ -164,6 +183,13 @@ status = "okay"; }; +&usb2_phy0 { + pinctrl-0 = <&usb0_pins>; + pinctrl-names = "default"; + + status = "okay"; +}; + &xhci0 { status = "okay"; }; -- 2.11.0 From mboxrd@z Thu Jan 1 00:00:00 1970 From: horms+renesas@verge.net.au (Simon Horman) Date: Thu, 7 Dec 2017 10:53:18 +0100 Subject: [PATCH 15/54] arm64: dts: renesas: ulcb-kf: enable USB2 PHY of channel 0 In-Reply-To: References: Message-ID: <80785024767c03ff28861db0faf274fffb8d713a.1512640145.git.horms+renesas@verge.net.au> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org From: Vladimir Barinov This supports USB2 PHY channel #0 on ULCB Kingfisher board The dedicated USB0_PWEN pin is used to control CN13 VBUS source from U43 power supply. MAX3355 can also provide VBUS, hence it should be disabled via OTG_OFFVBUSn node coming from gpio expander TCA9539. Set MAX3355 enabled using OTG_EXTLPn node to be able to read OTG ID of CN13. Signed-off-by: Vladimir Barinov Reviewed-by: Geert Uytterhoeven Signed-off-by: Simon Horman --- arch/arm64/boot/dts/renesas/ulcb-kf.dtsi | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/arch/arm64/boot/dts/renesas/ulcb-kf.dtsi b/arch/arm64/boot/dts/renesas/ulcb-kf.dtsi index 657ad1041965..48a2e8f48e3f 100644 --- a/arch/arm64/boot/dts/renesas/ulcb-kf.dtsi +++ b/arch/arm64/boot/dts/renesas/ulcb-kf.dtsi @@ -67,6 +67,20 @@ output-high; line-name = "HUB rst"; }; + + otg_offvbusn { + gpio-hog; + gpios = <8 GPIO_ACTIVE_HIGH>; + output-low; + line-name = "OTG OFFVBUSn"; + }; + + otg_extlpn { + gpio-hog; + gpios = <9 GPIO_ACTIVE_HIGH>; + output-high; + line-name = "OTG EXTLPn"; + }; }; gpio_exp_75: gpio at 75 { @@ -154,6 +168,11 @@ groups = "scif1_data_b", "scif1_ctrl"; function = "scif1"; }; + + usb0_pins: usb0 { + groups = "usb0"; + function = "usb0"; + }; }; &scif1 { @@ -164,6 +183,13 @@ status = "okay"; }; +&usb2_phy0 { + pinctrl-0 = <&usb0_pins>; + pinctrl-names = "default"; + + status = "okay"; +}; + &xhci0 { status = "okay"; }; -- 2.11.0