From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wei Wang Subject: [PATCH v4 04/11] x86/intel_pstate: avoid calling cpufreq_add_cpu() twice Date: Thu, 25 Jun 2015 19:15:22 +0800 Message-ID: <1435230922-22111-1-git-send-email-wei.w.wang@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: jbeulich@suse.com, andrew.cooper3@citrix.com, xen-devel@lists.xen.org Cc: Wei Wang List-Id: xen-devel@lists.xenproject.org cpufreq_add_cpu() is already called in the hypercall code path (the bottom of set_px_pminfo() and inside cpufreq_cpu_init()). So, we remove the redundant calling here. v4 changes: None. Signed-off-by: Wei Wang --- xen/drivers/cpufreq/cpufreq.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/xen/drivers/cpufreq/cpufreq.c b/xen/drivers/cpufreq/cpufreq.c index ab66884..91b6c25 100644 --- a/xen/drivers/cpufreq/cpufreq.c +++ b/xen/drivers/cpufreq/cpufreq.c @@ -632,8 +632,6 @@ static struct notifier_block cpu_nfb = { static int __init cpufreq_presmp_init(void) { - void *cpu = (void *)(long)smp_processor_id(); - cpu_callback(&cpu_nfb, CPU_ONLINE, cpu); register_cpu_notifier(&cpu_nfb); return 0; } -- 1.9.1