Skip to contentSkip to conversation

mfd: exynos-lpass: use devm_platform_get_and_ioremap_resource()

PATCH In review [email protected] 2 participants 2 messages Nov 11, 2022

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mfd: exynos-lpass: use devm_platform_get_and_ioremap_resource()

From: Minghao Chi <[email protected]>

Convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does.

---
 drivers/mfd/exynos-lpass.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/mfd/exynos-lpass.c +1 -3
index 166cd21088cd..ac99e742a355 100644
@@ -109,14 +109,12 @@ static int exynos_lpass_probe(struct platform_device *pdev)
 	struct device *dev = &pdev->dev;
 	struct exynos_lpass *lpass;
 	void __iomem *base_top;
-	struct resource *res;
 
 	lpass = devm_kzalloc(dev, sizeof(*lpass), GFP_KERNEL);
 	if (!lpass)
 		return -ENOMEM;
 
-	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	base_top = devm_ioremap_resource(dev, res);
+	base_top = devm_platform_get_and_ioremap_resource(pdev, 0, NULL);
 	if (IS_ERR(base_top))
 		return PTR_ERR(base_top);
 
Signature · 1 line
2.25.1
#1 lore raw
Quoted 7 lines · On 11/11/2022 09:40, [email protected] wrote:

From: Minghao Chi <[email protected]>

Convert platform_get_resource(), devm_ioremap_resource() to a single call to devm_platform_get_and_ioremap_resource(), as this is exactly what this function does.

1. I cannot find this report. This is an open source work and public collaboration. The "Reported-by" usually means that the issue was reported to us, in some way, usually in public. Can we see the report? Otherwise adding non-public, non-verifiable reports is useless and clutters our report-credit-system.

2. Where is the bug? Reported-by means there was a bug being fixed. Please describe the visible effects of bug and its impact.

Otherwise please stop adding bogus reported-by messages. I have seen to many bogus reported-by tags from ZTE last months.

Quoted 4 lines
---
 drivers/mfd/exynos-lpass.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

Best regards,
Krzysztof