diff options
author | Yang Li <yang.lee@linux.alibaba.com> | 2023-03-28 14:10:30 +0800 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2023-04-04 12:46:56 +0100 |
commit | 05c79f71e357a566de887efa55672c8a36569f60 (patch) | |
tree | 75855a04e3e46d5cb8c7c1729474604283751a7b /drivers/spi | |
parent | 75c1b5fc493c21ebe524e9e5bb8501bb351ad94a (diff) |
spi: tegra114: Use devm_platform_get_and_ioremap_resource()
According to commit 890cc39a8799 ("drivers: provide
devm_platform_get_and_ioremap_resource()"), 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: Yang Li <yang.lee@linux.alibaba.com>
Link: https://lore.kernel.org/r/20230328061031.70140-1-yang.lee@linux.alibaba.com
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/spi')
-rw-r--r-- | drivers/spi/spi-tegra114.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/spi/spi-tegra114.c b/drivers/spi/spi-tegra114.c index 9e7d762d0ee6..488df681eaef 100644 --- a/drivers/spi/spi-tegra114.c +++ b/drivers/spi/spi-tegra114.c @@ -1342,8 +1342,7 @@ static int tegra_spi_probe(struct platform_device *pdev) goto exit_free_master; } - r = platform_get_resource(pdev, IORESOURCE_MEM, 0); - tspi->base = devm_ioremap_resource(&pdev->dev, r); + tspi->base = devm_platform_get_and_ioremap_resource(pdev, 0, &r); if (IS_ERR(tspi->base)) { ret = PTR_ERR(tspi->base); goto exit_free_master; |