Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 102
b: refs/heads/master
c: ebfcaa9
h: refs/heads/master
v: v3
  • Loading branch information
Andi Kleen authored and Linus Torvalds committed Apr 16, 2005
1 parent fc266e9 commit c1ad1fc
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 9 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 229992446b12fbc755825b6a9f38fc6a273e1f19
refs/heads/master: ebfcaa96fccc01301a577c5c56a5f00543cf167e
13 changes: 6 additions & 7 deletions trunk/arch/x86_64/kernel/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -673,7 +673,7 @@ static int __init get_model_name(struct cpuinfo_x86 *c)
{
unsigned int *v;

if (c->x86_cpuid_level < 0x80000004)
if (c->extended_cpuid_level < 0x80000004)
return 0;

v = (unsigned int *) c->x86_model_id;
Expand All @@ -689,7 +689,7 @@ static void __init display_cacheinfo(struct cpuinfo_x86 *c)
{
unsigned int n, dummy, eax, ebx, ecx, edx;

n = c->x86_cpuid_level;
n = c->extended_cpuid_level;

if (n >= 0x80000005) {
cpuid(0x80000005, &dummy, &ebx, &ecx, &edx);
Expand Down Expand Up @@ -781,7 +781,7 @@ static int __init init_amd(struct cpuinfo_x86 *c)
}
display_cacheinfo(c);

if (c->x86_cpuid_level >= 0x80000008) {
if (c->extended_cpuid_level >= 0x80000008) {
c->x86_num_cores = (cpuid_ecx(0x80000008) & 0xff) + 1;
if (c->x86_num_cores & (c->x86_num_cores - 1))
c->x86_num_cores = 1;
Expand Down Expand Up @@ -841,7 +841,6 @@ static void __init detect_ht(struct cpuinfo_x86 *c)
if (smp_num_siblings & (smp_num_siblings - 1))
index_msb++;

/* RED-PEN surely this must run in the non HT case too! -AK */
cpu_core_id[cpu] = phys_pkg_id(index_msb);

if (c->x86_num_cores > 1)
Expand Down Expand Up @@ -878,7 +877,7 @@ static void __init init_intel(struct cpuinfo_x86 *c)
unsigned n;

init_intel_cacheinfo(c);
n = c->x86_cpuid_level;
n = c->extended_cpuid_level;
if (n >= 0x80000008) {
unsigned eax = cpuid_eax(0x80000008);
c->x86_virt_bits = (eax >> 8) & 0xff;
Expand Down Expand Up @@ -927,7 +926,7 @@ void __init early_identify_cpu(struct cpuinfo_x86 *c)
c->x86_cache_alignment = c->x86_clflush_size;
c->x86_num_cores = 1;
c->x86_apicid = c == &boot_cpu_data ? 0 : c - cpu_data;
c->x86_cpuid_level = 0;
c->extended_cpuid_level = 0;
memset(&c->x86_capability, 0, sizeof c->x86_capability);

/* Get vendor name */
Expand Down Expand Up @@ -974,7 +973,7 @@ void __init identify_cpu(struct cpuinfo_x86 *c)

/* AMD-defined flags: level 0x80000001 */
xlvl = cpuid_eax(0x80000000);
c->x86_cpuid_level = xlvl;
c->extended_cpuid_level = xlvl;
if ((xlvl & 0xffff0000) == 0x80000000) {
if (xlvl >= 0x80000001) {
c->x86_capability[1] = cpuid_edx(0x80000001);
Expand Down
2 changes: 1 addition & 1 deletion trunk/include/asm-x86_64/processor.h
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ struct cpuinfo_x86 {
__u8 x86_num_cores;
__u8 x86_apicid;
__u32 x86_power;
__u32 x86_cpuid_level; /* Max CPUID function supported */
__u32 extended_cpuid_level; /* Max extended CPUID function supported */
unsigned long loops_per_jiffy;
} ____cacheline_aligned;

Expand Down

0 comments on commit c1ad1fc

Please sign in to comment.