This patch series contains change to move sdc pinconf from SoC specific
DT file to board specific DT file. It also contain change to set sdc
GPIO pin to bias-pull up
Tested sd card working on sc7180 based board
Changes in v3:
- update commit message in patch 2
Changes in v2:
- added pull-up for IDP
Sujit Kautkar (2):
arm64: dts: qcom: sc7180: Move sdc pinconf to board specific DT files
arm64: dts: qcom: sc7180: SD-card GPIO pin set bias-pull up
arch/arm64/boot/dts/qcom/sc7180-idp.dts | 102 +++++++++++++++++++
arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi | 102 +++++++++++++++++++
arch/arm64/boot/dts/qcom/sc7180.dtsi | 102 -------------------
3 files changed, 204 insertions(+), 102 deletions(-)
--
2.32.0.rc0.204.g9fa02ecfa5-goog
Move sdc1/sdc2 pinconf from SoC specific DT file to board specific DT
files
Signed-off-by: Sujit Kautkar <[email protected]>
---
(no changes since v1)
arch/arm64/boot/dts/qcom/sc7180-idp.dts | 102 +++++++++++++++++++
arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi | 102 +++++++++++++++++++
arch/arm64/boot/dts/qcom/sc7180.dtsi | 102 -------------------
3 files changed, 204 insertions(+), 102 deletions(-)
diff --git a/arch/arm64/boot/dts/qcom/sc7180-idp.dts b/arch/arm64/boot/dts/qcom/sc7180-idp.dts
index e77a7926034a7..07133e0af581a 100644
--- a/arch/arm64/boot/dts/qcom/sc7180-idp.dts
+++ b/arch/arm64/boot/dts/qcom/sc7180-idp.dts
@@ -598,4 +598,106 @@ pinconf-rx {
bias-pull-up;
};
};
+
+ sdc1_on: sdc1-on {
+ pinconf-clk {
+ pins = "sdc1_clk";
+ bias-disable;
+ drive-strength = <16>;
+ };
+
+ pinconf-cmd {
+ pins = "sdc1_cmd";
+ bias-pull-up;
+ drive-strength = <10>;
+ };
+
+ pinconf-data {
+ pins = "sdc1_data";
+ bias-pull-up;
+ drive-strength = <10>;
+ };
+
+ pinconf-rclk {
+ pins = "sdc1_rclk";
+ bias-pull-down;
+ };
+ };
+
+ sdc1_off: sdc1-off {
+ pinconf-clk {
+ pins = "sdc1_clk";
+ bias-disable;
+ drive-strength = <2>;
+ };
+
+ pinconf-cmd {
+ pins = "sdc1_cmd";
+ bias-pull-up;
+ drive-strength = <2>;
+ };
+
+ pinconf-data {
+ pins = "sdc1_data";
+ bias-pull-up;
+ drive-strength = <2>;
+ };
+
+ pinconf-rclk {
+ pins = "sdc1_rclk";
+ bias-pull-down;
+ };
+ };
+
+ sdc2_on: sdc2-on {
+ pinconf-clk {
+ pins = "sdc2_clk";
+ bias-disable;
+ drive-strength = <16>;
+ };
+
+ pinconf-cmd {
+ pins = "sdc2_cmd";
+ bias-pull-up;
+ drive-strength = <10>;
+ };
+
+ pinconf-data {
+ pins = "sdc2_data";
+ bias-pull-up;
+ drive-strength = <10>;
+ };
+
+ pinconf-sd-cd {
+ pins = "gpio69";
+ bias-pull-up;
+ drive-strength = <2>;
+ };
+ };
+
+ sdc2_off: sdc2-off {
+ pinconf-clk {
+ pins = "sdc2_clk";
+ bias-disable;
+ drive-strength = <2>;
+ };
+
+ pinconf-cmd {
+ pins = "sdc2_cmd";
+ bias-pull-up;
+ drive-strength = <2>;
+ };
+
+ pinconf-data {
+ pins = "sdc2_data";
+ bias-pull-up;
+ drive-strength = <2>;
+ };
+
+ pinconf-sd-cd {
+ pins = "gpio69";
+ bias-disable;
+ drive-strength = <2>;
+ };
+ };
};
diff --git a/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi b/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi
index 609f0ceafd095..d128a0ed6ad3a 100644
--- a/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi
+++ b/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi
@@ -1540,4 +1540,106 @@ pinconf {
drive-strength = <2>;
};
};
+
+ sdc1_on: sdc1-on {
+ pinconf-clk {
+ pins = "sdc1_clk";
+ bias-disable;
+ drive-strength = <16>;
+ };
+
+ pinconf-cmd {
+ pins = "sdc1_cmd";
+ bias-pull-up;
+ drive-strength = <10>;
+ };
+
+ pinconf-data {
+ pins = "sdc1_data";
+ bias-pull-up;
+ drive-strength = <10>;
+ };
+
+ pinconf-rclk {
+ pins = "sdc1_rclk";
+ bias-pull-down;
+ };
+ };
+
+ sdc1_off: sdc1-off {
+ pinconf-clk {
+ pins = "sdc1_clk";
+ bias-disable;
+ drive-strength = <2>;
+ };
+
+ pinconf-cmd {
+ pins = "sdc1_cmd";
+ bias-pull-up;
+ drive-strength = <2>;
+ };
+
+ pinconf-data {
+ pins = "sdc1_data";
+ bias-pull-up;
+ drive-strength = <2>;
+ };
+
+ pinconf-rclk {
+ pins = "sdc1_rclk";
+ bias-pull-down;
+ };
+ };
+
+ sdc2_on: sdc2-on {
+ pinconf-clk {
+ pins = "sdc2_clk";
+ bias-disable;
+ drive-strength = <16>;
+ };
+
+ pinconf-cmd {
+ pins = "sdc2_cmd";
+ bias-pull-up;
+ drive-strength = <10>;
+ };
+
+ pinconf-data {
+ pins = "sdc2_data";
+ bias-pull-up;
+ drive-strength = <10>;
+ };
+
+ pinconf-sd-cd {
+ pins = "gpio69";
+ bias-pull-up;
+ drive-strength = <2>;
+ };
+ };
+
+ sdc2_off: sdc2-off {
+ pinconf-clk {
+ pins = "sdc2_clk";
+ bias-disable;
+ drive-strength = <2>;
+ };
+
+ pinconf-cmd {
+ pins = "sdc2_cmd";
+ bias-pull-up;
+ drive-strength = <2>;
+ };
+
+ pinconf-data {
+ pins = "sdc2_data";
+ bias-pull-up;
+ drive-strength = <2>;
+ };
+
+ pinconf-sd-cd {
+ pins = "gpio69";
+ bias-disable;
+ drive-strength = <2>;
+ };
+ };
};
diff --git a/arch/arm64/boot/dts/qcom/sc7180.dtsi b/arch/arm64/boot/dts/qcom/sc7180.dtsi
index 1fc328ba0403e..0630a9c410b58 100644
--- a/arch/arm64/boot/dts/qcom/sc7180.dtsi
+++ b/arch/arm64/boot/dts/qcom/sc7180.dtsi
@@ -1872,108 +1872,6 @@ pinmux {
function = "lpass_ext";
};
};
-
- sdc1_on: sdc1-on {
- pinconf-clk {
- pins = "sdc1_clk";
- bias-disable;
- drive-strength = <16>;
- };
-
- pinconf-cmd {
- pins = "sdc1_cmd";
- bias-pull-up;
- drive-strength = <10>;
- };
-
- pinconf-data {
- pins = "sdc1_data";
- bias-pull-up;
- drive-strength = <10>;
- };
-
- pinconf-rclk {
- pins = "sdc1_rclk";
- bias-pull-down;
- };
- };
-
- sdc1_off: sdc1-off {
- pinconf-clk {
- pins = "sdc1_clk";
- bias-disable;
- drive-strength = <2>;
- };
-
- pinconf-cmd {
- pins = "sdc1_cmd";
- bias-pull-up;
- drive-strength = <2>;
- };
-
- pinconf-data {
- pins = "sdc1_data";
- bias-pull-up;
- drive-strength = <2>;
- };
-
- pinconf-rclk {
- pins = "sdc1_rclk";
- bias-pull-down;
- };
- };
-
- sdc2_on: sdc2-on {
- pinconf-clk {
- pins = "sdc2_clk";
- bias-disable;
- drive-strength = <16>;
- };
-
- pinconf-cmd {
- pins = "sdc2_cmd";
- bias-pull-up;
- drive-strength = <10>;
- };
-
- pinconf-data {
- pins = "sdc2_data";
- bias-pull-up;
- drive-strength = <10>;
- };
-
- pinconf-sd-cd {
- pins = "gpio69";
- bias-pull-up;
- drive-strength = <2>;
- };
- };
-
- sdc2_off: sdc2-off {
- pinconf-clk {
- pins = "sdc2_clk";
- bias-disable;
- drive-strength = <2>;
- };
-
- pinconf-cmd {
- pins = "sdc2_cmd";
- bias-pull-up;
- drive-strength = <2>;
- };
-
- pinconf-data {
- pins = "sdc2_data";
- bias-pull-up;
- drive-strength = <2>;
- };
-
- pinconf-sd-cd {
- pins = "gpio69";
- bias-disable;
- drive-strength = <2>;
- };
- };
};
remoteproc_mpss: remoteproc@4080000 {
--
2.32.0.rc0.204.g9fa02ecfa5-goog
Some SC7180 based board do not have external pull-up for cd-gpio.
Set this pin to internal pull-up for sleep config to avoid frequent
regulator toggle events.
Signed-off-by: Sujit Kautkar <[email protected]>
---
Changes in v3:
- remove 'trogdor' from commit message
- move reference patch from commit message
Changes in v2:
- added pull-up for IDP
This change is with reference to Qualcomm's DT change posted at:
https://patchwork.kernel.org/patch/11675347/
arch/arm64/boot/dts/qcom/sc7180-idp.dts | 2 +-
arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/arm64/boot/dts/qcom/sc7180-idp.dts b/arch/arm64/boot/dts/qcom/sc7180-idp.dts
index 07133e0af581a..0c255edb7f3c3 100644
--- a/arch/arm64/boot/dts/qcom/sc7180-idp.dts
+++ b/arch/arm64/boot/dts/qcom/sc7180-idp.dts
@@ -696,7 +696,7 @@ pinconf-data {
pinconf-sd-cd {
pins = "gpio69";
- bias-disable;
+ bias-pull-up;
drive-strength = <2>;
};
};
diff --git a/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi b/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi
index d128a0ed6ad3a..330deb4967ca2 100644
--- a/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi
+++ b/arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi
@@ -1638,7 +1638,7 @@ pinconf-data {
pinconf-sd-cd {
pins = "gpio69";
- bias-disable;
+ bias-pull-up;
drive-strength = <2>;
};
};
--
2.32.0.rc0.204.g9fa02ecfa5-goog
Hi,
On Wed, Jun 2, 2021 at 12:14 PM Sujit Kautkar <[email protected]> wrote:
>
> Move sdc1/sdc2 pinconf from SoC specific DT file to board specific DT
> files
>
> Signed-off-by: Sujit Kautkar <[email protected]>
> ---
>
> (no changes since v1)
>
> arch/arm64/boot/dts/qcom/sc7180-idp.dts | 102 +++++++++++++++++++
> arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi | 102 +++++++++++++++++++
> arch/arm64/boot/dts/qcom/sc7180.dtsi | 102 -------------------
> 3 files changed, 204 insertions(+), 102 deletions(-)
FYI: Since there were no changes from v2 so you should have kept my
reviewed-by tag from v2. Here it is again, though:
Reviewed-by: Douglas Anderson <[email protected]>
Hi,
On Wed, Jun 2, 2021 at 12:14 PM Sujit Kautkar <[email protected]> wrote:
>
> Some SC7180 based board do not have external pull-up for cd-gpio.
nit: s/board/boards
Presumably Bjorn could fix this when he applies the patch. I wouldn't
re-post just for this fix unless Bjorn asks you to.
> Set this pin to internal pull-up for sleep config to avoid frequent
> regulator toggle events.
>
> Signed-off-by: Sujit Kautkar <[email protected]>
> ---
>
> Changes in v3:
> - remove 'trogdor' from commit message
> - move reference patch from commit message
>
> Changes in v2:
> - added pull-up for IDP
>
> This change is with reference to Qualcomm's DT change posted at:
> https://patchwork.kernel.org/patch/11675347/
>
> arch/arm64/boot/dts/qcom/sc7180-idp.dts | 2 +-
> arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
FYI: I had my Reviewed-by tag on v2. While you did make changes
between v2 and v3, in this case I don't think the changes were
significant enough to warrant removing my Reviewed-by tag and I would
have been happy if you'd kept it.
In general, if you ever have questions about whether you should keep
someone's reviewed tag, it never hurts to mention your logic "after
the cut" (I think you use patman so this would be "Commit-notes:").
For instance, you could say this if you removed Reviewed-by tags:
I totally recombobulated the frobnication logic in v3 and removed
previous Reviewed-by tags. Hopefully reviewers can re-add if they
still think the patch is good.
...or, you could say this if you kept them but you weren't totally
sure it was OK:
Even though every single line in the v3 patch changed from v2, it's
only because I fixed a stoopid spelling Mistake. Thus, I kept previous
Reviewed-by tags. Please yell if you object. Who knew that the only
acceptable spelling of the English word "stupid" in kerneldoc comments
was written as "stoopid". Live and learn.
:-)
In any case, here's my Reviewed-by tag again. I also agree that
Bjorn's comments made sense and were good to fix...
Reviewed-by: Douglas Anderson <[email protected]>
Hi,
On Thu, Jun 03, 2021 at 01:33:07PM -0700, Doug Anderson wrote:
> Hi,
>
> On Wed, Jun 2, 2021 at 12:14 PM Sujit Kautkar <[email protected]> wrote:
> >
> > Some SC7180 based board do not have external pull-up for cd-gpio.
>
> nit: s/board/boards
>
> Presumably Bjorn could fix this when he applies the patch. I wouldn't
> re-post just for this fix unless Bjorn asks you to.
I can repost this patch again with this fix if required
> FYI: I had my Reviewed-by tag on v2. While you did make changes
> between v2 and v3, in this case I don't think the changes were
> significant enough to warrant removing my Reviewed-by tag and I would
> have been happy if you'd kept it.
>
> In general, if you ever have questions about whether you should keep
> someone's reviewed tag, it never hurts to mention your logic "after
> the cut" (I think you use patman so this would be "Commit-notes:").
> For instance, you could say this if you removed Reviewed-by tags:
>
It is good to know this.
> I totally recombobulated the frobnication logic in v3 and removed
> previous Reviewed-by tags. Hopefully reviewers can re-add if they
> still think the patch is good.
>
> ...or, you could say this if you kept them but you weren't totally
> sure it was OK:
>
> Even though every single line in the v3 patch changed from v2, it's
> only because I fixed a stoopid spelling Mistake. Thus, I kept previous
> Reviewed-by tags. Please yell if you object. Who knew that the only
> acceptable spelling of the English word "stupid" in kerneldoc comments
> was written as "stoopid". Live and learn.
>
> :-)
>
> In any case, here's my Reviewed-by tag again. I also agree that
> Bjorn's comments made sense and were good to fix...
>
> Reviewed-by: Douglas Anderson <[email protected]>
Thanks for adding review tag again. I intended to keep this tag since
only commit message is updated, but I forgot to add it back while
posting latest version.
-Sujit