linux-tegra.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 5/5] ASoC: tegra: tegra20_ac97: Use devm_platform_get_and_ioremap_resource()
       [not found] <20230711034846.69437-1-frank.li@vivo.com>
@ 2023-07-11  3:48 ` Yangtao Li
  2023-07-11 15:46   ` Thierry Reding
  0 siblings, 1 reply; 2+ messages in thread
From: Yangtao Li @ 2023-07-11  3:48 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
	Thierry Reding, Jonathan Hunter
  Cc: Yangtao Li, alsa-devel, linux-tegra, linux-kernel

Convert platform_get_resource(), devm_ioremap_resource() to a single
call to devm_platform_get_and_ioremap_resource(), as this is exactly
what this function does.

Signed-off-by: Yangtao Li <frank.li@vivo.com>
---
 sound/soc/tegra/tegra20_ac97.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/sound/soc/tegra/tegra20_ac97.c b/sound/soc/tegra/tegra20_ac97.c
index a4073a746ae3..60e7df41c64c 100644
--- a/sound/soc/tegra/tegra20_ac97.c
+++ b/sound/soc/tegra/tegra20_ac97.c
@@ -328,8 +328,7 @@ static int tegra20_ac97_platform_probe(struct platform_device *pdev)
 		goto err;
 	}
 
-	mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	regs = devm_ioremap_resource(&pdev->dev, mem);
+	regs = devm_platform_get_and_ioremap_resource(pdev, 0, &mem);
 	if (IS_ERR(regs)) {
 		ret = PTR_ERR(regs);
 		goto err_clk_put;
-- 
2.39.0


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

* Re: [PATCH 5/5] ASoC: tegra: tegra20_ac97: Use devm_platform_get_and_ioremap_resource()
  2023-07-11  3:48 ` [PATCH 5/5] ASoC: tegra: tegra20_ac97: Use devm_platform_get_and_ioremap_resource() Yangtao Li
@ 2023-07-11 15:46   ` Thierry Reding
  0 siblings, 0 replies; 2+ messages in thread
From: Thierry Reding @ 2023-07-11 15:46 UTC (permalink / raw)
  To: Yangtao Li
  Cc: Liam Girdwood, Mark Brown, Jaroslav Kysela, Takashi Iwai,
	Jonathan Hunter, alsa-devel, linux-tegra, linux-kernel

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

On Tue, Jul 11, 2023 at 11:48:45AM +0800, Yangtao Li wrote:
> Convert platform_get_resource(), devm_ioremap_resource() to a single
> call to devm_platform_get_and_ioremap_resource(), as this is exactly
> what this function does.
> 
> Signed-off-by: Yangtao Li <frank.li@vivo.com>
> ---
>  sound/soc/tegra/tegra20_ac97.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)

Acked-by: Thierry Reding <treding@nvidia.com>

[-- 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:[~2023-07-11 15:46 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20230711034846.69437-1-frank.li@vivo.com>
2023-07-11  3:48 ` [PATCH 5/5] ASoC: tegra: tegra20_ac97: Use devm_platform_get_and_ioremap_resource() Yangtao Li
2023-07-11 15:46   ` Thierry Reding

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