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
This commit is contained in:
commit
f5e2d697d3
@ -377,8 +377,7 @@ static int tegra20_i2s_platform_probe(struct platform_device *pdev)
|
|||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
|
|
||||||
mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
|
regs = devm_platform_get_and_ioremap_resource(pdev, 0, &mem);
|
||||||
regs = devm_ioremap_resource(&pdev->dev, mem);
|
|
||||||
if (IS_ERR(regs)) {
|
if (IS_ERR(regs)) {
|
||||||
ret = PTR_ERR(regs);
|
ret = PTR_ERR(regs);
|
||||||
goto err;
|
goto err;
|
||||||
|
@ -269,8 +269,7 @@ static int tegra20_spdif_platform_probe(struct platform_device *pdev)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
|
regs = devm_platform_get_and_ioremap_resource(pdev, 0, &mem);
|
||||||
regs = devm_ioremap_resource(&pdev->dev, mem);
|
|
||||||
if (IS_ERR(regs))
|
if (IS_ERR(regs))
|
||||||
return PTR_ERR(regs);
|
return PTR_ERR(regs);
|
||||||
|
|
||||||
|
@ -706,9 +706,7 @@ static int tegra_admaif_probe(struct platform_device *pdev)
|
|||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
}
|
}
|
||||||
|
|
||||||
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
|
regs = devm_platform_get_and_ioremap_resource(pdev, 0, &res);
|
||||||
|
|
||||||
regs = devm_ioremap_resource(&pdev->dev, res);
|
|
||||||
if (IS_ERR(regs))
|
if (IS_ERR(regs))
|
||||||
return PTR_ERR(regs);
|
return PTR_ERR(regs);
|
||||||
|
|
||||||
|
@ -550,8 +550,7 @@ static int tegra30_ahub_probe(struct platform_device *pdev)
|
|||||||
goto err_unset_ahub;
|
goto err_unset_ahub;
|
||||||
}
|
}
|
||||||
|
|
||||||
res0 = platform_get_resource(pdev, IORESOURCE_MEM, 0);
|
regs_apbif = devm_platform_get_and_ioremap_resource(pdev, 0, &res0);
|
||||||
regs_apbif = devm_ioremap_resource(&pdev->dev, res0);
|
|
||||||
if (IS_ERR(regs_apbif)) {
|
if (IS_ERR(regs_apbif)) {
|
||||||
ret = PTR_ERR(regs_apbif);
|
ret = PTR_ERR(regs_apbif);
|
||||||
goto err_unset_ahub;
|
goto err_unset_ahub;
|
||||||
|
Loading…
Reference in New Issue
Block a user