From: Chunfeng Yun <chunfeng.yun@mediatek.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Rob Herring <robh+dt@kernel.org>
Cc: Mark Rutland <mark.rutland@arm.com>,
Matthias Brugger <matthias.bgg@gmail.com>,
Mathias Nyman <mathias.nyman@intel.com>,
Chunfeng Yun <chunfeng.yun@mediatek.com>,
<linux-usb@vger.kernel.org>, <devicetree@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>,
<linux-mediatek@lists.infradead.org>,
<linux-kernel@vger.kernel.org>
Subject: [PATCH v3 5/7] arm64: dts: mt8183: add usb and phy nodes
Date: Fri, 30 Aug 2019 15:40:52 +0800 [thread overview]
Message-ID: <1567150854-30033-6-git-send-email-chunfeng.yun@mediatek.com> (raw)
In-Reply-To: <1567150854-30033-1-git-send-email-chunfeng.yun@mediatek.com>
Add USB related nodes for MT8183, set it as host mode by default.
Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com>
---
v2~v3: no changes
---
arch/arm64/boot/dts/mediatek/mt8183-evb.dts | 22 +++++++++
arch/arm64/boot/dts/mediatek/mt8183.dtsi | 55 +++++++++++++++++++++
2 files changed, 77 insertions(+)
diff --git a/arch/arm64/boot/dts/mediatek/mt8183-evb.dts b/arch/arm64/boot/dts/mediatek/mt8183-evb.dts
index d8e555cbb5d3..142ff52f0f42 100644
--- a/arch/arm64/boot/dts/mediatek/mt8183-evb.dts
+++ b/arch/arm64/boot/dts/mediatek/mt8183-evb.dts
@@ -6,7 +6,9 @@
*/
/dts-v1/;
+#include <dt-bindings/gpio/gpio.h>
#include "mt8183.dtsi"
+#include "mt6358.dtsi"
/ {
model = "MediaTek MT8183 evaluation board";
@@ -24,6 +26,16 @@
chosen {
stdout-path = "serial0:921600n8";
};
+
+ usb_vbus: regulator@0 {
+ compatible = "regulator-fixed";
+ regulator-name = "p0_vbus";
+ regulator-min-microvolt = <5000000>;
+ regulator-max-microvolt = <5000000>;
+ gpio = <&pio 42 GPIO_ACTIVE_HIGH>;
+ enable-active-high;
+ regulator-always-on;
+ };
};
&auxadc {
@@ -135,6 +147,16 @@
};
+&ssusb {
+ vusb33-supply = <&mt6358_vusb_reg>;
+ dr_mode = "host";
+ status = "okay";
+};
+
+&usb_host {
+ status = "okay";
+};
+
&uart0 {
status = "okay";
};
diff --git a/arch/arm64/boot/dts/mediatek/mt8183.dtsi b/arch/arm64/boot/dts/mediatek/mt8183.dtsi
index c2749c4631bc..28da334237c6 100644
--- a/arch/arm64/boot/dts/mediatek/mt8183.dtsi
+++ b/arch/arm64/boot/dts/mediatek/mt8183.dtsi
@@ -8,6 +8,7 @@
#include <dt-bindings/clock/mt8183-clk.h>
#include <dt-bindings/interrupt-controller/arm-gic.h>
#include <dt-bindings/interrupt-controller/irq.h>
+#include <dt-bindings/phy/phy.h>
#include "mt8183-pinfunc.h"
/ {
@@ -372,6 +373,35 @@
status = "disabled";
};
+ ssusb: usb@11201000 {
+ compatible = "mediatek,mt8183-mtu3", "mediatek,mtu3";
+ reg = <0 0x11201000 0 0x2e00>,
+ <0 0x11203e00 0 0x0100>;
+ reg-names = "mac", "ippc";
+ interrupts = <GIC_SPI 72 IRQ_TYPE_LEVEL_LOW>;
+ phys = <&u2port0 PHY_TYPE_USB2>,
+ <&u3port0 PHY_TYPE_USB3>;
+ clocks = <&infracfg CLK_INFRA_UNIPRO_SCK>,
+ <&infracfg CLK_INFRA_USB>;
+ clock-names = "sys_ck", "ref_ck";
+ #address-cells = <2>;
+ #size-cells = <2>;
+ ranges;
+ status = "disabled";
+
+ usb_host: xhci@11200000 {
+ compatible = "mediatek,mt8183-xhci",
+ "mediatek,mtk-xhci";
+ reg = <0 0x11200000 0 0x1000>;
+ reg-names = "mac";
+ interrupts = <GIC_SPI 73 IRQ_TYPE_LEVEL_LOW>;
+ clocks = <&infracfg CLK_INFRA_UNIPRO_SCK>,
+ <&infracfg CLK_INFRA_USB>;
+ clock-names = "sys_ck", "ref_ck";
+ status = "disabled";
+ };
+ };
+
audiosys: syscon@11220000 {
compatible = "mediatek,mt8183-audiosys", "syscon";
reg = <0 0x11220000 0 0x1000>;
@@ -384,6 +414,31 @@
reg = <0 0x11f10000 0 0x1000>;
};
+ u3phy: usb-phy@11f40000 {
+ compatible = "mediatek,mt8183-tphy",
+ "mediatek,generic-tphy-v2";
+ #address-cells = <1>;
+ #size-cells = <1>;
+ ranges = <0 0 0x11f40000 0x1000>;
+ status = "okay";
+
+ u2port0: usb-phy@0 {
+ reg = <0x0 0x700>;
+ clocks = <&clk26m>;
+ clock-names = "ref";
+ #phy-cells = <1>;
+ status = "okay";
+ };
+
+ u3port0: usb-phy@0700 {
+ reg = <0x0700 0x900>;
+ clocks = <&clk26m>;
+ clock-names = "ref";
+ #phy-cells = <1>;
+ status = "okay";
+ };
+ };
+
mfgcfg: syscon@13000000 {
compatible = "mediatek,mt8183-mfgcfg", "syscon";
reg = <0 0x13000000 0 0x1000>;
--
2.23.0
next prev parent reply other threads:[~2019-08-30 7:41 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-30 7:40 [PATCH v3 0/7] add support USB for MT8183 Chunfeng Yun
2019-08-30 7:40 ` [PATCH v3 1/7] dt-bindings: usb: mtu3: support USB wakeup " Chunfeng Yun
2019-09-02 13:39 ` Rob Herring
2019-08-30 7:40 ` [PATCH v3 2/7] dt-bindings: usb: mtk-xhci: " Chunfeng Yun
2019-09-02 13:39 ` Rob Herring
2019-08-30 7:40 ` [PATCH v3 3/7] usb: mtu3: support ip-sleep " Chunfeng Yun
2019-09-02 9:23 ` kbuild test robot
2019-09-11 18:44 ` Guenter Roeck
2019-09-16 5:45 ` Chunfeng Yun
2019-08-30 7:40 ` [PATCH v3 4/7] usb: mtk-xhci: " Chunfeng Yun
2019-09-02 11:58 ` kbuild test robot
2019-08-30 7:40 ` Chunfeng Yun [this message]
2019-09-03 11:25 ` [PATCH v3 5/7] arm64: dts: mt8183: add usb and phy nodes kbuild test robot
2020-05-21 15:06 ` Matthias Brugger
2019-08-30 7:40 ` [PATCH v3 6/7] arm64: dts: mt8183: enable USB remote wakeup Chunfeng Yun
2019-08-30 7:40 ` [PATCH v3 7/7] arm64: dts: mt8183: tune disconnect threshold of u2phy Chunfeng Yun
2019-09-04 1:54 ` [PATCH v3 0/7] add support USB for MT8183 Chunfeng Yun
2019-09-04 7:06 ` Greg Kroah-Hartman
2020-05-21 12:41 ` Matthias Brugger
2020-05-22 1:07 ` Chunfeng Yun
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1567150854-30033-6-git-send-email-chunfeng.yun@mediatek.com \
--to=chunfeng.yun@mediatek.com \
--cc=devicetree@vger.kernel.org \
--cc=gregkh@linuxfoundation.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=linux-usb@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=mathias.nyman@intel.com \
--cc=matthias.bgg@gmail.com \
--cc=robh+dt@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).