cpuidle-clps711x.c (75bf465f0bc33e9b776a46d6a1b9b990f5fb7c37) | cpuidle-clps711x.c (22c48a439d6ac1dbe2db1092b64052592a47b017) |
---|---|
1// SPDX-License-Identifier: GPL-2.0-or-later 2/* 3 * CLPS711X CPU idle driver 4 * 5 * Copyright (C) 2014 Alexander Shiyan <shc_work@mail.ru> 6 */ 7 8#include <linux/cpuidle.h> --- 23 unchanged lines hidden (view full) --- 32 .enter = clps711x_cpuidle_halt, 33 .exit_latency = 1, 34 }, 35 .state_count = 1, 36}; 37 38static int __init clps711x_cpuidle_probe(struct platform_device *pdev) 39{ | 1// SPDX-License-Identifier: GPL-2.0-or-later 2/* 3 * CLPS711X CPU idle driver 4 * 5 * Copyright (C) 2014 Alexander Shiyan <shc_work@mail.ru> 6 */ 7 8#include <linux/cpuidle.h> --- 23 unchanged lines hidden (view full) --- 32 .enter = clps711x_cpuidle_halt, 33 .exit_latency = 1, 34 }, 35 .state_count = 1, 36}; 37 38static int __init clps711x_cpuidle_probe(struct platform_device *pdev) 39{ |
40 struct resource *res; 41 42 res = platform_get_resource(pdev, IORESOURCE_MEM, 0); 43 clps711x_halt = devm_ioremap_resource(&pdev->dev, res); | 40 clps711x_halt = devm_platform_ioremap_resource(pdev, 0); |
44 if (IS_ERR(clps711x_halt)) 45 return PTR_ERR(clps711x_halt); 46 47 return cpuidle_register(&clps711x_idle_driver, NULL); 48} 49 50static struct platform_driver clps711x_cpuidle_driver = { 51 .driver = { 52 .name = CLPS711X_CPUIDLE_NAME, 53 }, 54}; 55builtin_platform_driver_probe(clps711x_cpuidle_driver, clps711x_cpuidle_probe); | 41 if (IS_ERR(clps711x_halt)) 42 return PTR_ERR(clps711x_halt); 43 44 return cpuidle_register(&clps711x_idle_driver, NULL); 45} 46 47static struct platform_driver clps711x_cpuidle_driver = { 48 .driver = { 49 .name = CLPS711X_CPUIDLE_NAME, 50 }, 51}; 52builtin_platform_driver_probe(clps711x_cpuidle_driver, clps711x_cpuidle_probe); |