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:
e99d7c6
)
ASoC: stm32: i2s: Use devm_platform_get_and_ioremap_resource()
author
Yang Yingliang
<yangyingliang@huawei.com>
Thu, 17 Jun 2021 04:38:45 +0000
(12:38 +0800)
committer
Mark Brown
<broonie@kernel.org>
Thu, 17 Jun 2021 12:47:00 +0000
(13:47 +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/20210617043847.1113092-2-yangyingliang@huawei.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/stm/stm32_i2s.c
patch
|
blob
|
history
diff --git
a/sound/soc/stm/stm32_i2s.c
b/sound/soc/stm/stm32_i2s.c
index
7d1672c
..
6254bac
100644
(file)
--- a/
sound/soc/stm/stm32_i2s.c
+++ b/
sound/soc/stm/stm32_i2s.c
@@
-1036,8
+1036,7
@@
static int stm32_i2s_parse_dt(struct platform_device *pdev,
else
return -EINVAL;
- res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
- i2s->base = devm_ioremap_resource(&pdev->dev, res);
+ i2s->base = devm_platform_get_and_ioremap_resource(pdev, 0, &res);
if (IS_ERR(i2s->base))
return PTR_ERR(i2s->base);