Skip to contentSkip to conversation

arm64: dts: qcom: UFS updates

PATCH In review Vinod Koul 2 participants 5 messages Jan 6, 2020

Subsystems (3)
lore
Share & tools
lore

Vinod Koul

author
#0 lore raw

cover arm64: dts: qcom: UFS updates

We recently saw regression on UFS on SM8150 and few other boards and that was resolved by adding timeout and fixing the UFS phy reset sequence. That patches are in linux-next now.

During this we found sm8150 lacks gpio reset for ufs, so add that and fix the ufs phy register size.
Also add the sdm845 ufs reset.

Vinod Koul (3):
arm64: dts: qcom: sm8150-mtp: Add UFS gpio reset
arm64: dts: qcom: sm8150: Fix UFS phy register size
arm64: dts: qcom: sdm845: add the ufs reset

 arch/arm64/boot/dts/qcom/sdm845.dtsi    | 2 ++
 arch/arm64/boot/dts/qcom/sm8150-mtp.dts | 3 +++
 arch/arm64/boot/dts/qcom/sm8150.dtsi    | 2 +-
 3 files changed, 6 insertions(+), 1 deletion(-)
Signature · 1 line
2.24.1
author
#1 lore raw

PATCH 1/3 arm64: dts: qcom: sm8150-mtp: Add UFS gpio reset

Add the reset-gpio for UFS for sm8150-mtp.

---
 arch/arm64/boot/dts/qcom/sm8150-mtp.dts | 3 +++
 1 file changed, 3 insertions(+)
arch/arm64/boot/dts/qcom/sm8150-mtp.dts +3 -0
index 1eb93a768a85..9cab51759d2f 100644
@@ -7,6 +7,7 @@
 /dts-v1/;
 
 #include <dt-bindings/regulator/qcom,rpmh-regulator.h>
+#include <dt-bindings/gpio/gpio.h>
 #include "sm8150.dtsi"
 #include "pm8150.dtsi"
 #include "pm8150b.dtsi"
@@ -389,6 +390,8 @@ &uart2 {
 &ufs_mem_hc {
 	status = "okay";
 
+	reset-gpios = <&tlmm 175 GPIO_ACTIVE_LOW>;
+
 	vcc-supply = <&vreg_l10a_2p5>;
 	vcc-max-microamp = <750000>;
 	vccq-supply = <&vreg_l9a_1p2>;
Signature · 1 line
2.24.1
author
#2 lore raw

PATCH 2/3 arm64: dts: qcom: sm8150: Fix UFS phy register size

In reply to Vinod Koul

UFS phy register space size is 0x1c0. so update it

---
 arch/arm64/boot/dts/qcom/sm8150.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/arm64/boot/dts/qcom/sm8150.dtsi +1 -1
index f36d621a53e2..f92b92866ae0 100644
@@ -553,7 +553,7 @@ ufs_mem_hc: ufshc@1d84000 {
 
 		ufs_mem_phy: phy@1d87000 {
 			compatible = "qcom,sm8150-qmp-ufs-phy";
-			reg = <0 0x01d87000 0 0x18c>;
+			reg = <0 0x01d87000 0 0x1c0>;
 			#address-cells = <2>;
 			#size-cells = <2>;
 			ranges;
Signature · 1 line
2.24.1
author
#3 lore raw

PATCH 3/3 arm64: dts: qcom: sdm845: add the ufs reset

In reply to Vinod Koul

Add the core UFS reset for sdm845

---
 arch/arm64/boot/dts/qcom/sdm845.dtsi | 2 ++
 1 file changed, 2 insertions(+)
arch/arm64/boot/dts/qcom/sdm845.dtsi +2 -0
index ddb1f23c936f..0c233afd7a5e 100644
@@ -1374,6 +1374,8 @@ ufs_mem_hc: ufshc@1d84000 {
 			lanes-per-direction = <2>;
 			power-domains = <&gcc UFS_PHY_GDSC>;
 			#reset-cells = <1>;
+			resets = <&gcc GCC_UFS_PHY_BCR>;
+			reset-names = "rst";
 
 			iommus = <&apps_smmu 0x100 0xf>;
 
Signature · 1 line
2.24.1
#4 lore raw
In reply to Vinod Koul
Quoted 8 lines · Vinod Koul

We recently saw regression on UFS on SM8150 and few other boards and that was resolved by adding timeout and fixing the UFS phy reset sequence. That patches are in linux-next now.

During this we found sm8150 lacks gpio reset for ufs, so add that and fix the ufs phy register size.
Also add the sdm845 ufs reset.

Thanks Vinod, boot tested and merged.

Quoted 13 lines

Vinod Koul (3):
arm64: dts: qcom: sm8150-mtp: Add UFS gpio reset
arm64: dts: qcom: sm8150: Fix UFS phy register size
arm64: dts: qcom: sdm845: add the ufs reset

 arch/arm64/boot/dts/qcom/sdm845.dtsi    | 2 ++
 arch/arm64/boot/dts/qcom/sm8150-mtp.dts | 3 +++
 arch/arm64/boot/dts/qcom/sm8150.dtsi    | 2 +-
 3 files changed, 6 insertions(+), 1 deletion(-)
Signature · 1 line
2.24.1