x86/CPU: Make intel_num_cpu_cores() generic
authorDavid Wang <davidwang@zhaoxin.com>
Thu, 3 May 2018 02:32:44 +0000 (10:32 +0800)
committerThomas Gleixner <tglx@linutronix.de>
Sun, 13 May 2018 10:06:12 +0000 (12:06 +0200)
commit2cc61be60e37b1856a97ccbdcca3e86e593bf06a
treea4d2eae5b8d11c1b2dd1ca8afb2a4be3c99b4e52
parentb5cf8707e6c9d85819b4bee3218ec560953149f7
x86/CPU: Make intel_num_cpu_cores() generic

intel_num_cpu_cores() is a static function in intel.c which can't be used
by other files. Define another function called detect_num_cpu_cores() in
common.c to replace this function so it can be reused.

Signed-off-by: David Wang <davidwang@zhaoxin.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: lukelin@viacpu.com
Cc: qiyuanwang@zhaoxin.com
Cc: gregkh@linuxfoundation.org
Cc: brucechang@via-alliance.com
Cc: timguo@zhaoxin.com
Cc: cooperyan@zhaoxin.com
Cc: hpa@zytor.com
Cc: benjaminpan@viatech.com
Link: https://lkml.kernel.org/r/1525314766-18910-2-git-send-email-davidwang@zhaoxin.com
arch/x86/kernel/cpu/common.c
arch/x86/kernel/cpu/cpu.h
arch/x86/kernel/cpu/intel.c