All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] cpuidle: clps711x: convert to devm_platform_ioremap_resource
@ 2019-12-15 13:02 ` Yangtao Li
  0 siblings, 0 replies; 18+ messages in thread
From: Yangtao Li @ 2019-12-15 13:02 UTC (permalink / raw)
  To: rjw, daniel.lezcano, shc_work
  Cc: linux-pm, linux-arm-kernel, linux-kernel, Yangtao Li

Use devm_platform_ioremap_resource() to simplify code.

Signed-off-by: Yangtao Li <tiny.windzz@gmail.com>
---
 drivers/cpuidle/cpuidle-clps711x.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/drivers/cpuidle/cpuidle-clps711x.c b/drivers/cpuidle/cpuidle-clps711x.c
index 6e36740f5719..fc22c59b6c73 100644
--- a/drivers/cpuidle/cpuidle-clps711x.c
+++ b/drivers/cpuidle/cpuidle-clps711x.c
@@ -37,10 +37,7 @@ static struct cpuidle_driver clps711x_idle_driver = {
 
 static int __init clps711x_cpuidle_probe(struct platform_device *pdev)
 {
-	struct resource *res;
-
-	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	clps711x_halt = devm_ioremap_resource(&pdev->dev, res);
+	clps711x_halt = devm_platform_ioremap_resource(pdev, 0);
 	if (IS_ERR(clps711x_halt))
 		return PTR_ERR(clps711x_halt);
 
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2019-12-20  9:17 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-12-15 13:02 [PATCH] cpuidle: clps711x: convert to devm_platform_ioremap_resource Yangtao Li
2019-12-15 13:02 ` Yangtao Li
2019-12-15 13:02 ` [PATCH 1/2] cpuidle: kirkwood: " Yangtao Li
2019-12-15 13:02   ` Yangtao Li
2019-12-15 15:01   ` Andrew Lunn
2019-12-15 15:01     ` Andrew Lunn
2019-12-16 11:21   ` Rafael J. Wysocki
2019-12-16 11:21     ` Rafael J. Wysocki
2019-12-16 15:45     ` Daniel Lezcano
2019-12-16 15:45       ` Daniel Lezcano
2019-12-20  9:16   ` Rafael J. Wysocki
2019-12-20  9:16     ` Rafael J. Wysocki
2019-12-16 11:20 ` [PATCH] cpuidle: clps711x: " Rafael J. Wysocki
2019-12-16 11:20   ` Rafael J. Wysocki
2019-12-16 15:44   ` Daniel Lezcano
2019-12-16 15:44     ` Daniel Lezcano
2019-12-20  9:17 ` Rafael J. Wysocki
2019-12-20  9:17   ` Rafael J. Wysocki

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.