Linux MultiMedia Card development
 help / color / mirror / Atom feed
From: Adrian Hunter <adrian.hunter@intel.com>
To: Liming Sun <limings@nvidia.com>,
	Ulf Hansson <ulf.hansson@linaro.org>,
	David Woods <davwoods@nvidia.com>,
	Shawn Lin <shawn.lin@rock-chips.com>
Cc: linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3] mmc: sdhci-of-dwcmshc: add ACPI match data for BlueField-3 SoC
Date: Wed, 10 Aug 2022 15:58:38 +0300	[thread overview]
Message-ID: <765c3b77-9573-d48f-39a9-c311a62542ec@intel.com> (raw)
In-Reply-To: <20220809173742.178440-1-limings@nvidia.com>

On 9/08/22 20:37, Liming Sun wrote:
> Commit 08f3dff799d43 introduces the of_device_get_match_data()
> checking for some chip but breaks the BlueField-3 firmware which
> uses ACPI instead. This commit adds the ACPI match data and
> quirks/quirks2 to re-enable the support of BlueField-3 SoC.
> 
> Reviewed-by: David Woods <davwoods@nvidia.com>
> Signed-off-by: Liming Sun <limings@nvidia.com>

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

> ---
> v2->v3:
>     Rebase to mmc next
> v1->v2:
>     Fixes an acpi warning
>     Reported-by: kernel test robot <lkp@intel.com>
> v1: Initial version.
> ---
>  drivers/mmc/host/sdhci-of-dwcmshc.c | 16 ++++++++++++++--
>  1 file changed, 14 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/mmc/host/sdhci-of-dwcmshc.c b/drivers/mmc/host/sdhci-of-dwcmshc.c
> index 4e904850973c..a7343d4bc50e 100644
> --- a/drivers/mmc/host/sdhci-of-dwcmshc.c
> +++ b/drivers/mmc/host/sdhci-of-dwcmshc.c
> @@ -349,6 +349,15 @@ static const struct sdhci_pltfm_data sdhci_dwcmshc_pdata = {
>  	.quirks2 = SDHCI_QUIRK2_PRESET_VALUE_BROKEN,
>  };
>  
> +#ifdef CONFIG_ACPI
> +static const struct sdhci_pltfm_data sdhci_dwcmshc_bf3_pdata = {
> +	.ops = &sdhci_dwcmshc_ops,
> +	.quirks = SDHCI_QUIRK_CAP_CLOCK_BASE_BROKEN,
> +	.quirks2 = SDHCI_QUIRK2_PRESET_VALUE_BROKEN |
> +		   SDHCI_QUIRK2_ACMD23_BROKEN,
> +};
> +#endif
> +
>  static const struct sdhci_pltfm_data sdhci_dwcmshc_rk35xx_pdata = {
>  	.ops = &sdhci_dwcmshc_rk35xx_ops,
>  	.quirks = SDHCI_QUIRK_CAP_CLOCK_BASE_BROKEN |
> @@ -431,7 +440,10 @@ MODULE_DEVICE_TABLE(of, sdhci_dwcmshc_dt_ids);
>  
>  #ifdef CONFIG_ACPI
>  static const struct acpi_device_id sdhci_dwcmshc_acpi_ids[] = {
> -	{ .id = "MLNXBF30" },
> +	{
> +		.id = "MLNXBF30",
> +		.driver_data = (kernel_ulong_t)&sdhci_dwcmshc_bf3_pdata,
> +	},
>  	{}
>  };
>  #endif
> @@ -447,7 +459,7 @@ static int dwcmshc_probe(struct platform_device *pdev)
>  	int err;
>  	u32 extra;
>  
> -	pltfm_data = of_device_get_match_data(&pdev->dev);
> +	pltfm_data = device_get_match_data(&pdev->dev);
>  	if (!pltfm_data) {
>  		dev_err(&pdev->dev, "Error: No device match data found\n");
>  		return -ENODEV;


  reply	other threads:[~2022-08-10 12:59 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-29 13:17 [PATCH v1 1/1] mmc: sdhci-of-dwcmshc: add ACPI match data for BlueField-3 SoC Liming Sun
2022-07-30  8:04 ` kernel test robot
2022-08-07 20:56 ` [PATCH v2] " Liming Sun
2022-08-08  8:26   ` Adrian Hunter
2022-08-09 17:39     ` Liming Sun
2022-08-09 17:37 ` [PATCH v3] " Liming Sun
2022-08-10 12:58   ` Adrian Hunter [this message]
2022-08-15 18:28   ` Ulf Hansson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=765c3b77-9573-d48f-39a9-c311a62542ec@intel.com \
    --to=adrian.hunter@intel.com \
    --cc=davwoods@nvidia.com \
    --cc=limings@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=shawn.lin@rock-chips.com \
    --cc=ulf.hansson@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox