Commit b4fd4ea7 authored by Mark Brown's avatar Mark Brown

Merge series "ASoC: samsung: Use devm_platform_get_and_ioremap_resource()"...

Merge series "ASoC: samsung: 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: samsung: i2s: Use devm_platform_get_and_ioremap_resource()
  ASoC: samsung: pcm: Use devm_platform_get_and_ioremap_resource()
  ASoC: samsung: s3c2412-i2s: Use
    devm_platform_get_and_ioremap_resource()
  ASoC: samsung: s3c24xx-i2s: Use
    devm_platform_get_and_ioremap_resource()

 sound/soc/samsung/i2s.c         | 3 +--
 sound/soc/samsung/pcm.c         | 3 +--
 sound/soc/samsung/s3c2412-i2s.c | 3 +--
 sound/soc/samsung/s3c24xx-i2s.c | 3 +--
 4 files changed, 4 insertions(+), 8 deletions(-)

--
2.25.1
parents ea837090 b73cbd7b
......@@ -1441,8 +1441,7 @@ static int samsung_i2s_probe(struct platform_device *pdev)
}
}
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
priv->addr = devm_ioremap_resource(&pdev->dev, res);
priv->addr = devm_platform_get_and_ioremap_resource(pdev, 0, &res);
if (IS_ERR(priv->addr))
return PTR_ERR(priv->addr);
......
......@@ -512,8 +512,7 @@ static int s3c_pcm_dev_probe(struct platform_device *pdev)
/* Default is 128fs */
pcm->sclk_per_fs = 128;
mem_res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
pcm->regs = devm_ioremap_resource(&pdev->dev, mem_res);
pcm->regs = devm_platform_get_and_ioremap_resource(pdev, 0, &mem_res);
if (IS_ERR(pcm->regs))
return PTR_ERR(pcm->regs);
......
......@@ -208,8 +208,7 @@ static int s3c2412_iis_dev_probe(struct platform_device *pdev)
return -ENXIO;
}
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
s3c2412_i2s.regs = devm_ioremap_resource(&pdev->dev, res);
s3c2412_i2s.regs = devm_platform_get_and_ioremap_resource(pdev, 0, &res);
if (IS_ERR(s3c2412_i2s.regs))
return PTR_ERR(s3c2412_i2s.regs);
......
......@@ -425,8 +425,7 @@ static int s3c24xx_iis_dev_probe(struct platform_device *pdev)
struct resource *res;
int ret;
res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
s3c24xx_i2s.regs = devm_ioremap_resource(&pdev->dev, res);
s3c24xx_i2s.regs = devm_platform_get_and_ioremap_resource(pdev, 0, &res);
if (IS_ERR(s3c24xx_i2s.regs))
return PTR_ERR(s3c24xx_i2s.regs);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment