diff mbox series

[v1,2/2] arm64: dts: qcom: sc7180: trogdor: SD-card GPIO pin set bias-pull up

Message ID 20210521130511.v1.2.I52f30ddfe62041b7e6c3c362f0ad8f695ac28224@changeid (mailing list archive)
State Superseded
Headers show
Series Update sd card pinconf for sc7180 DT | expand

Commit Message

Sujit Kautkar May 21, 2021, 8:05 p.m. UTC
Trogdor board does not have external pull-up for cd-gpio. Set this pin
to internal pull-up for sleep config to avoid frequent regulator toggle
events.

This change is aligned with Qualcomm's DT change posted at:
https://patchwork.kernel.org/patch/11675347/

Signed-off-by: Sujit Kautkar <sujitka@chromium.org>
---

 arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Doug Anderson May 21, 2021, 9:15 p.m. UTC | #1
Hi,

On Fri, May 21, 2021 at 1:06 PM Sujit Kautkar <sujitka@chromium.org> wrote:
>
> Trogdor board does not have external pull-up for cd-gpio. Set this pin
> to internal pull-up for sleep config to avoid frequent regulator toggle
> events.
>
> This change is aligned with Qualcomm's DT change posted at:
> https://patchwork.kernel.org/patch/11675347/
>
> Signed-off-by: Sujit Kautkar <sujitka@chromium.org>
> ---
>
>  arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> 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;

This looks fine to me. Honestly, I would have done it for IDP too. It
really doesn't make any sense that the pull-up would be enabled for
the "on" state but disabled for the "off" state. Either you have an
external pull (in which case you never need the internal one) or you
don't have an external pull (in which case you always need the
internal one).

In any case, this change is correct and improves things. I'll add:

Reviewed-by: Douglas Anderson <dianders@chromium.org>

If you do respin the patch to fix IDP too then you can feel free to
keep my Reviewed-by tag.


-Doug
diff mbox series

Patch

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>;
 		};
 	};