summaryrefslogtreecommitdiff
path: root/arch/x86/kernel/cpu/common.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@google.com>2018-07-31 20:08:13 +0200
committerGreg Kroah-Hartman <gregkh@google.com>2018-07-31 20:08:13 +0200
commit8ec9fd8936b20ca2d18160f8b18acb4b732c2771 (patch)
treea339057501d8e92500ff6e7854b09fe0c39f3430 /arch/x86/kernel/cpu/common.c
parent8ddb600e033f69a1316e65d6af21eb3dc11501f2 (diff)
parentecb99897516f0bb433f3e79df3b1958c80ac4810 (diff)
Merge 4.4.142 into android-4.4
Changes in 4.4.142 Kbuild: fix # escaping in .cmd files for future Make x86/cpu: Probe CPUID leaf 6 even when cpuid_level == 6 perf tools: Move syscall number fallbacks from perf-sys.h to tools/arch/x86/include/asm/ Linux 4.4.142 Change-Id: If45535d0aeb1ad6f7239d3bc15aa4d3d60754da7 Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Diffstat (limited to 'arch/x86/kernel/cpu/common.c')
-rw-r--r--arch/x86/kernel/cpu/common.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/arch/x86/kernel/cpu/common.c b/arch/x86/kernel/cpu/common.c
index 814276d0eed1..736e2843139b 100644
--- a/arch/x86/kernel/cpu/common.c
+++ b/arch/x86/kernel/cpu/common.c
@@ -686,13 +686,14 @@ void get_cpu_cap(struct cpuinfo_x86 *c)
c->x86_capability[CPUID_1_EDX] = edx;
}
+ /* Thermal and Power Management Leaf: level 0x00000006 (eax) */
+ if (c->cpuid_level >= 0x00000006)
+ c->x86_capability[CPUID_6_EAX] = cpuid_eax(0x00000006);
+
/* Additional Intel-defined flags: level 0x00000007 */
if (c->cpuid_level >= 0x00000007) {
cpuid_count(0x00000007, 0, &eax, &ebx, &ecx, &edx);
-
c->x86_capability[CPUID_7_0_EBX] = ebx;
-
- c->x86_capability[CPUID_6_EAX] = cpuid_eax(0x00000006);
c->x86_capability[CPUID_7_ECX] = ecx;
}