Skip to content

Commit e77416b

Browse files
Kriskura176767Komal-Bajaj
authored andcommitted
arm64: dts: qcom: Add USB changes for Shikra
Add usb related changes on Shikra specifically: a) Primary controller node b) Primary high speed phy c) QMP Phy for super speed operation Enable USB controller and phys in device mode on CQS and CQM variants. Add the regulators for the phys accordingly. Signed-off-by: Krishna Kurapati <krishna.kurapati@oss.qualcomm.com>
1 parent ef1edb8 commit e77416b

3 files changed

Lines changed: 184 additions & 0 deletions

File tree

arch/arm64/boot/dts/qcom/shikra-cqm-evk.dts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,3 +59,24 @@
5959
&uart0 {
6060
status = "okay";
6161
};
62+
63+
&usb_1 {
64+
dr_mode = "peripheral";
65+
66+
status = "okay";
67+
};
68+
69+
&usb_1_hsphy {
70+
vdd-supply = <&pm4125_l12>;
71+
vdda-pll-supply = <&pm4125_l13>;
72+
vdda-phy-dpdm-supply = <&pm4125_l21>;
73+
74+
status = "okay";
75+
};
76+
77+
&usb_qmpphy {
78+
vdda-phy-supply = <&pm4125_l8>;
79+
vdda-pll-supply = <&pm4125_l13>;
80+
81+
status = "okay";
82+
};

arch/arm64/boot/dts/qcom/shikra-cqs-evk.dts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,3 +59,24 @@
5959
&uart0 {
6060
status = "okay";
6161
};
62+
63+
&usb_1 {
64+
dr_mode = "peripheral";
65+
66+
status = "okay";
67+
};
68+
69+
&usb_1_hsphy {
70+
vdd-supply = <&pm4125_l12>;
71+
vdda-pll-supply = <&pm4125_l13>;
72+
vdda-phy-dpdm-supply = <&pm4125_l21>;
73+
74+
status = "okay";
75+
};
76+
77+
&usb_qmpphy {
78+
vdda-phy-supply = <&pm4125_l8>;
79+
vdda-pll-supply = <&pm4125_l13>;
80+
81+
status = "okay";
82+
};

arch/arm64/boot/dts/qcom/shikra.dtsi

Lines changed: 142 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -488,6 +488,70 @@
488488
#power-domain-cells = <1>;
489489
};
490490

491+
usb_1_hsphy: phy@1613000 {
492+
compatible = "qcom,shikra-qusb2-phy";
493+
reg = <0x0 0x01613000 0x0 0x180>;
494+
495+
clocks = <&gcc GCC_AHB2PHY_USB_CLK>,
496+
<&rpmcc RPM_SMD_XO_CLK_SRC>;
497+
clock-names = "cfg_ahb", "ref";
498+
499+
resets = <&gcc GCC_QUSB2PHY_PRIM_BCR>;
500+
nvmem-cells = <&qusb2_hstx_trim_1>;
501+
#phy-cells = <0>;
502+
503+
status = "disabled";
504+
};
505+
506+
usb_qmpphy: phy@1615000 {
507+
compatible = "qcom,shikra-qmp-usb3-phy";
508+
reg = <0x0 0x01615000 0x0 0x1000>;
509+
510+
clocks = <&gcc GCC_AHB2PHY_USB_CLK>,
511+
<&gcc GCC_USB3_PRIM_CLKREF_EN>,
512+
<&gcc GCC_USB3_PRIM_PHY_COM_AUX_CLK>,
513+
<&gcc GCC_USB3_PRIM_PHY_PIPE_CLK>;
514+
clock-names = "cfg_ahb",
515+
"ref",
516+
"com_aux",
517+
"pipe";
518+
519+
resets = <&gcc GCC_USB3_PHY_PRIM_SP0_BCR>,
520+
<&gcc GCC_USB3PHY_PHY_PRIM_SP0_BCR>;
521+
reset-names = "phy",
522+
"phy_phy";
523+
524+
#clock-cells = <0>;
525+
clock-output-names = "usb3_phy_pipe_clk_src";
526+
527+
#phy-cells = <0>;
528+
orientation-switch;
529+
530+
qcom,tcsr-reg = <&tcsr_regs 0xb244>;
531+
532+
status = "disabled";
533+
534+
ports {
535+
#address-cells = <1>;
536+
#size-cells = <0>;
537+
538+
port@0 {
539+
reg = <0>;
540+
541+
usb_qmpphy_out: endpoint {
542+
};
543+
};
544+
545+
port@1 {
546+
reg = <1>;
547+
548+
usb_qmpphy_usb_ss_in: endpoint {
549+
remote-endpoint = <&usb_1_dwc3_ss>;
550+
};
551+
};
552+
};
553+
};
554+
491555
system_noc: interconnect@1880000 {
492556
compatible = "qcom,shikra-sys-noc";
493557
reg = <0x0 0x01880000 0x0 0x6a080>;
@@ -534,6 +598,11 @@
534598
#address-cells = <1>;
535599
#size-cells = <1>;
536600

601+
qusb2_hstx_trim_1: hstx-trim@258 {
602+
reg = <0x25b 0x1>;
603+
bits = <1 4>;
604+
};
605+
537606
gpu_speed_bin: gpu-speed-bin@6006 {
538607
reg = <0x6006 0x2>;
539608
bits = <5 8>;
@@ -689,6 +758,79 @@
689758
};
690759
};
691760

761+
usb_1: usb@4e00000 {
762+
compatible = "qcom,shikra-dwc3", "qcom,snps-dwc3";
763+
reg = <0x0 0x04e00000 0x0 0xfc100>;
764+
765+
clocks = <&gcc GCC_CFG_NOC_USB3_PRIM_AXI_CLK>,
766+
<&gcc GCC_USB30_PRIM_MASTER_CLK>,
767+
<&gcc GCC_SYS_NOC_USB3_PRIM_AXI_CLK>,
768+
<&gcc GCC_USB30_PRIM_SLEEP_CLK>,
769+
<&gcc GCC_USB30_PRIM_MOCK_UTMI_CLK>,
770+
<&gcc GCC_USB3_PRIM_CLKREF_EN>;
771+
clock-names = "cfg_noc",
772+
"core",
773+
"iface",
774+
"sleep",
775+
"mock_utmi",
776+
"xo";
777+
778+
assigned-clocks = <&gcc GCC_USB30_PRIM_MOCK_UTMI_CLK>,
779+
<&gcc GCC_USB30_PRIM_MASTER_CLK>;
780+
assigned-clock-rates = <19200000>, <133333333>;
781+
782+
interrupts-extended = <&intc GIC_SPI 255 IRQ_TYPE_LEVEL_HIGH>,
783+
<&intc GIC_SPI 302 IRQ_TYPE_LEVEL_HIGH>,
784+
<&intc GIC_SPI 260 IRQ_TYPE_LEVEL_HIGH>,
785+
<&intc GIC_SPI 422 IRQ_TYPE_LEVEL_HIGH>;
786+
interrupt-names = "dwc_usb3",
787+
"pwr_event",
788+
"qusb2_phy",
789+
"ss_phy_irq";
790+
791+
iommus = <&apps_smmu 0x120 0x0>;
792+
793+
phys = <&usb_1_hsphy>, <&usb_qmpphy>;
794+
phy-names = "usb2-phy", "usb3-phy";
795+
796+
power-domains = <&gcc GCC_USB30_PRIM_GDSC>;
797+
798+
resets = <&gcc GCC_USB30_PRIM_BCR>;
799+
800+
snps,dis_u2_susphy_quirk;
801+
snps,dis_enblslpm_quirk;
802+
snps,has-lpm-erratum;
803+
snps,hird-threshold = /bits/ 8 <0x10>;
804+
snps,usb3_lpm_capable;
805+
snps,parkmode-disable-ss-quirk;
806+
807+
usb-role-switch;
808+
809+
wakeup-source;
810+
811+
status = "disabled";
812+
813+
ports {
814+
#address-cells = <1>;
815+
#size-cells = <0>;
816+
817+
port@0 {
818+
reg = <0>;
819+
820+
usb_1_dwc3_hs: endpoint {
821+
};
822+
};
823+
824+
port@1 {
825+
reg = <1>;
826+
827+
usb_1_dwc3_ss: endpoint {
828+
remote-endpoint = <&usb_qmpphy_usb_ss_in>;
829+
};
830+
};
831+
};
832+
};
833+
692834
adreno_smmu: iommu@59a0000 {
693835
compatible = "qcom,shikra-smmu-500", "qcom,smmu-500", "arm,mmu-500";
694836
reg = <0x0 0x059a0000 0x0 0x10000>;

0 commit comments

Comments
 (0)