All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] mmc: dw_mmc: fix the wrong operation for reset controller
@ 2016-10-31  2:49 Jaehoon Chung
  2016-10-31  2:49   ` Jaehoon Chung
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Jaehoon Chung @ 2016-10-31  2:49 UTC (permalink / raw)
  To: linux-mmc, devicetree
  Cc: ulf.hansson, robh+dt, mark.rutland, linux-kernel, john.stultz,
	guodong.xu, leo.yan, vincent.guittot, Jaehoon Chung

This patch adds the "reset-names" as reset controller for dwmmc controller.
Linaro guys had reported the issue about booting stuck.

Some SoCs are enabled the CONFIG_RESET_CONTROLLER.
then dwmmc controller are waiting for getting reset controller.
But if doesn't define "resets" property in device-tree, it should be stuck.

If use the reset-names as reset controller for dwmmc controller,
it's more stable than now.
This commit is related with the below commit.

Fixes: d6786fefe816 ("mmc: dw_mmc: add reset support to dwmmc host controller")

Jaehoon Chung (2):
  Documentation: synopsys-dw-mshc: add binding for reset-names
  mmc: dw_mmc: add the "reset" as name of reset controller

 Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt | 5 +++++
 drivers/mmc/host/dw_mmc.c                                  | 2 +-
 2 files changed, 6 insertions(+), 1 deletion(-)

-- 
2.10.1

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

* [PATCH 1/2] Documentation: synopsys-dw-mshc: add binding for reset-names
@ 2016-10-31  2:49   ` Jaehoon Chung
  0 siblings, 0 replies; 10+ messages in thread
From: Jaehoon Chung @ 2016-10-31  2:49 UTC (permalink / raw)
  To: linux-mmc, devicetree
  Cc: ulf.hansson, robh+dt, mark.rutland, linux-kernel, john.stultz,
	guodong.xu, leo.yan, vincent.guittot, Jaehoon Chung

Add reset-names property for binding dw-mmc controller.
It might be used together with "reset" property.
-  Note: It must be "reset" as name.

Fixes: d6786fefe816 ("mmc: dw_mmc: add reset support to dwmmc host controller")

Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
---
 Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt b/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt
index 4e00e85..bfa461a 100644
--- a/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt
+++ b/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt
@@ -43,6 +43,9 @@ Optional properties:
   reset signal present internally in some host controller IC designs.
   See Documentation/devicetree/bindings/reset/reset.txt for details.
 
+* reset-names: request name for using "resets" property. Must be "reset".
+	(It will be used together with "resets" property.)
+
 * clocks: from common clock binding: handle to biu and ciu clocks for the
   bus interface unit clock and the card interface unit clock.
 
@@ -103,6 +106,8 @@ board specific portions as listed below.
 		interrupts = <0 75 0>;
 		#address-cells = <1>;
 		#size-cells = <0>;
+		resets = <&rst 20>;
+		reset-names = "reset";
 	};
 
 [board specific internal DMA resources]
-- 
2.10.1

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

* [PATCH 1/2] Documentation: synopsys-dw-mshc: add binding for reset-names
@ 2016-10-31  2:49   ` Jaehoon Chung
  0 siblings, 0 replies; 10+ messages in thread
From: Jaehoon Chung @ 2016-10-31  2:49 UTC (permalink / raw)
  To: linux-mmc-u79uwXL29TY76Z2rM5mHXA, devicetree-u79uwXL29TY76Z2rM5mHXA
  Cc: ulf.hansson-QSEj5FYQhm4dnm+yROfE0A,
	robh+dt-DgEjT+Ai2ygdnm+yROfE0A, mark.rutland-5wv7dgnIgG8,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	john.stultz-QSEj5FYQhm4dnm+yROfE0A,
	guodong.xu-QSEj5FYQhm4dnm+yROfE0A,
	leo.yan-QSEj5FYQhm4dnm+yROfE0A,
	vincent.guittot-QSEj5FYQhm4dnm+yROfE0A, Jaehoon Chung

Add reset-names property for binding dw-mmc controller.
It might be used together with "reset" property.
-  Note: It must be "reset" as name.

Fixes: d6786fefe816 ("mmc: dw_mmc: add reset support to dwmmc host controller")

Signed-off-by: Jaehoon Chung <jh80.chung-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
---
 Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt b/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt
index 4e00e85..bfa461a 100644
--- a/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt
+++ b/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt
@@ -43,6 +43,9 @@ Optional properties:
   reset signal present internally in some host controller IC designs.
   See Documentation/devicetree/bindings/reset/reset.txt for details.
 
+* reset-names: request name for using "resets" property. Must be "reset".
+	(It will be used together with "resets" property.)
+
 * clocks: from common clock binding: handle to biu and ciu clocks for the
   bus interface unit clock and the card interface unit clock.
 
@@ -103,6 +106,8 @@ board specific portions as listed below.
 		interrupts = <0 75 0>;
 		#address-cells = <1>;
 		#size-cells = <0>;
+		resets = <&rst 20>;
+		reset-names = "reset";
 	};
 
 [board specific internal DMA resources]
-- 
2.10.1

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* [PATCH 2/2] mmc: dw_mmc: add the "reset" as name of reset controller
  2016-10-31  2:49 [PATCH 0/2] mmc: dw_mmc: fix the wrong operation for reset controller Jaehoon Chung
  2016-10-31  2:49   ` Jaehoon Chung
@ 2016-10-31  2:49 ` Jaehoon Chung
  2016-11-01 21:56   ` John Stultz
  2 siblings, 0 replies; 10+ messages in thread
From: Jaehoon Chung @ 2016-10-31  2:49 UTC (permalink / raw)
  To: linux-mmc, devicetree
  Cc: ulf.hansson, robh+dt, mark.rutland, linux-kernel, john.stultz,
	guodong.xu, leo.yan, vincent.guittot, Jaehoon Chung

Add the "reset" as name of reset controller.
This is for preventing the wrong operation. Even if some SoC has reset
controller, doesn't define "resets" in device-tree.
Then it might be waiting for reset controller and it should be stuck.

Fixes: d6786fefe816 ("mmc: dw_mmc: add reset support to dwmmc host controller")

Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
---
 drivers/mmc/host/dw_mmc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/dw_mmc.c b/drivers/mmc/host/dw_mmc.c
index 1c9ee36..a16c537 100644
--- a/drivers/mmc/host/dw_mmc.c
+++ b/drivers/mmc/host/dw_mmc.c
@@ -2940,7 +2940,7 @@ static struct dw_mci_board *dw_mci_parse_dt(struct dw_mci *host)
 		return ERR_PTR(-ENOMEM);
 
 	/* find reset controller when exist */
-	pdata->rstc = devm_reset_control_get_optional(dev, NULL);
+	pdata->rstc = devm_reset_control_get_optional(dev, "reset");
 	if (IS_ERR(pdata->rstc)) {
 		if (PTR_ERR(pdata->rstc) == -EPROBE_DEFER)
 			return ERR_PTR(-EPROBE_DEFER);
-- 
2.10.1

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

* Re: [PATCH 0/2] mmc: dw_mmc: fix the wrong operation for reset controller
  2016-10-31  2:49 [PATCH 0/2] mmc: dw_mmc: fix the wrong operation for reset controller Jaehoon Chung
@ 2016-11-01 21:56   ` John Stultz
  2016-10-31  2:49 ` [PATCH 2/2] mmc: dw_mmc: add the "reset" as name of reset controller Jaehoon Chung
  2016-11-01 21:56   ` John Stultz
  2 siblings, 0 replies; 10+ messages in thread
From: John Stultz @ 2016-11-01 21:56 UTC (permalink / raw)
  To: Jaehoon Chung
  Cc: linux-mmc,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	Ulf Hansson, Rob Herring, Mark Rutland, lkml, Guodong Xu,
	Leo Yan, Vincent Guittot

On Sun, Oct 30, 2016 at 7:49 PM, Jaehoon Chung <jh80.chung@samsung.com> wrote:
> This patch adds the "reset-names" as reset controller for dwmmc controller.
> Linaro guys had reported the issue about booting stuck.
>
> Some SoCs are enabled the CONFIG_RESET_CONTROLLER.
> then dwmmc controller are waiting for getting reset controller.
> But if doesn't define "resets" property in device-tree, it should be stuck.
>
> If use the reset-names as reset controller for dwmmc controller,
> it's more stable than now.
> This commit is related with the below commit.
>
> Fixes: d6786fefe816 ("mmc: dw_mmc: add reset support to dwmmc host controller")

So I wasn't hit by the issue, as I don't tend to boot from SD on my
hikey, but I did run these patches and I'm not seeing any issues with
my Android environment.

So for what its worth:
Acked-by: John Stultz <john.stultz@linaro.org>

thanks
-john

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

* Re: [PATCH 0/2] mmc: dw_mmc: fix the wrong operation for reset controller
@ 2016-11-01 21:56   ` John Stultz
  0 siblings, 0 replies; 10+ messages in thread
From: John Stultz @ 2016-11-01 21:56 UTC (permalink / raw)
  To: Jaehoon Chung
  Cc: linux-mmc,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	Ulf Hansson, Rob Herring, Mark Rutland, lkml, Guodong Xu,
	Leo Yan, Vincent Guittot

On Sun, Oct 30, 2016 at 7:49 PM, Jaehoon Chung <jh80.chung@samsung.com> wrote:
> This patch adds the "reset-names" as reset controller for dwmmc controller.
> Linaro guys had reported the issue about booting stuck.
>
> Some SoCs are enabled the CONFIG_RESET_CONTROLLER.
> then dwmmc controller are waiting for getting reset controller.
> But if doesn't define "resets" property in device-tree, it should be stuck.
>
> If use the reset-names as reset controller for dwmmc controller,
> it's more stable than now.
> This commit is related with the below commit.
>
> Fixes: d6786fefe816 ("mmc: dw_mmc: add reset support to dwmmc host controller")

So I wasn't hit by the issue, as I don't tend to boot from SD on my
hikey, but I did run these patches and I'm not seeing any issues with
my Android environment.

So for what its worth:
Acked-by: John Stultz <john.stultz@linaro.org>

thanks
-john

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

* Re: [PATCH 0/2] mmc: dw_mmc: fix the wrong operation for reset controller
@ 2016-11-03  5:19     ` Jaehoon Chung
  0 siblings, 0 replies; 10+ messages in thread
From: Jaehoon Chung @ 2016-11-03  5:19 UTC (permalink / raw)
  To: John Stultz
  Cc: linux-mmc,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	Ulf Hansson, Rob Herring, Mark Rutland, lkml, Guodong Xu,
	Leo Yan, Vincent Guittot

Hi,

On 11/02/2016 06:56 AM, John Stultz wrote:
> On Sun, Oct 30, 2016 at 7:49 PM, Jaehoon Chung <jh80.chung@samsung.com> wrote:
>> This patch adds the "reset-names" as reset controller for dwmmc controller.
>> Linaro guys had reported the issue about booting stuck.
>>
>> Some SoCs are enabled the CONFIG_RESET_CONTROLLER.
>> then dwmmc controller are waiting for getting reset controller.
>> But if doesn't define "resets" property in device-tree, it should be stuck.
>>
>> If use the reset-names as reset controller for dwmmc controller,
>> it's more stable than now.
>> This commit is related with the below commit.
>>
>> Fixes: d6786fefe816 ("mmc: dw_mmc: add reset support to dwmmc host controller")
> 
> So I wasn't hit by the issue, as I don't tend to boot from SD on my
> hikey, but I did run these patches and I'm not seeing any issues with
> my Android environment.
> 
> So for what its worth:
> Acked-by: John Stultz <john.stultz@linaro.org>

Applied on my repository (fixes branch).

Best Regards,
Jaehoon Chung

> 
> thanks
> -john
> 
> 
> 

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

* Re: [PATCH 0/2] mmc: dw_mmc: fix the wrong operation for reset controller
@ 2016-11-03  5:19     ` Jaehoon Chung
  0 siblings, 0 replies; 10+ messages in thread
From: Jaehoon Chung @ 2016-11-03  5:19 UTC (permalink / raw)
  To: John Stultz
  Cc: linux-mmc,
	open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS,
	Ulf Hansson, Rob Herring, Mark Rutland, lkml, Guodong Xu,
	Leo Yan, Vincent Guittot

Hi,

On 11/02/2016 06:56 AM, John Stultz wrote:
> On Sun, Oct 30, 2016 at 7:49 PM, Jaehoon Chung <jh80.chung-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org> wrote:
>> This patch adds the "reset-names" as reset controller for dwmmc controller.
>> Linaro guys had reported the issue about booting stuck.
>>
>> Some SoCs are enabled the CONFIG_RESET_CONTROLLER.
>> then dwmmc controller are waiting for getting reset controller.
>> But if doesn't define "resets" property in device-tree, it should be stuck.
>>
>> If use the reset-names as reset controller for dwmmc controller,
>> it's more stable than now.
>> This commit is related with the below commit.
>>
>> Fixes: d6786fefe816 ("mmc: dw_mmc: add reset support to dwmmc host controller")
> 
> So I wasn't hit by the issue, as I don't tend to boot from SD on my
> hikey, but I did run these patches and I'm not seeing any issues with
> my Android environment.
> 
> So for what its worth:
> Acked-by: John Stultz <john.stultz-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>

Applied on my repository (fixes branch).

Best Regards,
Jaehoon Chung

> 
> thanks
> -john
> 
> 
> 

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH 1/2] Documentation: synopsys-dw-mshc: add binding for reset-names
@ 2016-11-09 18:24     ` Rob Herring
  0 siblings, 0 replies; 10+ messages in thread
From: Rob Herring @ 2016-11-09 18:24 UTC (permalink / raw)
  To: Jaehoon Chung
  Cc: linux-mmc, devicetree, ulf.hansson, mark.rutland, linux-kernel,
	john.stultz, guodong.xu, leo.yan, vincent.guittot

On Mon, Oct 31, 2016 at 11:49:41AM +0900, Jaehoon Chung wrote:
> Add reset-names property for binding dw-mmc controller.
> It might be used together with "reset" property.
> -  Note: It must be "reset" as name.
> 
> Fixes: d6786fefe816 ("mmc: dw_mmc: add reset support to dwmmc host controller")
> 
> Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
> ---
>  Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt b/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt
> index 4e00e85..bfa461a 100644
> --- a/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt
> +++ b/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt
> @@ -43,6 +43,9 @@ Optional properties:
>    reset signal present internally in some host controller IC designs.
>    See Documentation/devicetree/bindings/reset/reset.txt for details.
>  
> +* reset-names: request name for using "resets" property. Must be "reset".
> +	(It will be used together with "resets" property.)

There is no point in having names for a single reset. This should be 
fixed in the kernel only if this causes a problem.

Rob

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

* Re: [PATCH 1/2] Documentation: synopsys-dw-mshc: add binding for reset-names
@ 2016-11-09 18:24     ` Rob Herring
  0 siblings, 0 replies; 10+ messages in thread
From: Rob Herring @ 2016-11-09 18:24 UTC (permalink / raw)
  To: Jaehoon Chung
  Cc: linux-mmc-u79uwXL29TY76Z2rM5mHXA,
	devicetree-u79uwXL29TY76Z2rM5mHXA,
	ulf.hansson-QSEj5FYQhm4dnm+yROfE0A, mark.rutland-5wv7dgnIgG8,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	john.stultz-QSEj5FYQhm4dnm+yROfE0A,
	guodong.xu-QSEj5FYQhm4dnm+yROfE0A,
	leo.yan-QSEj5FYQhm4dnm+yROfE0A,
	vincent.guittot-QSEj5FYQhm4dnm+yROfE0A

On Mon, Oct 31, 2016 at 11:49:41AM +0900, Jaehoon Chung wrote:
> Add reset-names property for binding dw-mmc controller.
> It might be used together with "reset" property.
> -  Note: It must be "reset" as name.
> 
> Fixes: d6786fefe816 ("mmc: dw_mmc: add reset support to dwmmc host controller")
> 
> Signed-off-by: Jaehoon Chung <jh80.chung-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
> ---
>  Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt b/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt
> index 4e00e85..bfa461a 100644
> --- a/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt
> +++ b/Documentation/devicetree/bindings/mmc/synopsys-dw-mshc.txt
> @@ -43,6 +43,9 @@ Optional properties:
>    reset signal present internally in some host controller IC designs.
>    See Documentation/devicetree/bindings/reset/reset.txt for details.
>  
> +* reset-names: request name for using "resets" property. Must be "reset".
> +	(It will be used together with "resets" property.)

There is no point in having names for a single reset. This should be 
fixed in the kernel only if this causes a problem.

Rob
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

end of thread, other threads:[~2016-11-09 18:24 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-10-31  2:49 [PATCH 0/2] mmc: dw_mmc: fix the wrong operation for reset controller Jaehoon Chung
2016-10-31  2:49 ` [PATCH 1/2] Documentation: synopsys-dw-mshc: add binding for reset-names Jaehoon Chung
2016-10-31  2:49   ` Jaehoon Chung
2016-11-09 18:24   ` Rob Herring
2016-11-09 18:24     ` Rob Herring
2016-10-31  2:49 ` [PATCH 2/2] mmc: dw_mmc: add the "reset" as name of reset controller Jaehoon Chung
2016-11-01 21:56 ` [PATCH 0/2] mmc: dw_mmc: fix the wrong operation for " John Stultz
2016-11-01 21:56   ` John Stultz
2016-11-03  5:19   ` Jaehoon Chung
2016-11-03  5:19     ` Jaehoon Chung

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.