Linux-mmc Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH] mmc: sdhci-of-at91: fix quirk2 overwrite
@ 2019-11-14 12:59 Eugen.Hristev
  2019-11-14 13:01 ` Adrian Hunter
  2019-11-14 14:00 ` Ulf Hansson
  0 siblings, 2 replies; 3+ messages in thread
From: Eugen.Hristev @ 2019-11-14 12:59 UTC (permalink / raw)
  To: adrian.hunter, Ludovic.Desroches, ulf.hansson, linux-mmc,
	linux-arm-kernel, linux-kernel
  Cc: Eugen.Hristev

From: Eugen Hristev <eugen.hristev@microchip.com>

The quirks2 are parsed and set (e.g. from DT) before the quirk for broken
HS200 is set in the driver.
The driver needs to enable just this flag, not rewrite the whole quirk set.

Fixes: 7871aa60ae00 ("mmc: sdhci-of-at91: add quirk for broken HS200")
Signed-off-by: Eugen Hristev <eugen.hristev@microchip.com>
---

 drivers/mmc/host/sdhci-of-at91.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sdhci-of-at91.c b/drivers/mmc/host/sdhci-of-at91.c
index 496844a..5fe6684 100644
--- a/drivers/mmc/host/sdhci-of-at91.c
+++ b/drivers/mmc/host/sdhci-of-at91.c
@@ -389,7 +389,7 @@ static int sdhci_at91_probe(struct platform_device *pdev)
 	pm_runtime_use_autosuspend(&pdev->dev);
 
 	/* HS200 is broken at this moment */
-	host->quirks2 = SDHCI_QUIRK2_BROKEN_HS200;
+	host->quirks2 |= SDHCI_QUIRK2_BROKEN_HS200;
 
 	ret = sdhci_add_host(host);
 	if (ret)
-- 
2.7.4

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

* Re: [PATCH] mmc: sdhci-of-at91: fix quirk2 overwrite
  2019-11-14 12:59 [PATCH] mmc: sdhci-of-at91: fix quirk2 overwrite Eugen.Hristev
@ 2019-11-14 13:01 ` Adrian Hunter
  2019-11-14 14:00 ` Ulf Hansson
  1 sibling, 0 replies; 3+ messages in thread
From: Adrian Hunter @ 2019-11-14 13:01 UTC (permalink / raw)
  To: Eugen.Hristev, Ludovic.Desroches, ulf.hansson, linux-mmc,
	linux-arm-kernel, linux-kernel

On 14/11/19 2:59 PM, Eugen.Hristev@microchip.com wrote:
> From: Eugen Hristev <eugen.hristev@microchip.com>
> 
> The quirks2 are parsed and set (e.g. from DT) before the quirk for broken
> HS200 is set in the driver.
> The driver needs to enable just this flag, not rewrite the whole quirk set.
> 
> Fixes: 7871aa60ae00 ("mmc: sdhci-of-at91: add quirk for broken HS200")
> Signed-off-by: Eugen Hristev <eugen.hristev@microchip.com>

Acked-by: Adrian Hunter <adrian.hunter@intel.com>

> ---
> 
>  drivers/mmc/host/sdhci-of-at91.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/mmc/host/sdhci-of-at91.c b/drivers/mmc/host/sdhci-of-at91.c
> index 496844a..5fe6684 100644
> --- a/drivers/mmc/host/sdhci-of-at91.c
> +++ b/drivers/mmc/host/sdhci-of-at91.c
> @@ -389,7 +389,7 @@ static int sdhci_at91_probe(struct platform_device *pdev)
>  	pm_runtime_use_autosuspend(&pdev->dev);
>  
>  	/* HS200 is broken at this moment */
> -	host->quirks2 = SDHCI_QUIRK2_BROKEN_HS200;
> +	host->quirks2 |= SDHCI_QUIRK2_BROKEN_HS200;
>  
>  	ret = sdhci_add_host(host);
>  	if (ret)
> 

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

* Re: [PATCH] mmc: sdhci-of-at91: fix quirk2 overwrite
  2019-11-14 12:59 [PATCH] mmc: sdhci-of-at91: fix quirk2 overwrite Eugen.Hristev
  2019-11-14 13:01 ` Adrian Hunter
@ 2019-11-14 14:00 ` Ulf Hansson
  1 sibling, 0 replies; 3+ messages in thread
From: Ulf Hansson @ 2019-11-14 14:00 UTC (permalink / raw)
  To: Eugen.Hristev
  Cc: Adrian Hunter, Ludovic Desroches, linux-mmc, Linux ARM,
	Linux Kernel Mailing List

On Thu, 14 Nov 2019 at 13:59, <Eugen.Hristev@microchip.com> wrote:
>
> From: Eugen Hristev <eugen.hristev@microchip.com>
>
> The quirks2 are parsed and set (e.g. from DT) before the quirk for broken
> HS200 is set in the driver.
> The driver needs to enable just this flag, not rewrite the whole quirk set.
>
> Fixes: 7871aa60ae00 ("mmc: sdhci-of-at91: add quirk for broken HS200")
> Signed-off-by: Eugen Hristev <eugen.hristev@microchip.com>

Applied for fixes, adding a stable tag, thanks!

Kind regards
Uffe

> ---
>
>  drivers/mmc/host/sdhci-of-at91.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/mmc/host/sdhci-of-at91.c b/drivers/mmc/host/sdhci-of-at91.c
> index 496844a..5fe6684 100644
> --- a/drivers/mmc/host/sdhci-of-at91.c
> +++ b/drivers/mmc/host/sdhci-of-at91.c
> @@ -389,7 +389,7 @@ static int sdhci_at91_probe(struct platform_device *pdev)
>         pm_runtime_use_autosuspend(&pdev->dev);
>
>         /* HS200 is broken at this moment */
> -       host->quirks2 = SDHCI_QUIRK2_BROKEN_HS200;
> +       host->quirks2 |= SDHCI_QUIRK2_BROKEN_HS200;
>
>         ret = sdhci_add_host(host);
>         if (ret)
> --
> 2.7.4
>

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

end of thread, back to index

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-14 12:59 [PATCH] mmc: sdhci-of-at91: fix quirk2 overwrite Eugen.Hristev
2019-11-14 13:01 ` Adrian Hunter
2019-11-14 14:00 ` Ulf Hansson

Linux-mmc Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-mmc/0 linux-mmc/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-mmc linux-mmc/ https://lore.kernel.org/linux-mmc \
		linux-mmc@vger.kernel.org
	public-inbox-index linux-mmc

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-mmc


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git