Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

ASoC: mediatek: mt8186: Convert to devm_platform_ioremap_resource()

Use devm_platform_ioremap_resource() to simplify code.

Signed-off-by: Yangtao Li <frank.li@vivo.com>
Link: https://lore.kernel.org/r/20230711034846.69437-3-frank.li@vivo.com
Signed-off-by: Mark Brown <broonie@kernel.org>

authored by

Yangtao Li and committed by
Mark Brown
e1537b59 c8b04f00

+1 -3
+1 -3
sound/soc/mediatek/mt8186/mt8186-afe-pcm.c
··· 2815 2815 { 2816 2816 struct mtk_base_afe *afe; 2817 2817 struct mt8186_afe_private *afe_priv; 2818 - struct resource *res; 2819 2818 struct reset_control *rstc; 2820 2819 struct device *dev = &pdev->dev; 2821 2820 int i, ret, irq_id; ··· 2835 2836 afe_priv = afe->platform_priv; 2836 2837 afe->dev = &pdev->dev; 2837 2838 2838 - res = platform_get_resource(pdev, IORESOURCE_MEM, 0); 2839 - afe->base_addr = devm_ioremap_resource(dev, res); 2839 + afe->base_addr = devm_platform_ioremap_resource(pdev, 0); 2840 2840 if (IS_ERR(afe->base_addr)) 2841 2841 return PTR_ERR(afe->base_addr); 2842 2842