Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1372828

[PATCH 04/13] intel_idle: Remove redundant initialization calls.

From Len Brown <lenb@kernel.org>
Newsgroups linux.kernel
Subject [PATCH 04/13] intel_idle: Remove redundant initialization calls.
Date 2016-04-06 23:10 +0200
Message-ID <rl2S7-1tt-33@gated-at.bofh.it> (permalink)
References <rl2S6-1tt-7@gated-at.bofh.it>
Organization Intel Open Source Technology Center

Show all headers | View raw


From: Richard Cochran <rcochran@linutronix.de>

The function, intel_idle_cpuidle_driver_init, makes calls on each CPU
to auto_demotion_disable() and c1e_promotion_disable().  These calls
are redundant, as intel_idle_cpu_init() does the same calls just a bit
later on.  They are also premature, as the driver registration may yet
fail.

This patch removes the redundant code.

Signed-off-by: Richard Cochran <rcochran@linutronix.de>
Signed-off-by: Len Brown <len.brown@intel.com>
---
 drivers/idle/intel_idle.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/drivers/idle/intel_idle.c b/drivers/idle/intel_idle.c
index d2e7baf..c50859d 100644
--- a/drivers/idle/intel_idle.c
+++ b/drivers/idle/intel_idle.c
@@ -1300,16 +1300,10 @@ static void __init intel_idle_cpuidle_driver_init(void)
 		drv->state_count += 1;
 	}
 
-	if (icpu->auto_demotion_disable_flags)
-		on_each_cpu(auto_demotion_disable, NULL, 1);
-
 	if (icpu->byt_auto_demotion_disable_flag) {
 		wrmsrl(MSR_CC6_DEMOTION_POLICY_CONFIG, 0);
 		wrmsrl(MSR_MC6_DEMOTION_POLICY_CONFIG, 0);
 	}
-
-	if (icpu->disable_promotion_to_c1e)	/* each-cpu is redundant */
-		on_each_cpu(c1e_promotion_disable, NULL, 1);
 }
 
 
-- 
2.8.0.rc4.16.g56331f8

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 0/13] intel_idle patches ready for upstream Len Brown <lenb@kernel.org> - 2016-04-06 23:10 +0200
  [PATCH 13/13] intel_idle: Add KBL support Len Brown <lenb@kernel.org> - 2016-04-06 23:10 +0200
  [PATCH 08/13] intel_idle: Setup the timer broadcast only on successful driver load. Len Brown <lenb@kernel.org> - 2016-04-06 23:10 +0200
  [PATCH 07/13] intel_idle: Avoid a double free of the per-CPU data. Len Brown <lenb@kernel.org> - 2016-04-06 23:10 +0200
  [PATCH 02/13] intel_idle: remove useless return from void function. Len Brown <lenb@kernel.org> - 2016-04-06 23:10 +0200
  [PATCH 04/13] intel_idle: Remove redundant initialization calls. Len Brown <lenb@kernel.org> - 2016-04-06 23:10 +0200
  [PATCH 06/13] intel_idle: Fix dangling registration on error path. Len Brown <lenb@kernel.org> - 2016-04-06 23:10 +0200
  [PATCH 01/13] intel_idle: add BXT support Len Brown <lenb@kernel.org> - 2016-04-06 23:10 +0200
  [PATCH 09/13] intel_idle: Don't overreact to a cpuidle registration failure. Len Brown <lenb@kernel.org> - 2016-04-06 23:10 +0200

csiph-web