2024-05-14 13:08:59

by Manivannan Sadhasivam

[permalink] [raw]
Subject: [PATCH 0/2] arm64: dts: qcom: Use 'ufshc' as the node name for UFS controller nodes

Devicetree binding has documented the node name for UFS controllers as
'ufshc'. So let's use it instead of 'ufs' which is for the UFS devices.

Signed-off-by: Manivannan Sadhasivam <[email protected]>
---
Manivannan Sadhasivam (2):
dt-bindings: ufs: qcom: Use 'ufshc' as the node name for UFS controller nodes
arm64: dts: qcom: Use 'ufshc' as the node name for UFS controller nodes

Documentation/devicetree/bindings/ufs/qcom,ufs.yaml | 2 +-
arch/arm64/boot/dts/qcom/sa8775p.dtsi | 2 +-
arch/arm64/boot/dts/qcom/sc7280.dtsi | 2 +-
arch/arm64/boot/dts/qcom/sc8280xp.dtsi | 4 ++--
arch/arm64/boot/dts/qcom/sm6115.dtsi | 2 +-
arch/arm64/boot/dts/qcom/sm6125.dtsi | 2 +-
arch/arm64/boot/dts/qcom/sm6350.dtsi | 2 +-
arch/arm64/boot/dts/qcom/sm8550.dtsi | 2 +-
arch/arm64/boot/dts/qcom/sm8650.dtsi | 2 +-
9 files changed, 10 insertions(+), 10 deletions(-)
---
base-commit: 4cece764965020c22cff7665b18a012006359095
change-id: 20240514-ufs-nodename-fix-40672bc593a5

Best regards,
--
Manivannan Sadhasivam <[email protected]>



2024-05-14 13:09:13

by Manivannan Sadhasivam

[permalink] [raw]
Subject: [PATCH 1/2] dt-bindings: ufs: qcom: Use 'ufshc' as the node name for UFS controller nodes

Devicetree binding has documented the node name for UFS controllers as
'ufshc'. So let's use it instead of 'ufs' which is for the UFS devices.

Signed-off-by: Manivannan Sadhasivam <[email protected]>
---
Documentation/devicetree/bindings/ufs/qcom,ufs.yaml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/ufs/qcom,ufs.yaml b/Documentation/devicetree/bindings/ufs/qcom,ufs.yaml
index 10c146424baa..37112e17e474 100644
--- a/Documentation/devicetree/bindings/ufs/qcom,ufs.yaml
+++ b/Documentation/devicetree/bindings/ufs/qcom,ufs.yaml
@@ -273,7 +273,7 @@ examples:
#address-cells = <2>;
#size-cells = <2>;

- ufs@1d84000 {
+ ufshc@1d84000 {
compatible = "qcom,sm8450-ufshc", "qcom,ufshc",
"jedec,ufs-2.0";
reg = <0 0x01d84000 0 0x3000>;

--
2.25.1


2024-05-14 13:09:34

by Manivannan Sadhasivam

[permalink] [raw]
Subject: [PATCH 2/2] arm64: dts: qcom: Use 'ufshc' as the node name for UFS controller nodes

Devicetree binding has documented the node name for UFS controllers as
'ufshc'. So let's use it instead of 'ufs' which is for the UFS devices.

Signed-off-by: Manivannan Sadhasivam <[email protected]>
---
arch/arm64/boot/dts/qcom/sa8775p.dtsi | 2 +-
arch/arm64/boot/dts/qcom/sc7280.dtsi | 2 +-
arch/arm64/boot/dts/qcom/sc8280xp.dtsi | 4 ++--
arch/arm64/boot/dts/qcom/sm6115.dtsi | 2 +-
arch/arm64/boot/dts/qcom/sm6125.dtsi | 2 +-
arch/arm64/boot/dts/qcom/sm6350.dtsi | 2 +-
arch/arm64/boot/dts/qcom/sm8550.dtsi | 2 +-
arch/arm64/boot/dts/qcom/sm8650.dtsi | 2 +-
8 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/sa8775p.dtsi b/arch/arm64/boot/dts/qcom/sa8775p.dtsi
index 231cea1f0fa8..3f65494259aa 100644
--- a/arch/arm64/boot/dts/qcom/sa8775p.dtsi
+++ b/arch/arm64/boot/dts/qcom/sa8775p.dtsi
@@ -1577,7 +1577,7 @@ rng: rng@10d2000 {
reg = <0 0x010d2000 0 0x1000>;
};

- ufs_mem_hc: ufs@1d84000 {
+ ufs_mem_hc: ufshc@1d84000 {
compatible = "qcom,sa8775p-ufshc", "qcom,ufshc", "jedec,ufs-2.0";
reg = <0x0 0x01d84000 0x0 0x3000>;
interrupts = <GIC_SPI 265 IRQ_TYPE_LEVEL_HIGH>;
diff --git a/arch/arm64/boot/dts/qcom/sc7280.dtsi b/arch/arm64/boot/dts/qcom/sc7280.dtsi
index 7e7f0f0fb41b..da63e9435130 100644
--- a/arch/arm64/boot/dts/qcom/sc7280.dtsi
+++ b/arch/arm64/boot/dts/qcom/sc7280.dtsi
@@ -2303,7 +2303,7 @@ pcie1_phy: phy@1c0e000 {
status = "disabled";
};

- ufs_mem_hc: ufs@1d84000 {
+ ufs_mem_hc: ufshc@1d84000 {
compatible = "qcom,sc7280-ufshc", "qcom,ufshc",
"jedec,ufs-2.0";
reg = <0x0 0x01d84000 0x0 0x3000>;
diff --git a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi
index a5b194813079..9c5437c2540a 100644
--- a/arch/arm64/boot/dts/qcom/sc8280xp.dtsi
+++ b/arch/arm64/boot/dts/qcom/sc8280xp.dtsi
@@ -2208,7 +2208,7 @@ pcie2a_phy: phy@1c24000 {
status = "disabled";
};

- ufs_mem_hc: ufs@1d84000 {
+ ufs_mem_hc: ufshc@1d84000 {
compatible = "qcom,sc8280xp-ufshc", "qcom,ufshc",
"jedec,ufs-2.0";
reg = <0 0x01d84000 0 0x3000>;
@@ -2274,7 +2274,7 @@ ufs_mem_phy: phy@1d87000 {
status = "disabled";
};

- ufs_card_hc: ufs@1da4000 {
+ ufs_card_hc: ufshc@1da4000 {
compatible = "qcom,sc8280xp-ufshc", "qcom,ufshc",
"jedec,ufs-2.0";
reg = <0 0x01da4000 0 0x3000>;
diff --git a/arch/arm64/boot/dts/qcom/sm6115.dtsi b/arch/arm64/boot/dts/qcom/sm6115.dtsi
index aca0a87092e4..974e4b6e27a4 100644
--- a/arch/arm64/boot/dts/qcom/sm6115.dtsi
+++ b/arch/arm64/boot/dts/qcom/sm6115.dtsi
@@ -1175,7 +1175,7 @@ opp-202000000 {
};
};

- ufs_mem_hc: ufs@4804000 {
+ ufs_mem_hc: ufshc@4804000 {
compatible = "qcom,sm6115-ufshc", "qcom,ufshc", "jedec,ufs-2.0";
reg = <0x0 0x04804000 0x0 0x3000>, <0x0 0x04810000 0x0 0x8000>;
reg-names = "std", "ice";
diff --git a/arch/arm64/boot/dts/qcom/sm6125.dtsi b/arch/arm64/boot/dts/qcom/sm6125.dtsi
index 98ab08356088..20527b254f6b 100644
--- a/arch/arm64/boot/dts/qcom/sm6125.dtsi
+++ b/arch/arm64/boot/dts/qcom/sm6125.dtsi
@@ -763,7 +763,7 @@ sdhc_2: mmc@4784000 {
status = "disabled";
};

- ufs_mem_hc: ufs@4804000 {
+ ufs_mem_hc: ufshc@4804000 {
compatible = "qcom,sm6125-ufshc", "qcom,ufshc", "jedec,ufs-2.0";
reg = <0x04804000 0x3000>, <0x04810000 0x8000>;
reg-names = "std", "ice";
diff --git a/arch/arm64/boot/dts/qcom/sm6350.dtsi b/arch/arm64/boot/dts/qcom/sm6350.dtsi
index 24bcec3366ef..66e5ebbbbada 100644
--- a/arch/arm64/boot/dts/qcom/sm6350.dtsi
+++ b/arch/arm64/boot/dts/qcom/sm6350.dtsi
@@ -1136,7 +1136,7 @@ mmss_noc: interconnect@1740000 {
qcom,bcm-voters = <&apps_bcm_voter>;
};

- ufs_mem_hc: ufs@1d84000 {
+ ufs_mem_hc: ufshc@1d84000 {
compatible = "qcom,sm6350-ufshc", "qcom,ufshc",
"jedec,ufs-2.0";
reg = <0 0x01d84000 0 0x3000>,
diff --git a/arch/arm64/boot/dts/qcom/sm8550.dtsi b/arch/arm64/boot/dts/qcom/sm8550.dtsi
index 3904348075f6..94eea47c24d3 100644
--- a/arch/arm64/boot/dts/qcom/sm8550.dtsi
+++ b/arch/arm64/boot/dts/qcom/sm8550.dtsi
@@ -1957,7 +1957,7 @@ ufs_mem_phy: phy@1d80000 {
status = "disabled";
};

- ufs_mem_hc: ufs@1d84000 {
+ ufs_mem_hc: ufshc@1d84000 {
compatible = "qcom,sm8550-ufshc", "qcom,ufshc",
"jedec,ufs-2.0";
reg = <0x0 0x01d84000 0x0 0x3000>;
diff --git a/arch/arm64/boot/dts/qcom/sm8650.dtsi b/arch/arm64/boot/dts/qcom/sm8650.dtsi
index ba72d8f38420..7c6d2150a1e0 100644
--- a/arch/arm64/boot/dts/qcom/sm8650.dtsi
+++ b/arch/arm64/boot/dts/qcom/sm8650.dtsi
@@ -2509,7 +2509,7 @@ ufs_mem_phy: phy@1d80000 {
status = "disabled";
};

- ufs_mem_hc: ufs@1d84000 {
+ ufs_mem_hc: ufshc@1d84000 {
compatible = "qcom,sm8650-ufshc", "qcom,ufshc", "jedec,ufs-2.0";
reg = <0 0x01d84000 0 0x3000>;


--
2.25.1


2024-05-14 18:50:41

by Conor Dooley

[permalink] [raw]
Subject: Re: [PATCH 1/2] dt-bindings: ufs: qcom: Use 'ufshc' as the node name for UFS controller nodes

On Tue, May 14, 2024 at 03:08:40PM +0200, Manivannan Sadhasivam wrote:
> Devicetree binding has documented the node name for UFS controllers as
> 'ufshc'. So let's use it instead of 'ufs' which is for the UFS devices.

Can you point out where that's been documented?
Thanks,
Conor.

>
> Signed-off-by: Manivannan Sadhasivam <[email protected]>
> ---
> Documentation/devicetree/bindings/ufs/qcom,ufs.yaml | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/Documentation/devicetree/bindings/ufs/qcom,ufs.yaml b/Documentation/devicetree/bindings/ufs/qcom,ufs.yaml
> index 10c146424baa..37112e17e474 100644
> --- a/Documentation/devicetree/bindings/ufs/qcom,ufs.yaml
> +++ b/Documentation/devicetree/bindings/ufs/qcom,ufs.yaml
> @@ -273,7 +273,7 @@ examples:
> #address-cells = <2>;
> #size-cells = <2>;
>
> - ufs@1d84000 {
> + ufshc@1d84000 {
> compatible = "qcom,sm8450-ufshc", "qcom,ufshc",
> "jedec,ufs-2.0";
> reg = <0 0x01d84000 0 0x3000>;
>
> --
> 2.25.1
>


Attachments:
(No filename) (1.09 kB)
signature.asc (235.00 B)
Download all attachments

2024-05-15 07:50:18

by Manivannan Sadhasivam

[permalink] [raw]
Subject: Re: [PATCH 1/2] dt-bindings: ufs: qcom: Use 'ufshc' as the node name for UFS controller nodes

On Tue, May 14, 2024 at 07:50:15PM +0100, Conor Dooley wrote:
> On Tue, May 14, 2024 at 03:08:40PM +0200, Manivannan Sadhasivam wrote:
> > Devicetree binding has documented the node name for UFS controllers as
> > 'ufshc'. So let's use it instead of 'ufs' which is for the UFS devices.
>
> Can you point out where that's been documented?

Typo here. s/Devicetree binding/Devicetree spec

https://github.com/devicetree-org/devicetree-specification/blob/main/source/chapter2-devicetree-basics.rst#generic-names-recommendation

- Mani

> Thanks,
> Conor.
>
> >
> > Signed-off-by: Manivannan Sadhasivam <[email protected]>
> > ---
> > Documentation/devicetree/bindings/ufs/qcom,ufs.yaml | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/Documentation/devicetree/bindings/ufs/qcom,ufs.yaml b/Documentation/devicetree/bindings/ufs/qcom,ufs.yaml
> > index 10c146424baa..37112e17e474 100644
> > --- a/Documentation/devicetree/bindings/ufs/qcom,ufs.yaml
> > +++ b/Documentation/devicetree/bindings/ufs/qcom,ufs.yaml
> > @@ -273,7 +273,7 @@ examples:
> > #address-cells = <2>;
> > #size-cells = <2>;
> >
> > - ufs@1d84000 {
> > + ufshc@1d84000 {
> > compatible = "qcom,sm8450-ufshc", "qcom,ufshc",
> > "jedec,ufs-2.0";
> > reg = <0 0x01d84000 0 0x3000>;
> >
> > --
> > 2.25.1
> >



--
மணிவண்ணன் சதாசிவம்

2024-05-15 08:03:52

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH 1/2] dt-bindings: ufs: qcom: Use 'ufshc' as the node name for UFS controller nodes

On 15/05/2024 09:50, Manivannan Sadhasivam wrote:
> On Tue, May 14, 2024 at 07:50:15PM +0100, Conor Dooley wrote:
>> On Tue, May 14, 2024 at 03:08:40PM +0200, Manivannan Sadhasivam wrote:
>>> Devicetree binding has documented the node name for UFS controllers as
>>> 'ufshc'. So let's use it instead of 'ufs' which is for the UFS devices.
>>
>> Can you point out where that's been documented?
>
> Typo here. s/Devicetree binding/Devicetree spec
>
> https://github.com/devicetree-org/devicetree-specification/blob/main/source/chapter2-devicetree-basics.rst#generic-names-recommendation

I read your explanation in DT spec commit:

"In a lot of places, 'ufs' is used as the node name to identify the host
controller, but it is wrong since 'ufs' denotes 'UFS device'."

but isn't this the same as with MMC? We do not call the nodes "mmchc" or
"mmch", even though all of them are hosts, because "mmc" is the card.
The same for most of other storage devices. Or USB. The term
"controller" appears only for few cases like clocks, resets and power.

When looking at storage nodes, ufsHC is an exception here.

Best regards,
Krzysztof


2024-05-15 08:08:31

by Conor Dooley

[permalink] [raw]
Subject: Re: [PATCH 1/2] dt-bindings: ufs: qcom: Use 'ufshc' as the node name for UFS controller nodes

On Wed, May 15, 2024 at 09:50:05AM +0200, Manivannan Sadhasivam wrote:
> On Tue, May 14, 2024 at 07:50:15PM +0100, Conor Dooley wrote:
> > On Tue, May 14, 2024 at 03:08:40PM +0200, Manivannan Sadhasivam wrote:
> > > Devicetree binding has documented the node name for UFS controllers as
> > > 'ufshc'. So let's use it instead of 'ufs' which is for the UFS devices.
> >
> > Can you point out where that's been documented?
>
> Typo here. s/Devicetree binding/Devicetree spec
>
> https://github.com/devicetree-org/devicetree-specification/blob/main/source/chapter2-devicetree-basics.rst#generic-names-recommendation

Ah, that makes sense. I grepped for it in the kernel tree and didn't see
anything so I was a bit confused..


Attachments:
(No filename) (739.00 B)
signature.asc (235.00 B)
Download all attachments

2024-05-15 08:21:06

by Manivannan Sadhasivam

[permalink] [raw]
Subject: Re: [PATCH 1/2] dt-bindings: ufs: qcom: Use 'ufshc' as the node name for UFS controller nodes

On Wed, May 15, 2024 at 10:03:36AM +0200, Krzysztof Kozlowski wrote:
> On 15/05/2024 09:50, Manivannan Sadhasivam wrote:
> > On Tue, May 14, 2024 at 07:50:15PM +0100, Conor Dooley wrote:
> >> On Tue, May 14, 2024 at 03:08:40PM +0200, Manivannan Sadhasivam wrote:
> >>> Devicetree binding has documented the node name for UFS controllers as
> >>> 'ufshc'. So let's use it instead of 'ufs' which is for the UFS devices.
> >>
> >> Can you point out where that's been documented?
> >
> > Typo here. s/Devicetree binding/Devicetree spec
> >
> > https://github.com/devicetree-org/devicetree-specification/blob/main/source/chapter2-devicetree-basics.rst#generic-names-recommendation
>
> I read your explanation in DT spec commit:
>
> "In a lot of places, 'ufs' is used as the node name to identify the host
> controller, but it is wrong since 'ufs' denotes 'UFS device'."
>
> but isn't this the same as with MMC? We do not call the nodes "mmchc" or
> "mmch", even though all of them are hosts, because "mmc" is the card.
> The same for most of other storage devices. Or USB. The term
> "controller" appears only for few cases like clocks, resets and power.
>

The compatible for UFS HC is '*-ufshc', so it makes sense to use 'ufshc' as the
node name. But for other bus controllers like MMC, compatible just mentions
'mmc'.

And there were already nodes using both 'ufshc' and 'ufs', so I wanted to avoid
the confusion and just use 'ufshc'.

- Mani

--
மணிவண்ணன் சதாசிவம்

2024-05-15 19:17:41

by Stephen Boyd

[permalink] [raw]
Subject: Re: [PATCH 1/2] dt-bindings: ufs: qcom: Use 'ufshc' as the node name for UFS controller nodes

Quoting Manivannan Sadhasivam (2024-05-14 06:08:40)
> Devicetree binding has documented the node name for UFS controllers as
> 'ufshc'. So let's use it instead of 'ufs' which is for the UFS devices.
>
> Signed-off-by: Manivannan Sadhasivam <[email protected]>
> ---

Reviewed-by: Stephen Boyd <[email protected]>

2024-05-15 19:18:09

by Stephen Boyd

[permalink] [raw]
Subject: Re: [PATCH 2/2] arm64: dts: qcom: Use 'ufshc' as the node name for UFS controller nodes

Quoting Manivannan Sadhasivam (2024-05-14 06:08:41)
> Devicetree binding has documented the node name for UFS controllers as
> 'ufshc'. So let's use it instead of 'ufs' which is for the UFS devices.
>
> Signed-off-by: Manivannan Sadhasivam <[email protected]>
> ---

Reviewed-by: Stephen Boyd <[email protected]>