All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] soc: tegra: pmc: Make use of the helper function devm_platform_ioremap_resource()
@ 2021-09-08  7:17 Cai Huoqing
  2021-10-07 18:51 ` Thierry Reding
  0 siblings, 1 reply; 2+ messages in thread
From: Cai Huoqing @ 2021-09-08  7:17 UTC (permalink / raw)
  To: caihuoqing; +Cc: Thierry Reding, Jonathan Hunter, linux-tegra, linux-kernel

Use the devm_platform_ioremap_resource() helper instead of
calling platform_get_resource() and devm_ioremap_resource()
separately

Signed-off-by: Cai Huoqing <caihuoqing@baidu.com>
---
 drivers/soc/tegra/pmc.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/soc/tegra/pmc.c b/drivers/soc/tegra/pmc.c
index 50091c4ec948..24683e11ac9b 100644
--- a/drivers/soc/tegra/pmc.c
+++ b/drivers/soc/tegra/pmc.c
@@ -2815,8 +2815,7 @@ static int tegra_pmc_probe(struct platform_device *pdev)
 		return err;
 
 	/* take over the memory region from the early initialization */
-	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	base = devm_ioremap_resource(&pdev->dev, res);
+	base = devm_platform_ioremap_resource(pdev, 0);
 	if (IS_ERR(base))
 		return PTR_ERR(base);
 
-- 
2.25.1


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

* Re: [PATCH] soc: tegra: pmc: Make use of the helper function devm_platform_ioremap_resource()
  2021-09-08  7:17 [PATCH] soc: tegra: pmc: Make use of the helper function devm_platform_ioremap_resource() Cai Huoqing
@ 2021-10-07 18:51 ` Thierry Reding
  0 siblings, 0 replies; 2+ messages in thread
From: Thierry Reding @ 2021-10-07 18:51 UTC (permalink / raw)
  To: Cai Huoqing; +Cc: Jonathan Hunter, linux-tegra, linux-kernel

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

On Wed, Sep 08, 2021 at 03:17:24PM +0800, Cai Huoqing wrote:
> Use the devm_platform_ioremap_resource() helper instead of
> calling platform_get_resource() and devm_ioremap_resource()
> separately
> 
> Signed-off-by: Cai Huoqing <caihuoqing@baidu.com>
> ---
>  drivers/soc/tegra/pmc.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)

Applied, thanks.

Thierry

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

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

end of thread, other threads:[~2021-10-07 18:51 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-08  7:17 [PATCH] soc: tegra: pmc: Make use of the helper function devm_platform_ioremap_resource() Cai Huoqing
2021-10-07 18:51 ` Thierry Reding

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.