linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] arm64/hisilicon: fix SDcard detection
@ 2019-01-14  8:24 Vincent Guittot
  2019-01-14  8:28 ` Linus Walleij
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Vincent Guittot @ 2019-01-14  8:24 UTC (permalink / raw)
  To: xuwei5, robh+dt, mark.rutland, linux-arm-kernel, devicetree,
	linux-kernel, linus.walleij
  Cc: Vincent Guittot

The SDcard detection of hikey960 is active low so cd-inverted is wrong.
Instead of adding cd-inverted, we should better set correctly cd-gpios
to use GPIO_ACTIVE_LOW.

Signed-off-by: Vincent Guittot <vincent.guittot@linaro.org>
---

SD card detection was not working on v5.0-rc1 but patch
https://marc.info/?l=linux-mmc&m=154637189021211&w=2 makes it work.
Nevertheles, latest changes in of_mmc_detection makes possible to have 
a correct DT config.

 arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts b/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts
index 71bfe41..dc314e7 100644
--- a/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts
+++ b/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts
@@ -665,8 +665,7 @@
 	sd-uhs-sdr50;
 	sd-uhs-sdr104;
 	disable-wp;
-	cd-inverted;
-	cd-gpios = <&gpio25 3 0>;
+	cd-gpios = <&gpio25 3 GPIO_ACTIVE_LOW>;
 	pinctrl-names = "default";
 	pinctrl-0 = <&sd_pmx_func
 		     &sd_clk_cfg_func
-- 
2.7.4


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

* Re: [PATCH v2] arm64/hisilicon: fix SDcard detection
  2019-01-14  8:24 [PATCH v2] arm64/hisilicon: fix SDcard detection Vincent Guittot
@ 2019-01-14  8:28 ` Linus Walleij
  2019-01-14  8:36 ` Leo Yan
  2019-02-01 17:00 ` Wei Xu
  2 siblings, 0 replies; 5+ messages in thread
From: Linus Walleij @ 2019-01-14  8:28 UTC (permalink / raw)
  To: Vincent Guittot
  Cc: Xu Wei, Rob Herring, Mark Rutland, Linux ARM,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	linux-kernel

On Mon, Jan 14, 2019 at 9:24 AM Vincent Guittot
<vincent.guittot@linaro.org> wrote:

> The SDcard detection of hikey960 is active low so cd-inverted is wrong.
> Instead of adding cd-inverted, we should better set correctly cd-gpios
> to use GPIO_ACTIVE_LOW.
>
> Signed-off-by: Vincent Guittot <vincent.guittot@linaro.org>

Reviewed-by: Linus Walleij <linus.walleij@linaro.org>

Yours,
Linus Walleij

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

* Re: [PATCH v2] arm64/hisilicon: fix SDcard detection
  2019-01-14  8:24 [PATCH v2] arm64/hisilicon: fix SDcard detection Vincent Guittot
  2019-01-14  8:28 ` Linus Walleij
@ 2019-01-14  8:36 ` Leo Yan
  2019-02-01 17:00 ` Wei Xu
  2 siblings, 0 replies; 5+ messages in thread
From: Leo Yan @ 2019-01-14  8:36 UTC (permalink / raw)
  To: Vincent Guittot
  Cc: xuwei5, robh+dt, mark.rutland, linux-arm-kernel, devicetree,
	linux-kernel, linus.walleij

Hi Vincent,

On Mon, Jan 14, 2019 at 09:24:34AM +0100, Vincent Guittot wrote:
> The SDcard detection of hikey960 is active low so cd-inverted is wrong.
> Instead of adding cd-inverted, we should better set correctly cd-gpios
> to use GPIO_ACTIVE_LOW.

Just remind, usually ARM maintainer has requirement for subject as:
'arm64: dts: hikey960: xxxx'.

> Signed-off-by: Vincent Guittot <vincent.guittot@linaro.org>
> ---
> 
> SD card detection was not working on v5.0-rc1 but patch
> https://marc.info/?l=linux-mmc&m=154637189021211&w=2 makes it work.
> Nevertheles, latest changes in of_mmc_detection makes possible to have 
> a correct DT config.
> 
>  arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts b/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts
> index 71bfe41..dc314e7 100644
> --- a/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts
> +++ b/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts
> @@ -665,8 +665,7 @@
>  	sd-uhs-sdr50;
>  	sd-uhs-sdr104;
>  	disable-wp;
> -	cd-inverted;
> -	cd-gpios = <&gpio25 3 0>;
> +	cd-gpios = <&gpio25 3 GPIO_ACTIVE_LOW>;
>  	pinctrl-names = "default";
>  	pinctrl-0 = <&sd_pmx_func
>  		     &sd_clk_cfg_func
> -- 
> 2.7.4
> 

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

* Re: [PATCH v2] arm64/hisilicon: fix SDcard detection
  2019-01-14  8:24 [PATCH v2] arm64/hisilicon: fix SDcard detection Vincent Guittot
  2019-01-14  8:28 ` Linus Walleij
  2019-01-14  8:36 ` Leo Yan
@ 2019-02-01 17:00 ` Wei Xu
  2019-02-02  8:52   ` Vincent Guittot
  2 siblings, 1 reply; 5+ messages in thread
From: Wei Xu @ 2019-02-01 17:00 UTC (permalink / raw)
  To: Vincent Guittot, robh+dt, mark.rutland, linux-arm-kernel,
	devicetree, linux-kernel, linus.walleij

Hi Vincent,

On 1/14/2019 8:24 AM, Vincent Guittot wrote:
> The SDcard detection of hikey960 is active low so cd-inverted is wrong.
> Instead of adding cd-inverted, we should better set correctly cd-gpios
> to use GPIO_ACTIVE_LOW.
> 
> Signed-off-by: Vincent Guittot <vincent.guittot@linaro.org>

Updated the subject as Leo suggested and applied to the hisilicon tree.
Thanks!

Best Regards,
Wei

> ---
> 
> SD card detection was not working on v5.0-rc1 but patch
> https://marc.info/?l=linux-mmc&m=154637189021211&w=2 makes it work.
> Nevertheles, latest changes in of_mmc_detection makes possible to have 
> a correct DT config.
> 
>  arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts b/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts
> index 71bfe41..dc314e7 100644
> --- a/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts
> +++ b/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts
> @@ -665,8 +665,7 @@
>  	sd-uhs-sdr50;
>  	sd-uhs-sdr104;
>  	disable-wp;
> -	cd-inverted;
> -	cd-gpios = <&gpio25 3 0>;
> +	cd-gpios = <&gpio25 3 GPIO_ACTIVE_LOW>;
>  	pinctrl-names = "default";
>  	pinctrl-0 = <&sd_pmx_func
>  		     &sd_clk_cfg_func
> 


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

* Re: [PATCH v2] arm64/hisilicon: fix SDcard detection
  2019-02-01 17:00 ` Wei Xu
@ 2019-02-02  8:52   ` Vincent Guittot
  0 siblings, 0 replies; 5+ messages in thread
From: Vincent Guittot @ 2019-02-02  8:52 UTC (permalink / raw)
  To: Wei Xu
  Cc: Rob Herring, Mark Rutland, LAK,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	linux-kernel, Linus Walleij

Hi Wei,

On Fri, 1 Feb 2019 at 18:00, Wei Xu <xuwei5@hisilicon.com> wrote:
>
> Hi Vincent,
>
> On 1/14/2019 8:24 AM, Vincent Guittot wrote:
> > The SDcard detection of hikey960 is active low so cd-inverted is wrong.
> > Instead of adding cd-inverted, we should better set correctly cd-gpios
> > to use GPIO_ACTIVE_LOW.
> >
> > Signed-off-by: Vincent Guittot <vincent.guittot@linaro.org>
>
> Updated the subject as Leo suggested and applied to the hisilicon tree.

Thanks

> Thanks!
>
> Best Regards,
> Wei
>
> > ---
> >
> > SD card detection was not working on v5.0-rc1 but patch
> > https://marc.info/?l=linux-mmc&m=154637189021211&w=2 makes it work.
> > Nevertheles, latest changes in of_mmc_detection makes possible to have
> > a correct DT config.
> >
> >  arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts | 3 +--
> >  1 file changed, 1 insertion(+), 2 deletions(-)
> >
> > diff --git a/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts b/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts
> > index 71bfe41..dc314e7 100644
> > --- a/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts
> > +++ b/arch/arm64/boot/dts/hisilicon/hi3660-hikey960.dts
> > @@ -665,8 +665,7 @@
> >       sd-uhs-sdr50;
> >       sd-uhs-sdr104;
> >       disable-wp;
> > -     cd-inverted;
> > -     cd-gpios = <&gpio25 3 0>;
> > +     cd-gpios = <&gpio25 3 GPIO_ACTIVE_LOW>;
> >       pinctrl-names = "default";
> >       pinctrl-0 = <&sd_pmx_func
> >                    &sd_clk_cfg_func
> >
>

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

end of thread, other threads:[~2019-02-02  8:53 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-14  8:24 [PATCH v2] arm64/hisilicon: fix SDcard detection Vincent Guittot
2019-01-14  8:28 ` Linus Walleij
2019-01-14  8:36 ` Leo Yan
2019-02-01 17:00 ` Wei Xu
2019-02-02  8:52   ` Vincent Guittot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).