linux-mmc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci
       [not found] <4CC0A281.1010202@eukrea.com>
@ 2010-10-21 21:20 ` Eric Bénard
  2010-10-22  6:15   ` Wolfram Sang
  2010-10-22 23:12   ` Chris Ball
  2010-10-21 21:20 ` Eric Bénard
  1 sibling, 2 replies; 12+ messages in thread
From: Eric Bénard @ 2010-10-21 21:20 UTC (permalink / raw)
  To: linux-mmc
  Cc: linux-arm-kernel, shawn.gsc, w.sang, nicolas.pitre, r65037,
	amit.kucheria, Eric Bénard

this patch fix timeout problems on i.MX's sdhci as suggested by
Richard Zhu.

Tested on :
- i.MX257 : not needed
- i.MX357 : needed
- i.MX515 : needed

more details can be found here :
http://lists.infradead.org/pipermail/linux-arm-kernel/2010-October/029748.html

Signed-off-by: Eric Bénard <eric@eukrea.com>
Tested-by: Shawn Guo <shawn.gsc@gmail.com>
---
 drivers/mmc/host/sdhci-esdhc-imx.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/drivers/mmc/host/sdhci-esdhc-imx.c b/drivers/mmc/host/sdhci-esdhc-imx.c
index afbac9a..11e1ae1 100644
--- a/drivers/mmc/host/sdhci-esdhc-imx.c
+++ b/drivers/mmc/host/sdhci-esdhc-imx.c
@@ -130,6 +130,12 @@ static int esdhc_pltfm_init(struct sdhci_host *host, struct sdhci_pltfm_data *pd
 		gpio_request(boarddata->wp_gpio, "SD_WP");
 		gpio_direction_input(boarddata->wp_gpio);
 	}
+
+	if (cpu_is_mx35() || cpu_is_mx51()) {
+		dev_info(mmc_dev(host->mmc), "using broken timeout quirk\n");
+		host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL;
+	}
+
 	return 0;
 }
 
-- 
1.7.0.4


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

* [PATCH 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35
       [not found] <4CC0A281.1010202@eukrea.com>
  2010-10-21 21:20 ` [PATCH 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci Eric Bénard
@ 2010-10-21 21:20 ` Eric Bénard
  2010-10-22  6:18   ` Wolfram Sang
  1 sibling, 1 reply; 12+ messages in thread
From: Eric Bénard @ 2010-10-21 21:20 UTC (permalink / raw)
  To: linux-mmc
  Cc: linux-arm-kernel, shawn.gsc, w.sang, nicolas.pitre, r65037,
	amit.kucheria, Eric Bénard

only these CPU's errata list this bug.

Signed-off-by: Eric Bénard <eric@eukrea.com>
---
 drivers/mmc/host/sdhci-esdhc-imx.c |   10 +++++++---
 1 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/drivers/mmc/host/sdhci-esdhc-imx.c b/drivers/mmc/host/sdhci-esdhc-imx.c
index 11e1ae1..4d67f58 100644
--- a/drivers/mmc/host/sdhci-esdhc-imx.c
+++ b/drivers/mmc/host/sdhci-esdhc-imx.c
@@ -136,6 +136,12 @@ static int esdhc_pltfm_init(struct sdhci_host *host, struct sdhci_pltfm_data *pd
 		host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL;
 	}
 
+	/* fix errata ENGcm07207 which is present on i.MX25 and i.MX35 */
+	if (cpu_is_mx25() || cpu_is_mx35()) {
+		dev_info(mmc_dev(host->mmc), "using ENGcm07207 workaround\n");
+		host->quirks |= SDHCI_QUIRK_NO_MULTIBLOCK;
+	}
+
 	return 0;
 }
 
@@ -162,10 +168,8 @@ static struct sdhci_ops sdhci_esdhc_ops = {
 };
 
 struct sdhci_pltfm_data sdhci_esdhc_imx_pdata = {
-	.quirks = ESDHC_DEFAULT_QUIRKS | SDHCI_QUIRK_NO_MULTIBLOCK
-			| SDHCI_QUIRK_BROKEN_ADMA,
+	.quirks = ESDHC_DEFAULT_QUIRKS | SDHCI_QUIRK_BROKEN_ADMA,
 	/* ADMA has issues. Might be fixable */
-	/* NO_MULTIBLOCK might be MX35 only (Errata: ENGcm07207) */
 	.ops = &sdhci_esdhc_ops,
 	.init = esdhc_pltfm_init,
 	.exit = esdhc_pltfm_exit,
-- 
1.7.0.4


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

* Re: [PATCH 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci
  2010-10-21 21:20 ` [PATCH 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci Eric Bénard
@ 2010-10-22  6:15   ` Wolfram Sang
  2010-10-22 23:12   ` Chris Ball
  1 sibling, 0 replies; 12+ messages in thread
From: Wolfram Sang @ 2010-10-22  6:15 UTC (permalink / raw)
  To: Eric Bénard
  Cc: linux-mmc, linux-arm-kernel, shawn.gsc, nicolas.pitre, r65037,
	amit.kucheria

[-- Attachment #1: Type: text/plain, Size: 1511 bytes --]

On Thu, Oct 21, 2010 at 11:20:27PM +0200, Eric Bénard wrote:
> this patch fix timeout problems on i.MX's sdhci as suggested by
> Richard Zhu.
> 
> Tested on :
> - i.MX257 : not needed
> - i.MX357 : needed
> - i.MX515 : needed
> 
> more details can be found here :
> http://lists.infradead.org/pipermail/linux-arm-kernel/2010-October/029748.html
> 
> Signed-off-by: Eric Bénard <eric@eukrea.com>
> Tested-by: Shawn Guo <shawn.gsc@gmail.com>
> ---
>  drivers/mmc/host/sdhci-esdhc-imx.c |    6 ++++++
>  1 files changed, 6 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/mmc/host/sdhci-esdhc-imx.c b/drivers/mmc/host/sdhci-esdhc-imx.c
> index afbac9a..11e1ae1 100644
> --- a/drivers/mmc/host/sdhci-esdhc-imx.c
> +++ b/drivers/mmc/host/sdhci-esdhc-imx.c
> @@ -130,6 +130,12 @@ static int esdhc_pltfm_init(struct sdhci_host *host, struct sdhci_pltfm_data *pd
>  		gpio_request(boarddata->wp_gpio, "SD_WP");
>  		gpio_direction_input(boarddata->wp_gpio);
>  	}
> +
> +	if (cpu_is_mx35() || cpu_is_mx51()) {
> +		dev_info(mmc_dev(host->mmc), "using broken timeout quirk\n");

Please drop this line. The boot log is full enough IMO :)

Other than that:

Acked-by: Wolfram Sang <w.sang@pengutronix.de>

> +		host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL;
> +	}
> +
>  	return 0;
>  }
>  
> -- 
> 1.7.0.4
> 

-- 
Pengutronix e.K.                           | Wolfram Sang                |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 197 bytes --]

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

* Re: [PATCH 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35
  2010-10-21 21:20 ` Eric Bénard
@ 2010-10-22  6:18   ` Wolfram Sang
  2010-10-22  7:07     ` Eric Bénard
                       ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Wolfram Sang @ 2010-10-22  6:18 UTC (permalink / raw)
  To: Eric Bénard
  Cc: linux-mmc, linux-arm-kernel, shawn.gsc, nicolas.pitre, r65037,
	amit.kucheria

[-- Attachment #1: Type: text/plain, Size: 1728 bytes --]

On Thu, Oct 21, 2010 at 11:20:28PM +0200, Eric Bénard wrote:
> only these CPU's errata list this bug.

So, it was not directly tested?

> 
> Signed-off-by: Eric Bénard <eric@eukrea.com>
> ---
>  drivers/mmc/host/sdhci-esdhc-imx.c |   10 +++++++---
>  1 files changed, 7 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/mmc/host/sdhci-esdhc-imx.c b/drivers/mmc/host/sdhci-esdhc-imx.c
> index 11e1ae1..4d67f58 100644
> --- a/drivers/mmc/host/sdhci-esdhc-imx.c
> +++ b/drivers/mmc/host/sdhci-esdhc-imx.c
> @@ -136,6 +136,12 @@ static int esdhc_pltfm_init(struct sdhci_host *host, struct sdhci_pltfm_data *pd
>  		host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL;
>  	}
>  
> +	/* fix errata ENGcm07207 which is present on i.MX25 and i.MX35 */
> +	if (cpu_is_mx25() || cpu_is_mx35()) {
> +		dev_info(mmc_dev(host->mmc), "using ENGcm07207 workaround\n");

Same here, no printout please (or do you see a reason for it?)

> +		host->quirks |= SDHCI_QUIRK_NO_MULTIBLOCK;
> +	}
> +
>  	return 0;
>  }
>  
> @@ -162,10 +168,8 @@ static struct sdhci_ops sdhci_esdhc_ops = {
>  };
>  
>  struct sdhci_pltfm_data sdhci_esdhc_imx_pdata = {
> -	.quirks = ESDHC_DEFAULT_QUIRKS | SDHCI_QUIRK_NO_MULTIBLOCK
> -			| SDHCI_QUIRK_BROKEN_ADMA,
> +	.quirks = ESDHC_DEFAULT_QUIRKS | SDHCI_QUIRK_BROKEN_ADMA,
>  	/* ADMA has issues. Might be fixable */
> -	/* NO_MULTIBLOCK might be MX35 only (Errata: ENGcm07207) */
>  	.ops = &sdhci_esdhc_ops,
>  	.init = esdhc_pltfm_init,
>  	.exit = esdhc_pltfm_exit,

Other than that, looks good. Thanks.

-- 
Pengutronix e.K.                           | Wolfram Sang                |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 197 bytes --]

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

* Re: [PATCH 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35
  2010-10-22  6:18   ` Wolfram Sang
@ 2010-10-22  7:07     ` Eric Bénard
  2010-10-22  8:46     ` [PATCH v2 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci Eric Bénard
  2010-10-22  8:46     ` [PATCH v2 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35 Eric Bénard
  2 siblings, 0 replies; 12+ messages in thread
From: Eric Bénard @ 2010-10-22  7:07 UTC (permalink / raw)
  To: Wolfram Sang
  Cc: linux-mmc, linux-arm-kernel, shawn.gsc, nicolas.pitre, r65037,
	amit.kucheria

Hi Wolfram,

Le 22/10/2010 08:18, Wolfram Sang a écrit :
> On Thu, Oct 21, 2010 at 11:20:28PM +0200, Eric Bénard wrote:
>> only these CPU's errata list this bug.
>
> So, it was not directly tested?
>
While I was testing the other quirk, I tested this one on 25, 35 & 51, but I 
can't trigger the bug on any of these CPU (without the quirk : the bug suppose 
there is an error reading one block and that the MMC layer then sends CMD12 
which can't stop the AHB transfer and thus the controler stays blocked. As I 
didn't met an error to read a block, I wasn't able to trigger the bug.

Eric

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

* [PATCH v2 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci
  2010-10-22  6:18   ` Wolfram Sang
  2010-10-22  7:07     ` Eric Bénard
@ 2010-10-22  8:46     ` Eric Bénard
  2010-10-22  8:46     ` [PATCH v2 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35 Eric Bénard
  2 siblings, 0 replies; 12+ messages in thread
From: Eric Bénard @ 2010-10-22  8:46 UTC (permalink / raw)
  To: linux-mmc
  Cc: linux-arm-kernel, shawn.gsc, w.sang, nicolas.pitre, r65037,
	amit.kucheria, Eric Bénard

this patch fix timeout problems on i.MX's sdhci as suggested by
Richard Zhu.

Tested on :
- i.MX257 : not needed
- i.MX357 : needed
- i.MX515 : needed

more details can be found here :
http://lists.infradead.org/pipermail/linux-arm-kernel/2010-October/029748.html

Signed-off-by: Eric Bénard <eric@eukrea.com>
Tested-by: Shawn Guo <shawn.gsc@gmail.com>
Acked-by: Wolfram Sang <w.sang@pengutronix.de>
---
 drivers/mmc/host/sdhci-esdhc-imx.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/drivers/mmc/host/sdhci-esdhc-imx.c b/drivers/mmc/host/sdhci-esdhc-imx.c
index afbac9a..31256ad 100644
--- a/drivers/mmc/host/sdhci-esdhc-imx.c
+++ b/drivers/mmc/host/sdhci-esdhc-imx.c
@@ -130,6 +130,10 @@ static int esdhc_pltfm_init(struct sdhci_host *host, struct sdhci_pltfm_data *pd
 		gpio_request(boarddata->wp_gpio, "SD_WP");
 		gpio_direction_input(boarddata->wp_gpio);
 	}
+
+	if (cpu_is_mx35() || cpu_is_mx51())
+		host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL;
+
 	return 0;
 }
 
-- 
1.7.0.4


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

* [PATCH v2 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35
  2010-10-22  6:18   ` Wolfram Sang
  2010-10-22  7:07     ` Eric Bénard
  2010-10-22  8:46     ` [PATCH v2 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci Eric Bénard
@ 2010-10-22  8:46     ` Eric Bénard
  2010-10-22 10:54       ` Wolfram Sang
  2 siblings, 1 reply; 12+ messages in thread
From: Eric Bénard @ 2010-10-22  8:46 UTC (permalink / raw)
  To: linux-mmc
  Cc: linux-arm-kernel, shawn.gsc, w.sang, nicolas.pitre, r65037,
	amit.kucheria, Eric Bénard

only these CPU's errata list this bug.

Signed-off-by: Eric Bénard <eric@eukrea.com>
---
 drivers/mmc/host/sdhci-esdhc-imx.c |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/drivers/mmc/host/sdhci-esdhc-imx.c b/drivers/mmc/host/sdhci-esdhc-imx.c
index 31256ad..14d2836 100644
--- a/drivers/mmc/host/sdhci-esdhc-imx.c
+++ b/drivers/mmc/host/sdhci-esdhc-imx.c
@@ -134,6 +134,10 @@ static int esdhc_pltfm_init(struct sdhci_host *host, struct sdhci_pltfm_data *pd
 	if (cpu_is_mx35() || cpu_is_mx51())
 		host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL;
 
+	/* fix errata ENGcm07207 which is present on i.MX25 and i.MX35 */
+	if (cpu_is_mx25() || cpu_is_mx35())
+		host->quirks |= SDHCI_QUIRK_NO_MULTIBLOCK;
+
 	return 0;
 }
 
@@ -160,10 +164,8 @@ static struct sdhci_ops sdhci_esdhc_ops = {
 };
 
 struct sdhci_pltfm_data sdhci_esdhc_imx_pdata = {
-	.quirks = ESDHC_DEFAULT_QUIRKS | SDHCI_QUIRK_NO_MULTIBLOCK
-			| SDHCI_QUIRK_BROKEN_ADMA,
+	.quirks = ESDHC_DEFAULT_QUIRKS | SDHCI_QUIRK_BROKEN_ADMA,
 	/* ADMA has issues. Might be fixable */
-	/* NO_MULTIBLOCK might be MX35 only (Errata: ENGcm07207) */
 	.ops = &sdhci_esdhc_ops,
 	.init = esdhc_pltfm_init,
 	.exit = esdhc_pltfm_exit,
-- 
1.7.0.4


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

* Re: [PATCH v2 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35
  2010-10-22  8:46     ` [PATCH v2 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35 Eric Bénard
@ 2010-10-22 10:54       ` Wolfram Sang
  0 siblings, 0 replies; 12+ messages in thread
From: Wolfram Sang @ 2010-10-22 10:54 UTC (permalink / raw)
  To: Eric Bénard
  Cc: linux-mmc, linux-arm-kernel, shawn.gsc, nicolas.pitre, r65037,
	amit.kucheria

[-- Attachment #1: Type: text/plain, Size: 204 bytes --]

On Fri, Oct 22, 2010 at 10:46:19AM +0200, Eric Bénard wrote:
> only these CPU's errata list this bug.
> 
> Signed-off-by: Eric Bénard <eric@eukrea.com>
Acked-by: Wolfram Sang <w.sang@pengutronix.de>

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 197 bytes --]

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

* Re: [PATCH 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci
  2010-10-21 21:20 ` [PATCH 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci Eric Bénard
  2010-10-22  6:15   ` Wolfram Sang
@ 2010-10-22 23:12   ` Chris Ball
  2010-10-22 23:57     ` Eric Bénard
  2010-10-22 23:57     ` [PATCH 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35 Eric Bénard
  1 sibling, 2 replies; 12+ messages in thread
From: Chris Ball @ 2010-10-22 23:12 UTC (permalink / raw)
  To: Eric Bénard
  Cc: linux-mmc, linux-arm-kernel, shawn.gsc, w.sang, nicolas.pitre,
	r65037, amit.kucheria

On Thu, Oct 21, 2010 at 11:20:27PM +0200, Eric Bénard wrote:
> this patch fix timeout problems on i.MX's sdhci as suggested by
> Richard Zhu.
> 
> Tested on :
> - i.MX257 : not needed
> - i.MX357 : needed
> - i.MX515 : needed
> 
> more details can be found here :
> http://lists.infradead.org/pipermail/linux-arm-kernel/2010-October/029748.html
> 
> Signed-off-by: Eric Bénard <eric@eukrea.com>
> Tested-by: Shawn Guo <shawn.gsc@gmail.com>
> ---
>  drivers/mmc/host/sdhci-esdhc-imx.c |    6 ++++++
>  1 files changed, 6 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/mmc/host/sdhci-esdhc-imx.c b/drivers/mmc/host/sdhci-esdhc-imx.c
> index afbac9a..11e1ae1 100644
> --- a/drivers/mmc/host/sdhci-esdhc-imx.c
> +++ b/drivers/mmc/host/sdhci-esdhc-imx.c
> @@ -130,6 +130,12 @@ static int esdhc_pltfm_init(struct sdhci_host *host, struct sdhci_pltfm_data *pd
>  		gpio_request(boarddata->wp_gpio, "SD_WP");
>  		gpio_direction_input(boarddata->wp_gpio);
>  	}
> +
> +	if (cpu_is_mx35() || cpu_is_mx51()) {
> +		dev_info(mmc_dev(host->mmc), "using broken timeout quirk\n");
> +		host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL;
> +	}
> +
>  	return 0;
>  }
>  

This has Wolfram's RFC wp-on-gpio patch applied.  Want to repost these
against mmc-next?

I'll plan on leaving this until after -rc1, so that I can send out a
pull request shortly.  Thanks,

-- 
Chris Ball   <cjb@laptop.org>   <http://printf.net/>
One Laptop Per Child

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

* [PATCH 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci
  2010-10-22 23:12   ` Chris Ball
@ 2010-10-22 23:57     ` Eric Bénard
  2010-11-07 22:51       ` Chris Ball
  2010-10-22 23:57     ` [PATCH 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35 Eric Bénard
  1 sibling, 1 reply; 12+ messages in thread
From: Eric Bénard @ 2010-10-22 23:57 UTC (permalink / raw)
  To: cjb
  Cc: linux-mmc, linux-arm-kernel, shawn.gsc, w.sang, nicolas.pitre,
	r65037, amit.kucheria, Eric Bénard

this patch fix timeout problems on i.MX's sdhci as suggested by
Richard Zhu.

Tested on :
- i.MX257 : not needed
- i.MX357 : needed
- i.MX515 : needed

more details can be found here :
http://lists.infradead.org/pipermail/linux-arm-kernel/2010-October/029748.html

Signed-off-by: Eric Bénard <eric@eukrea.com>
Tested-by: Shawn Guo <shawn.gsc@gmail.com>
Acked-by: Wolfram Sang <w.sang@pengutronix.de>
---
 drivers/mmc/host/sdhci-esdhc-imx.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/drivers/mmc/host/sdhci-esdhc-imx.c b/drivers/mmc/host/sdhci-esdhc-imx.c
index 2e9cca1..28e63ef 100644
--- a/drivers/mmc/host/sdhci-esdhc-imx.c
+++ b/drivers/mmc/host/sdhci-esdhc-imx.c
@@ -17,6 +17,7 @@
 #include <linux/clk.h>
 #include <linux/mmc/host.h>
 #include <linux/mmc/sdhci-pltfm.h>
+#include <mach/hardware.h>
 #include "sdhci.h"
 #include "sdhci-pltfm.h"
 #include "sdhci-esdhc.h"
@@ -112,6 +113,9 @@ static int esdhc_pltfm_init(struct sdhci_host *host, struct sdhci_pltfm_data *pd
 	clk_enable(clk);
 	pltfm_host->clk = clk;
 
+	if (cpu_is_mx35() || cpu_is_mx51())
+		host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL;
+
 	return 0;
 }
 
-- 
1.7.0.4


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

* [PATCH 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35
  2010-10-22 23:12   ` Chris Ball
  2010-10-22 23:57     ` Eric Bénard
@ 2010-10-22 23:57     ` Eric Bénard
  1 sibling, 0 replies; 12+ messages in thread
From: Eric Bénard @ 2010-10-22 23:57 UTC (permalink / raw)
  To: cjb
  Cc: linux-mmc, linux-arm-kernel, shawn.gsc, w.sang, nicolas.pitre,
	r65037, amit.kucheria, Eric Bénard

only these CPU's errata list this bug.

Signed-off-by: Eric Bénard <eric@eukrea.com>
Acked-by: Wolfram Sang <w.sang@pengutronix.de>
---
 drivers/mmc/host/sdhci-esdhc-imx.c |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/drivers/mmc/host/sdhci-esdhc-imx.c b/drivers/mmc/host/sdhci-esdhc-imx.c
index 28e63ef..8308bcd 100644
--- a/drivers/mmc/host/sdhci-esdhc-imx.c
+++ b/drivers/mmc/host/sdhci-esdhc-imx.c
@@ -116,6 +116,10 @@ static int esdhc_pltfm_init(struct sdhci_host *host, struct sdhci_pltfm_data *pd
 	if (cpu_is_mx35() || cpu_is_mx51())
 		host->quirks |= SDHCI_QUIRK_BROKEN_TIMEOUT_VAL;
 
+	/* fix errata ENGcm07207 which is present on i.MX25 and i.MX35 */
+	if (cpu_is_mx25() || cpu_is_mx35())
+		host->quirks |= SDHCI_QUIRK_NO_MULTIBLOCK;
+
 	return 0;
 }
 
@@ -137,10 +141,8 @@ static struct sdhci_ops sdhci_esdhc_ops = {
 };
 
 struct sdhci_pltfm_data sdhci_esdhc_imx_pdata = {
-	.quirks = ESDHC_DEFAULT_QUIRKS | SDHCI_QUIRK_NO_MULTIBLOCK
-			| SDHCI_QUIRK_BROKEN_ADMA,
+	.quirks = ESDHC_DEFAULT_QUIRKS | SDHCI_QUIRK_BROKEN_ADMA,
 	/* ADMA has issues. Might be fixable */
-	/* NO_MULTIBLOCK might be MX35 only (Errata: ENGcm07207) */
 	.ops = &sdhci_esdhc_ops,
 	.init = esdhc_pltfm_init,
 	.exit = esdhc_pltfm_exit,
-- 
1.7.0.4


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

* Re: [PATCH 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci
  2010-10-22 23:57     ` Eric Bénard
@ 2010-11-07 22:51       ` Chris Ball
  0 siblings, 0 replies; 12+ messages in thread
From: Chris Ball @ 2010-11-07 22:51 UTC (permalink / raw)
  To: Eric Bénard
  Cc: linux-mmc, linux-arm-kernel, shawn.gsc, w.sang, nicolas.pitre,
	r65037, amit.kucheria

Hi Eric,

On Sat, Oct 23, 2010 at 01:57:21AM +0200, Eric Bénard wrote:
> this patch fix timeout problems on i.MX's sdhci as suggested by
> Richard Zhu.
> 
> Tested on :
> - i.MX257 : not needed
> - i.MX357 : needed
> - i.MX515 : needed
> 
> more details can be found here :
> http://lists.infradead.org/pipermail/linux-arm-kernel/2010-October/029748.html
> 
> Signed-off-by: Eric Bénard <eric@eukrea.com>
> Tested-by: Shawn Guo <shawn.gsc@gmail.com>
> Acked-by: Wolfram Sang <w.sang@pengutronix.de>

Thanks, I've pushed and queued these two patches for 2.6.37.

-- 
Chris Ball   <cjb@laptop.org>   <http://printf.net/>
One Laptop Per Child

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

end of thread, other threads:[~2010-11-07 22:51 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <4CC0A281.1010202@eukrea.com>
2010-10-21 21:20 ` [PATCH 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci Eric Bénard
2010-10-22  6:15   ` Wolfram Sang
2010-10-22 23:12   ` Chris Ball
2010-10-22 23:57     ` Eric Bénard
2010-11-07 22:51       ` Chris Ball
2010-10-22 23:57     ` [PATCH 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35 Eric Bénard
2010-10-21 21:20 ` Eric Bénard
2010-10-22  6:18   ` Wolfram Sang
2010-10-22  7:07     ` Eric Bénard
2010-10-22  8:46     ` [PATCH v2 1/2] sdhci-esdhc-imx: fix timeout on i.MX's sdhci Eric Bénard
2010-10-22  8:46     ` [PATCH v2 2/2] sdhci-esdhc-imx: enable QUIRK_NO_MULTIBLOCK only for i.MX25 and i.MX35 Eric Bénard
2010-10-22 10:54       ` Wolfram Sang

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).