diff options
author | Li Zetao <lizetao1@huawei.com> | 2023-08-02 12:40:28 +0300 |
---|---|---|
committer | Ulf Hansson <ulf.hansson@linaro.org> | 2023-08-09 14:21:48 +0300 |
commit | aa857326a454814478b8e7c52caeee1743d92e0d (patch) | |
tree | d73f7a85c4436f7b5490b4b1c56a5d2e4dadc39d | |
parent | 90ecc29a09d5113a54d09053a019d4236ca685ca (diff) | |
download | linux-aa857326a454814478b8e7c52caeee1743d92e0d.tar.xz |
mmc: sdhci-st: Use devm_platform_ioremap_resource_byname()
Convert platform_get_resource_byname() + devm_ioremap_resource() to a
single call to devm_platform_ioremap_resource_byname(), as this is
exactly what this function does.
Signed-off-by: Li Zetao <lizetao1@huawei.com>
Acked-by: Adrian Hunter <adrian.hunter@intel.com>
Link: https://lore.kernel.org/r/20230802094028.976612-1-lizetao1@huawei.com
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
-rw-r--r-- | drivers/mmc/host/sdhci-st.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/mmc/host/sdhci-st.c b/drivers/mmc/host/sdhci-st.c index 6415916fbd91..97f350953c4b 100644 --- a/drivers/mmc/host/sdhci-st.c +++ b/drivers/mmc/host/sdhci-st.c @@ -348,7 +348,6 @@ static int sdhci_st_probe(struct platform_device *pdev) struct clk *clk, *icnclk; int ret = 0; u16 host_version; - struct resource *res; struct reset_control *rstc; clk = devm_clk_get(&pdev->dev, "mmc"); @@ -397,9 +396,7 @@ static int sdhci_st_probe(struct platform_device *pdev) } /* Configure the FlashSS Top registers for setting eMMC TX/RX delay */ - res = platform_get_resource_byname(pdev, IORESOURCE_MEM, - "top-mmc-delay"); - pdata->top_ioaddr = devm_ioremap_resource(&pdev->dev, res); + pdata->top_ioaddr = devm_platform_ioremap_resource_byname(pdev, "top-mmc-delay"); if (IS_ERR(pdata->top_ioaddr)) pdata->top_ioaddr = NULL; |