public inbox for linux-tegra@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 04/11] ata: ahci_tegra: Convert to devm_platform_ioremap_resource()
       [not found] <20230707095513.64224-1-frank.li@vivo.com>
@ 2023-07-07  9:55 ` Yangtao Li
  2023-07-07 12:49   ` Thierry Reding
  0 siblings, 1 reply; 2+ messages in thread
From: Yangtao Li @ 2023-07-07  9:55 UTC (permalink / raw)
  To: Damien Le Moal, Thierry Reding, Jonathan Hunter
  Cc: Yangtao Li, linux-ide, linux-tegra, linux-kernel

Use devm_platform_ioremap_resource() to simplify code.

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

diff --git a/drivers/ata/ahci_tegra.c b/drivers/ata/ahci_tegra.c
index 21c20793e517..d1a35da7e824 100644
--- a/drivers/ata/ahci_tegra.c
+++ b/drivers/ata/ahci_tegra.c
@@ -530,8 +530,7 @@ static int tegra_ahci_probe(struct platform_device *pdev)
 	tegra->pdev = pdev;
 	tegra->soc = of_device_get_match_data(&pdev->dev);
 
-	res = platform_get_resource(pdev, IORESOURCE_MEM, 1);
-	tegra->sata_regs = devm_ioremap_resource(&pdev->dev, res);
+	tegra->sata_regs = devm_platform_ioremap_resource(pdev, 1);
 	if (IS_ERR(tegra->sata_regs))
 		return PTR_ERR(tegra->sata_regs);
 
-- 
2.39.0


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

* Re: [PATCH v2 04/11] ata: ahci_tegra: Convert to devm_platform_ioremap_resource()
  2023-07-07  9:55 ` [PATCH v2 04/11] ata: ahci_tegra: Convert to devm_platform_ioremap_resource() Yangtao Li
@ 2023-07-07 12:49   ` Thierry Reding
  0 siblings, 0 replies; 2+ messages in thread
From: Thierry Reding @ 2023-07-07 12:49 UTC (permalink / raw)
  To: Yangtao Li
  Cc: Damien Le Moal, Jonathan Hunter, linux-ide, linux-tegra,
	linux-kernel

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

On Fri, Jul 07, 2023 at 05:55:06PM +0800, Yangtao Li wrote:
> Use devm_platform_ioremap_resource() to simplify code.
> 
> Signed-off-by: Yangtao Li <frank.li@vivo.com>
> ---
>  drivers/ata/ahci_tegra.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-07 12:49 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20230707095513.64224-1-frank.li@vivo.com>
2023-07-07  9:55 ` [PATCH v2 04/11] ata: ahci_tegra: Convert to devm_platform_ioremap_resource() Yangtao Li
2023-07-07 12:49   ` Thierry Reding

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox