projects
/
platform
/
kernel
/
linux-rpi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4ffbcd4
)
ASoC: rockchip: pdm: Use devm_platform_get_and_ioremap_resource()
author
Yang Yingliang
<yangyingliang@huawei.com>
Tue, 15 Jun 2021 14:15:01 +0000
(22:15 +0800)
committer
Mark Brown
<broonie@kernel.org>
Wed, 16 Jun 2021 14:41:11 +0000
(15:41 +0100)
Use devm_platform_get_and_ioremap_resource() to simplify
code.
Signed-off-by: Yang Yingliang <yangyingliang@huawei.com>
Link:
https://lore.kernel.org/r/20210615141502.1683686-2-yangyingliang@huawei.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/rockchip/rockchip_pdm.c
patch
|
blob
|
history
diff --git
a/sound/soc/rockchip/rockchip_pdm.c
b/sound/soc/rockchip/rockchip_pdm.c
index
9295d64
..
38bd603
100644
(file)
--- a/
sound/soc/rockchip/rockchip_pdm.c
+++ b/
sound/soc/rockchip/rockchip_pdm.c
@@
-495,8
+495,7
@@
static int rockchip_pdm_probe(struct platform_device *pdev)
return PTR_ERR(pdm->reset);
}
- 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);