[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <1477042377-13485-1-git-send-email-chenhui.zhao@nxp.com>
Date:   Fri, 21 Oct 2016 17:32:57 +0800
From:   Chenhui Zhao <chenhui.zhao@....com>
To:     <linux-pm@...r.kernel.org>, <rjw@...ysocki.net>,
        <daniel.lezcano@...aro.org>, <linux-kernel@...r.kernel.org>
CC:     <z.chenhui@...il.com>, Chenhui Zhao <chenhui.zhao@....com>
Subject: [PATCH] cpuidle: remove cpu_pm calls when entering a idle state
The functions, cpu_pm_enter and cpu_pm_exit, assume that CPU would
be reset when entering and exiting a idle state. If that is not the
case, they would cause issue.
Signed-off-by: Chenhui Zhao <chenhui.zhao@....com>
---
 include/linux/cpuidle.h | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/include/linux/cpuidle.h b/include/linux/cpuidle.h
index bb31373..063af89 100644
--- a/include/linux/cpuidle.h
+++ b/include/linux/cpuidle.h
@@ -261,12 +261,7 @@ static inline int cpuidle_register_governor(struct cpuidle_governor *gov)
 		return idx;					\
 	}							\
 								\
-	__ret = cpu_pm_enter();					\
-	if (!__ret) {						\
-		__ret = low_level_idle_enter(idx);		\
-		cpu_pm_exit();					\
-	}							\
-								\
+	__ret = low_level_idle_enter(idx);			\
 	__ret ? -1 : idx;					\
 })
 
-- 
1.9.1
Powered by blists - more mailing lists
 
