diff mbox

cpuidle: remove cpu_pm calls when entering a idle state

Message ID 1477042377-13485-1-git-send-email-chenhui.zhao@nxp.com (mailing list archive)
State Rejected, archived
Headers show

Commit Message

Chenhui Zhao Oct. 21, 2016, 9:32 a.m. UTC
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@nxp.com>
---
 include/linux/cpuidle.h | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

Comments

Sudeep Holla Oct. 21, 2016, 9:59 a.m. UTC | #1
Hi Chenhui,

On Fri, Oct 21, 2016 at 10:32 AM, Chenhui Zhao <chenhui.zhao@nxp.com> wrote:
> 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.
>

So are you OK to break all the states that would be reset ?
This is not a proper solution. Can you provide more details on the issue
you are facing ? What platform ? which idle states ? and so on..

Regards,
Sudeep
--
To unsubscribe from this list: send the line "unsubscribe linux-pm" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

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;					\
 })