diff options
author | Mark Brown <broonie@kernel.org> | 2021-06-23 16:31:13 +0100 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2021-06-23 16:31:13 +0100 |
commit | f5e2d697d3cbd6d20684eddd3e280809c30e37a1 (patch) | |
tree | 3366d0b119ea092b9a3803624f68620e28138d84 | |
parent | 723ca2f89412abe47b7cbb276f683ddb292c172c (diff) | |
parent | fc8344e63e595fa1f2e783aaae0253570cd8eea8 (diff) | |
download | linux-stable-f5e2d697d3cbd6d20684eddd3e280809c30e37a1.tar.gz linux-stable-f5e2d697d3cbd6d20684eddd3e280809c30e37a1.tar.bz2 linux-stable-f5e2d697d3cbd6d20684eddd3e280809c30e37a1.zip |
Merge series "ASoC: tegra: Use devm_platform_get_and_ioremap_resource()" from Yang Yingliang <yangyingliang@huawei.com>:
Use devm_platform_get_and_ioremap_resource() to simplify
code.
Yang Yingliang (4):
ASoC: tegra20: i2s: Use devm_platform_get_and_ioremap_resource()
ASoC: tegra20: spdif: Use devm_platform_get_and_ioremap_resource()
ASoC: tegra: tegra210_admaif: Use
devm_platform_get_and_ioremap_resource()
ASoC: tegra30: ahub: Use devm_platform_get_and_ioremap_resource()
sound/soc/tegra/tegra20_i2s.c | 3 +--
sound/soc/tegra/tegra20_spdif.c | 3 +--
sound/soc/tegra/tegra210_admaif.c | 4 +---
sound/soc/tegra/tegra30_ahub.c | 3 +--
4 files changed, 4 insertions(+), 9 deletions(-)
--
2.25.1
-rw-r--r-- | sound/soc/tegra/tegra20_i2s.c | 3 | ||||
-rw-r--r-- | sound/soc/tegra/tegra20_spdif.c | 3 | ||||
-rw-r--r-- | sound/soc/tegra/tegra210_admaif.c | 4 | ||||
-rw-r--r-- | sound/soc/tegra/tegra30_ahub.c | 3 |
4 files changed, 4 insertions, 9 deletions
diff --git a/sound/soc/tegra/tegra20_i2s.c b/sound/soc/tegra/tegra20_i2s.c index b280ebd72591..266d2cab9f49 100644 --- a/sound/soc/tegra/tegra20_i2s.c +++ b/sound/soc/tegra/tegra20_i2s.c @@ -377,8 +377,7 @@ static int tegra20_i2s_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; diff --git a/sound/soc/tegra/tegra20_spdif.c b/sound/soc/tegra/tegra20_spdif.c index de698ff2a69c..7751575cd6d6 100644 --- a/sound/soc/tegra/tegra20_spdif.c +++ b/sound/soc/tegra/tegra20_spdif.c @@ -269,8 +269,7 @@ static int tegra20_spdif_platform_probe(struct platform_device *pdev) return ret; } - 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)) return PTR_ERR(regs); diff --git a/sound/soc/tegra/tegra210_admaif.c b/sound/soc/tegra/tegra210_admaif.c index 1268046b345d..0f9beef429a2 100644 --- a/sound/soc/tegra/tegra210_admaif.c +++ b/sound/soc/tegra/tegra210_admaif.c @@ -706,9 +706,7 @@ static int tegra_admaif_probe(struct platform_device *pdev) return -ENOMEM; } - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - - regs = devm_ioremap_resource(&pdev->dev, res); + regs = devm_platform_get_and_ioremap_resource(pdev, 0, &res); if (IS_ERR(regs)) return PTR_ERR(regs); diff --git a/sound/soc/tegra/tegra30_ahub.c b/sound/soc/tegra/tegra30_ahub.c index 4692c70ed933..b3e1df693381 100644 --- a/sound/soc/tegra/tegra30_ahub.c +++ b/sound/soc/tegra/tegra30_ahub.c @@ -550,8 +550,7 @@ static int tegra30_ahub_probe(struct platform_device *pdev) goto err_unset_ahub; } - res0 = platform_get_resource(pdev, IORESOURCE_MEM, 0); - regs_apbif = devm_ioremap_resource(&pdev->dev, res0); + regs_apbif = devm_platform_get_and_ioremap_resource(pdev, 0, &res0); if (IS_ERR(regs_apbif)) { ret = PTR_ERR(regs_apbif); goto err_unset_ahub; |