Linux ARM-MSM sub-architecture
 help / color / mirror / Atom feed
* [PATCH 1/1] arm64: dts: qcom: ipq6018: enable sdhci node
@ 2024-01-07 12:28 Chukun Pan
  2024-01-09 10:17 ` Robert Marko
  0 siblings, 1 reply; 4+ messages in thread
From: Chukun Pan @ 2024-01-07 12:28 UTC (permalink / raw)
  To: Bjorn Andersson
  Cc: Konrad Dybcio, Krzysztof Kozlowski, Conor Dooley, Rob Herring,
	linux-arm-msm, linux-kernel, devicetree, Chukun Pan

Enable mmc device found on ipq6018 devices.
This node supports both eMMC and SD cards.

Tested with:
  eMMC (HS200)
  SD Card (SDR50/SDR104)

Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
---
 arch/arm64/boot/dts/qcom/ipq6018.dtsi | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/ipq6018.dtsi b/arch/arm64/boot/dts/qcom/ipq6018.dtsi
index 5e1277fea725..39fb38914a1e 100644
--- a/arch/arm64/boot/dts/qcom/ipq6018.dtsi
+++ b/arch/arm64/boot/dts/qcom/ipq6018.dtsi
@@ -436,6 +436,28 @@ dwc_1: usb@7000000 {
 			};
 		};
 
+		sdhc: mmc@7804000 {
+			compatible = "qcom,ipq6018-sdhci", "qcom,sdhci-msm-v5";
+			reg = <0x0 0x7804000 0x0 0x1000>,
+			      <0x0 0x7805000 0x0 0x1000>;
+			reg-names = "hc", "cqhci";
+
+			interrupts = <GIC_SPI 123 IRQ_TYPE_LEVEL_HIGH>,
+				     <GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>;
+			interrupt-names = "hc_irq", "pwr_irq";
+
+			clocks = <&gcc GCC_SDCC1_AHB_CLK>,
+				 <&gcc GCC_SDCC1_APPS_CLK>,
+				 <&xo>;
+			clock-names = "iface", "core", "xo";
+			resets = <&gcc GCC_SDCC1_BCR>;
+			max-frequency = <192000000>;
+			mmc-ddr-1_8v;
+			mmc-hs200-1_8v;
+
+			status = "disabled";
+		};
+
 		blsp_dma: dma-controller@7884000 {
 			compatible = "qcom,bam-v1.7.0";
 			reg = <0x0 0x07884000 0x0 0x2b000>;
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH 1/1] arm64: dts: qcom: ipq6018: enable sdhci node
  2024-01-07 12:28 [PATCH 1/1] arm64: dts: qcom: ipq6018: enable sdhci node Chukun Pan
@ 2024-01-09 10:17 ` Robert Marko
  2024-01-10  2:30   ` Chukun Pan
  0 siblings, 1 reply; 4+ messages in thread
From: Robert Marko @ 2024-01-09 10:17 UTC (permalink / raw)
  To: Chukun Pan, Bjorn Andersson
  Cc: Konrad Dybcio, Krzysztof Kozlowski, Conor Dooley, Rob Herring,
	linux-arm-msm, linux-kernel, devicetree


On 07. 01. 2024. 13:28, Chukun Pan wrote:
> Enable mmc device found on ipq6018 devices.
> This node supports both eMMC and SD cards.
>
> Tested with:
>    eMMC (HS200)
>    SD Card (SDR50/SDR104)
>
> Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
L2 LDO should be used as VQMMC supply, otherwise you cannot change 
between 3 and 1.8V.

Regards,
Robert
> ---
>   arch/arm64/boot/dts/qcom/ipq6018.dtsi | 22 ++++++++++++++++++++++
>   1 file changed, 22 insertions(+)
>
> diff --git a/arch/arm64/boot/dts/qcom/ipq6018.dtsi b/arch/arm64/boot/dts/qcom/ipq6018.dtsi
> index 5e1277fea725..39fb38914a1e 100644
> --- a/arch/arm64/boot/dts/qcom/ipq6018.dtsi
> +++ b/arch/arm64/boot/dts/qcom/ipq6018.dtsi
> @@ -436,6 +436,28 @@ dwc_1: usb@7000000 {
>   			};
>   		};
>   
> +		sdhc: mmc@7804000 {
> +			compatible = "qcom,ipq6018-sdhci", "qcom,sdhci-msm-v5";
> +			reg = <0x0 0x7804000 0x0 0x1000>,
> +			      <0x0 0x7805000 0x0 0x1000>;
> +			reg-names = "hc", "cqhci";
> +
> +			interrupts = <GIC_SPI 123 IRQ_TYPE_LEVEL_HIGH>,
> +				     <GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>;
> +			interrupt-names = "hc_irq", "pwr_irq";
> +
> +			clocks = <&gcc GCC_SDCC1_AHB_CLK>,
> +				 <&gcc GCC_SDCC1_APPS_CLK>,
> +				 <&xo>;
> +			clock-names = "iface", "core", "xo";
> +			resets = <&gcc GCC_SDCC1_BCR>;
> +			max-frequency = <192000000>;
> +			mmc-ddr-1_8v;
> +			mmc-hs200-1_8v;
> +
> +			status = "disabled";
> +		};
> +
>   		blsp_dma: dma-controller@7884000 {
>   			compatible = "qcom,bam-v1.7.0";
>   			reg = <0x0 0x07884000 0x0 0x2b000>;

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 1/1] arm64: dts: qcom: ipq6018: enable sdhci node
  2024-01-09 10:17 ` Robert Marko
@ 2024-01-10  2:30   ` Chukun Pan
  2024-01-10  8:29     ` Robert Marko
  0 siblings, 1 reply; 4+ messages in thread
From: Chukun Pan @ 2024-01-10  2:30 UTC (permalink / raw)
  To: robimarko
  Cc: amadeus, andersson, conor+dt, devicetree, konrad.dybcio,
	krzysztof.kozlowski+dt, linux-arm-msm, linux-kernel, robh+dt

Hi, Robert
> L2 LDO should be used as VQMMC supply, otherwise you cannot change 
> between 3 and 1.8V.

Some ipq6000 devices do not have pmic chips, resulting in l2 being
unavailable. So vqmmc-supply should be configured in the dts of the
device.

Thanks,
Chukun

-- 
2.25.1


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 1/1] arm64: dts: qcom: ipq6018: enable sdhci node
  2024-01-10  2:30   ` Chukun Pan
@ 2024-01-10  8:29     ` Robert Marko
  0 siblings, 0 replies; 4+ messages in thread
From: Robert Marko @ 2024-01-10  8:29 UTC (permalink / raw)
  To: Chukun Pan
  Cc: andersson, conor+dt, devicetree, konrad.dybcio,
	krzysztof.kozlowski+dt, linux-arm-msm, linux-kernel, robh+dt

On Wed, 10 Jan 2024 at 03:31, Chukun Pan <amadeus@jmu.edu.cn> wrote:
>
> Hi, Robert
> > L2 LDO should be used as VQMMC supply, otherwise you cannot change
> > between 3 and 1.8V.
>
> Some ipq6000 devices do not have pmic chips, resulting in l2 being
> unavailable. So vqmmc-supply should be configured in the dts of the
> device.

Yes, but you need to at least register it in the RPM regulator node so
that they can easily reference it in the device DTS.

Regards,
Robert
>
> Thanks,
> Chukun
>
> --
> 2.25.1
>

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-01-10  8:29 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-01-07 12:28 [PATCH 1/1] arm64: dts: qcom: ipq6018: enable sdhci node Chukun Pan
2024-01-09 10:17 ` Robert Marko
2024-01-10  2:30   ` Chukun Pan
2024-01-10  8:29     ` Robert Marko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox