x86: cpu_debug.c prepare report if files are inappropriate or CPU is not supported
PATCH 1/1 x86: cpu_debug.c prepare report if files are inappropriate or CPU is not supported
This will prepare the report to update cpu_debug. If files are inappropriate or CPU is not supported.
--- arch/x86/kernel/cpu/cpu_debug.c | 17 +++++++++++++++++ 1 files changed, 17 insertions(+), 0 deletions(-)
arch/x86/kernel/cpu/cpu_debug.c +17 -0
@@ -30,6 +30,8 @@#include <asm/apic.h> #include <asm/desc.h> +#define
@@ -838,6 +840,17 @@ static int cpu_init_allreg(unsigned cpu, struct dentry *dentry)return err; } +/* +* Prepare report for LKML and maintainer if files count are inappropriate +* Or CPU is not supported +*/ +static void send_report (int files,struct cpuinfo_x86 *cpui) +{ +WARN_ONCE (1 ,"Please report \"cpu_debug files %d for %x:%x:%x:%x\" to" +" %s\n" , files, cpui->x86_vendor, cpui->x86, cpui->x86_model, + cpui->x86_mask,static int cpu_init_cpu (void ) {struct dentry *cpu_dentry =NULL ;
@@ -861,9 +874,13 @@ static int cpu_init_cpu(void)pr_info ("cpu%d(%d) debug files %d\n" , cpu, nr_cpu_ids,per_cpu (cpu_priv_count, cpu)); +if (!per_cpu (cpu_modelflag, cpu)) +send_report (per_cpu (cpu_priv_count, cpu), cpui); +if (per_cpu (cpu_priv_count, cpu) >MAX_CPU_FILES ) {pr_err ("Register files count %d exceeds limit %d\n" ,per_cpu (cpu_priv_count, cpu),MAX_CPU_FILES ); +send_report (per_cpu (cpu_priv_count, cpu), cpui);per_cpu (cpu_priv_count, cpu) =MAX_CPU_FILES ; err = -ENFILE ; }
Signature · 1 line
1.6.0.6
arch/x86/kernel/cpu/cpu_debug.c static int cpu_init_cpu(void) · line 877
Quoted 1 line · Jaswinder Singh Rajput
arch/x86/kernel/cpu/cpu_debug.c +1
-0+if (!per_cpu (cpu_modelflag, cpu))
hm, on a second look - the whole cpu_model / cpu_modelflag business in arch/x86/kernel/cpu/cpu_debug.c looks over-complicated and broken. You encode it into a 'modelflag':
per_cpu(cpu_model, cpu) = ((cpui->x86_vendor << 16) |
(cpui->x86 << 8) |
(cpui->x86_model));just to decode it later on:
flag = per_cpu(cpu_model, cpu);
switch (flag >> 16) {That does not make much sense. Please use a proper boot_cpu_data.x86_vendor switch() statement, ok?
Ingo
Quoted 13 lines · Ingo Molnar
arch/x86/kernel/cpu/cpu_debug.c static int cpu_init_cpu(void) · line 877
Quoted 1 line · Jaswinder Singh Rajput
arch/x86/kernel/cpu/cpu_debug.c +1
-0+if (!per_cpu (cpu_modelflag, cpu))hm, on a second look - the whole
cpu_model/cpu_modelflagbusiness inarch/x86/kernel/cpu/cpu_debug.clooks over-complicated and broken. You encode it into a 'modelflag':per_cpu(cpu_model, cpu) = ((cpui->x86_vendor << 16) | (cpui->x86 << 8) | (cpui->x86_model));
Quoted 9 lines
just to decode it later on:
flag = per_cpu(cpu_model, cpu); switch (flag >> 16) {That does not make much sense. Please use a proper boot_cpu_data.x86_vendor
switch()statement, ok?
I am using flags for each cpu, in case there are different CPU in the sockets:
struct cpuinfo_x86 *cpui;
cpui = &cpu_data(cpu);
Do you still think that boot_cpu_data.x86_vendor is better option in case for multiple CPUs.
--
JSR
Quoted 24 lines · Jaswinder Singh Rajput
Quoted 13 lines · Ingo Molnar
arch/x86/kernel/cpu/cpu_debug.c static int cpu_init_cpu(void) · line 877
Quoted 1 line · Jaswinder Singh Rajput
arch/x86/kernel/cpu/cpu_debug.c +1
-0+if (!per_cpu (cpu_modelflag, cpu))hm, on a second look - the whole
cpu_model/cpu_modelflagbusiness inarch/x86/kernel/cpu/cpu_debug.clooks over-complicated and broken. You encode it into a 'modelflag':per_cpu(cpu_model, cpu) = ((cpui->x86_vendor << 16) | (cpui->x86 << 8) | (cpui->x86_model));Quoted 9 lines
just to decode it later on:
flag = per_cpu(cpu_model, cpu); switch (flag >> 16) {That does not make much sense. Please use a proper boot_cpu_data.x86_vendor
switch()statement, ok?
Quoted 8 lines
I am using flags for each cpu, in case there are different CPU in the sockets:
struct
cpuinfo_x86*cpui;
cpui =&cpu_data(cpu);Do you still think that boot_cpu_data.x86_vendor is better option in case for multiple CPUs.
yes. Assymetric SMP never really happened on x86.
Ingo
Quoted 6 lines · Ingo Molnar
Quoted 3 lines
Do you still think that boot_cpu_data.x86_vendor is better option in case for multiple CPUs.
yes. Assymetric SMP never really happened on x86.
OK, it is late here, I will send cpu_debug patches tomorrow :-)
Thanks,
--
JSR
Quoted 4 lines
Quoted 2 lines
Do you still think that boot_cpu_data.x86_vendor is better option in case for multiple CPUs.
yes. Assymetric SMP never really happened on x86.
It did but not between vendors. You can get away with a vendor assumption but cpu type (mixed 486SX/DX, PII/PIII/Celeron) mixed steppings and mixed speeds do occur. We've never supported the mixed 486SX cases but the PII/PIII cases work (or at least worked).
Alan
Quoted 10 lines · Alan Cox
Quoted 4 lines
Quoted 2 lines
Do you still think that boot_cpu_data.x86_vendor is better option in case for multiple CPUs.
yes. Assymetric SMP never really happened on x86.
It did but not between vendors. You can get away with a vendor assumption but cpu type (mixed 486SX/DX, PII/PIII/Celeron) mixed steppings and mixed speeds do occur. We've never supported the mixed 486SX cases but the PII/PIII cases work (or at least worked).
yeah - but look at the specific purpose here: we are deciding whether to print out state information related to major CPU features. Mixed steppings/speeds might happen, mixed apic / non-lapic not really.
Ingo
Quoted 13 lines · Ingo Molnar
Quoted 10 lines · Alan Cox
Quoted 4 lines
Quoted 2 lines
Do you still think that boot_cpu_data.x86_vendor is better option in case for multiple CPUs.
yes. Assymetric SMP never really happened on x86.
It did but not between vendors. You can get away with a vendor assumption but cpu type (mixed 486SX/DX, PII/PIII/Celeron) mixed steppings and mixed speeds do occur. We've never supported the mixed 486SX cases but the PII/PIII cases work (or at least worked).
Quoted 5 lines
yeah - but look at the specific purpose here: we are deciding whether to print out state information related to major CPU features. Mixed steppings/speeds might happen, mixed apic / non-lapic not really.
We are trying to debug each CPU, so we should also collect information from each CPU.
Just reading information from boot CPU and display information for all CPU is not correct. If we are getting information from boot CPU then we only need to show information for boot CPU and ignore others.
I am trying to adding more features which will be unique for each CPU/core.
So it seems current model is correct where I am collecting information for each CPU and printing information for each CPU.
Thanks,
--
JSR
Quoted 28 lines · Jaswinder Singh Rajput
Quoted 13 lines · Ingo Molnar
Quoted 10 lines · Alan Cox
Quoted 4 lines
Quoted 2 lines
Do you still think that boot_cpu_data.x86_vendor is better option in case for multiple CPUs.
yes. Assymetric SMP never really happened on x86.
It did but not between vendors. You can get away with a vendor assumption but cpu type (mixed 486SX/DX, PII/PIII/Celeron) mixed steppings and mixed speeds do occur. We've never supported the mixed 486SX cases but the PII/PIII cases work (or at least worked).
Quoted 5 lines
yeah - but look at the specific purpose here: we are deciding whether to print out state information related to major CPU features. Mixed steppings/speeds might happen, mixed apic / non-lapic not really.
We are trying to debug each CPU, so we should also collect information from each CPU.
Just reading information from boot CPU and display information for all CPU is not correct. If we are getting information from boot CPU then we only need to show information for boot CPU and ignore others.
Quoted 5 lines
I am trying to adding more features which will be unique for each CPU/core.
So it seems current model is correct where I am collecting information for each CPU and printing information for each CPU.
that's OK - and we have all the per cpu data too.
The main beef i had with your code is that it copies CPU enumeration over into some local variables (cpu_modelflag, cpu_model) with redundant encodings and decodings which dont fully work.
Is there anything that your encoding/decoding does that cannot be done via the standard methods?
Do:
git grep X86_VENDOR_INTEL arch/x86/
To see existing coding practices that make use of these facilities.
Ingo
Hello Ingo,
Quoted 7 lines · Ingo Molnar
The main beef i had with your code is that it copies CPU enumeration over into some local variables (
cpu_modelflag,cpu_model) with redundant encodings and decodings which dont fully work.Is there anything that your encoding/decoding does that cannot be done via the standard methods?
I removed cpu model info. May be this will create some issues on ancient machine as now it depends on rdmsr_safe_on_cpu() and I hope it will be safe ;-)
Can you please check this patch on ancient and latest machines.
[PATCH] x86: cpu_debug remove model information to reduce encoding-decoding
Remove model information, encoding/decoding and reduce bookkeeping.
--- arch/x86/include/asm/cpu_debug.h | 101 +--------- arch/x86/kernel/cpu/cpu_debug.c | 417 +++++++++----------------------------- 2 files changed, 97 insertions(+), 421 deletions(-)
arch/x86/include/asm/cpu_debug.h +1 -100
@@ -86,105 +86,7 @@ enum cpu_file_bit { CPU_VALUE_BIT, /* value */ }; -#define CPU_FILE_VALUE (1 << CPU_VALUE_BIT) - -/* -* DisplayFamily_DisplayModel Processor Families/Processor Number Series -* -------------------------- ------------------------------------------ -* 05_01, 05_02, 05_04 Pentium, Pentium with MMX -* -* 06_01 Pentium Pro -* 06_03, 06_05 Pentium II Xeon, Pentium II -* 06_07, 06_08, 06_0A, 06_0B Pentium III Xeon, Pentum III -* -* 06_09, 060D Pentium M -* -* 06_0E Core Duo, Core Solo -* -* 06_0F Xeon 3000, 3200, 5100, 5300, 7300 series, -* Core 2 Quad, Core 2 Extreme, Core 2 Duo, -* Pentium dual-core -* 06_17 Xeon 5200, 5400 series, Core 2 Quad Q9650 -* -* 06_1C Atom -* -* 0F_00, 0F_01, 0F_02 Xeon, Xeon MP, Pentium 4 -* 0F_03, 0F_04 Xeon, Xeon MP, Pentium 4, Pentium D -* -* 0F_06 Xeon 7100, 5000 Series, Xeon MP, -* Pentium 4, Pentium D -*/ - -/* Register processors bits */ -enum cpu_processor_bit { -CPU_NONE , -/* Intel */ -CPU_INTEL_PENTIUM_BIT , -CPU_INTEL_P6_BIT , -CPU_INTEL_PENTIUM_M_BIT , -CPU_INTEL_CORE_BIT , -CPU_INTEL_CORE2_BIT , -CPU_INTEL_ATOM_BIT , -CPU_INTEL_XEON_P4_BIT , -CPU_INTEL_XEON_MP_BIT , -/* AMD */ -CPU_AMD_K6_BIT , -CPU_AMD_K7_BIT , -CPU_AMD_K8_BIT , -CPU_AMD_0F_BIT , -CPU_AMD_10_BIT , -CPU_AMD_11_BIT , -}; - -#define CPU_INTEL_PENTIUM (1 << CPU_INTEL_PENTIUM_BIT) -#define CPU_INTEL_P6 (1 << CPU_INTEL_P6_BIT) -#define CPU_INTEL_PENTIUM_M (1 << CPU_INTEL_PENTIUM_M_BIT) -#define CPU_INTEL_CORE (1 << CPU_INTEL_CORE_BIT) -#define CPU_INTEL_CORE2 (1 << CPU_INTEL_CORE2_BIT) -#define CPU_INTEL_ATOM (1 << CPU_INTEL_ATOM_BIT) -#define CPU_INTEL_XEON_P4 (1 << CPU_INTEL_XEON_P4_BIT) -#define CPU_INTEL_XEON_MP (1 << CPU_INTEL_XEON_MP_BIT) - -#define CPU_INTEL_PX (CPU_INTEL_P6 | CPU_INTEL_PENTIUM_M) -#define CPU_INTEL_COREX (CPU_INTEL_CORE | CPU_INTEL_CORE2) -#define CPU_INTEL_XEON (CPU_INTEL_XEON_P4 | CPU_INTEL_XEON_MP) -#define CPU_CO_AT (CPU_INTEL_CORE | CPU_INTEL_ATOM) -#define CPU_C2_AT (CPU_INTEL_CORE2 | CPU_INTEL_ATOM) -#define CPU_CX_AT (CPU_INTEL_COREX | CPU_INTEL_ATOM) -#define CPU_CX_XE (CPU_INTEL_COREX | CPU_INTEL_XEON) -#define CPU_P6_XE (CPU_INTEL_P6 | CPU_INTEL_XEON) -#define CPU_PM_CO_AT (CPU_INTEL_PENTIUM_M | CPU_CO_AT) -#define CPU_C2_AT_XE (CPU_C2_AT | CPU_INTEL_XEON) -#define CPU_CX_AT_XE (CPU_CX_AT | CPU_INTEL_XEON) -#define CPU_P6_CX_AT (CPU_INTEL_P6 | CPU_CX_AT) -#define CPU_P6_CX_XE (CPU_P6_XE | CPU_INTEL_COREX) -#define CPU_P6_CX_AT_XE (CPU_INTEL_P6 | CPU_CX_AT_XE) -#define CPU_PM_CX_AT_XE (CPU_INTEL_PENTIUM_M | CPU_CX_AT_XE) -#define CPU_PM_CX_AT (CPU_INTEL_PENTIUM_M | CPU_CX_AT) -#define CPU_PM_CX_XE (CPU_INTEL_PENTIUM_M | CPU_CX_XE) -#define CPU_PX_CX_AT (CPU_INTEL_PX | CPU_CX_AT) -#define CPU_PX_CX_AT_XE (CPU_INTEL_PX | CPU_CX_AT_XE) - -/* Select all supported Intel CPUs */ -#define CPU_INTEL_ALL (CPU_INTEL_PENTIUM | CPU_PX_CX_AT_XE) - -#define CPU_AMD_K6 (1 << CPU_AMD_K6_BIT) -#define CPU_AMD_K7 (1 << CPU_AMD_K7_BIT) -#define CPU_AMD_K8 (1 << CPU_AMD_K8_BIT) -#define CPU_AMD_0F (1 << CPU_AMD_0F_BIT) -#define CPU_AMD_10 (1 << CPU_AMD_10_BIT) -#define CPU_AMD_11 (1 << CPU_AMD_11_BIT) - -#define CPU_K10_PLUS (CPU_AMD_10 | CPU_AMD_11) -#define CPU_K0F_PLUS (CPU_AMD_0F | CPU_K10_PLUS) -#define CPU_K8_PLUS (CPU_AMD_K8 | CPU_K0F_PLUS) -#define CPU_K7_PLUS (CPU_AMD_K7 | CPU_K8_PLUS) - -/* Select all supported AMD CPUs */ -#define CPU_AMD_ALL (CPU_AMD_K6 | CPU_K7_PLUS) - -/* Select all supported CPUs */ -#define CPU_ALL (CPU_INTEL_ALL | CPU_AMD_ALL) +#define CPU_FILE_VALUE (1 << CPU_VALUE_BIT)#define MAX_CPU_FILES 512
@@ -220,7 +122,6 @@ struct cpu_debug_range {unsigned min;/* Register range min */ unsigned max;/* Register range max */ unsigned flag; /* Supported flags */ - unsigned model; /* Supported models */ };#endif /* _ASM_X86_CPU_DEBUG_H */
arch/x86/kernel/cpu/cpu_debug.c +96 -321
472 lines not on this page · raw message
Signature · 1 line
1.6.0.6
Quoted 18 lines · Jaswinder Singh Rajput
Hello Ingo,
Quoted 7 lines · Ingo Molnar
The main beef i had with your code is that it copies CPU enumeration over into some local variables (
cpu_modelflag,cpu_model) with redundant encodings and decodings which dont fully work.Is there anything that your encoding/decoding does that cannot be done via the standard methods?
I removed cpu model info. May be this will create some issues on ancient machine as now it depends on
rdmsr_safe_on_cpu()and I hope it will be safe ;-)
Can you please check this patch on ancient and latest machines.
Quoted 7 lines
[PATCH] x86:
cpu_debugremove model information to reduce encoding-decodingRemove model information, encoding/decoding and reduce bookkeeping.
Reported-by Ingo Molnar <[email protected]>Signed-off-by Jaswinder Singh Rajput <[email protected]>---
If you have any objections please let me know otherwise I will start sending patches on top of this patch.
Thanks,
--
JSR
Quoted 8 lines · Jaswinder Singh Rajput
Hello Ingo,
Quoted 4 lines · Ingo Molnar
The main beef i had with your code is that it copies CPU enumeration over into some local variables (
cpu_modelflag,cpu_model) with redundant encodings and decodings which dont fully work.
Quoted 7 lines
Quoted 3 lines
Is there anything that your encoding/decoding does that cannot be done via the standard methods?
I removed cpu model info. May be this will create some issues on ancient machine as now it depends on
rdmsr_safe_on_cpu()and I hope it will be safe ;-)
rdmsr_safe() should really be safe. (If it isnt then that primitive needs fixing, not the code that uses it.)
Quoted 5 lines
Can you please check this patch on ancient and latest machines.
[PATCH] x86:
cpu_debugremove model information to reduce encoding-decoding
Quoted 8 lines
Remove model information, encoding/decoding and reduce bookkeeping.
Reported-by Ingo Molnar <[email protected]>Signed-off-by Jaswinder Singh Rajput <[email protected]>--- arch/x86/include/asm/cpu_debug.h | 101 +--------- arch/x86/kernel/cpu/cpu_debug.c | 417 +++++++++----------------------------- 2 files changed, 97 insertions(+), 421 deletions(-)
This actually looks like to be a very nice cleanup as well, as can be seen from the massive line count reduction. I'll give it some testing.
Ingo
[tip:x86/cpu] x86: cpu_debug: Remove model information to reduce encoding-decoding
In reply to Jaswinder Singh RajputCommit-ID: 5095f59bda6793a7b8f0856096d6893fe98e0e51 Gitweb: http://git.kernel.org/tip/5095f59bda6793a7b8f0856096d6893fe98e0e51 Author: Jaswinder Singh Rajput <[email protected]> AuthorDate: Fri, 5 Jun 2009 23:27:17 +0530 Committer: Ingo Molnar <[email protected]> CommitDate: Sun, 7 Jun 2009 12:22:56 +0200
x86: cpu_debug: Remove model information to reduce encoding-decoding
Remove model information, encoding/decoding and reduce bookkeeping.
This, besides removing a lot of code and cleaning up the code, also enables these features on many more CPUs that were enumerated before.
LKML-Reference: <[email protected]>
--- arch/x86/include/asm/cpu_debug.h | 101 +--------- arch/x86/kernel/cpu/cpu_debug.c | 417 +++++++++----------------------------- 2 files changed, 97 insertions(+), 421 deletions(-)
arch/x86/include/asm/cpu_debug.h +1 -100
@@ -86,105 +86,7 @@ enum cpu_file_bit { CPU_VALUE_BIT, /* value */ }; -#define CPU_FILE_VALUE (1 << CPU_VALUE_BIT) - -/* -* DisplayFamily_DisplayModel Processor Families/Processor Number Series -* -------------------------- ------------------------------------------ -* 05_01, 05_02, 05_04 Pentium, Pentium with MMX -* -* 06_01 Pentium Pro -* 06_03, 06_05 Pentium II Xeon, Pentium II -* 06_07, 06_08, 06_0A, 06_0B Pentium III Xeon, Pentum III -* -* 06_09, 060D Pentium M -* -* 06_0E Core Duo, Core Solo -* -* 06_0F Xeon 3000, 3200, 5100, 5300, 7300 series, -* Core 2 Quad, Core 2 Extreme, Core 2 Duo, -* Pentium dual-core -* 06_17 Xeon 5200, 5400 series, Core 2 Quad Q9650 -* -* 06_1C Atom -* -* 0F_00, 0F_01, 0F_02 Xeon, Xeon MP, Pentium 4 -* 0F_03, 0F_04 Xeon, Xeon MP, Pentium 4, Pentium D -* -* 0F_06 Xeon 7100, 5000 Series, Xeon MP, -* Pentium 4, Pentium D -*/ - -/* Register processors bits */ -enum cpu_processor_bit { -CPU_NONE , -/* Intel */ -CPU_INTEL_PENTIUM_BIT , -CPU_INTEL_P6_BIT , -CPU_INTEL_PENTIUM_M_BIT , -CPU_INTEL_CORE_BIT , -CPU_INTEL_CORE2_BIT , -CPU_INTEL_ATOM_BIT , -CPU_INTEL_XEON_P4_BIT , -CPU_INTEL_XEON_MP_BIT , -/* AMD */ -CPU_AMD_K6_BIT , -CPU_AMD_K7_BIT , -CPU_AMD_K8_BIT , -CPU_AMD_0F_BIT , -CPU_AMD_10_BIT , -CPU_AMD_11_BIT , -}; - -#define CPU_INTEL_PENTIUM (1 << CPU_INTEL_PENTIUM_BIT) -#define CPU_INTEL_P6 (1 << CPU_INTEL_P6_BIT) -#define CPU_INTEL_PENTIUM_M (1 << CPU_INTEL_PENTIUM_M_BIT) -#define CPU_INTEL_CORE (1 << CPU_INTEL_CORE_BIT) -#define CPU_INTEL_CORE2 (1 << CPU_INTEL_CORE2_BIT) -#define CPU_INTEL_ATOM (1 << CPU_INTEL_ATOM_BIT) -#define CPU_INTEL_XEON_P4 (1 << CPU_INTEL_XEON_P4_BIT) -#define CPU_INTEL_XEON_MP (1 << CPU_INTEL_XEON_MP_BIT) - -#define CPU_INTEL_PX (CPU_INTEL_P6 | CPU_INTEL_PENTIUM_M) -#define CPU_INTEL_COREX (CPU_INTEL_CORE | CPU_INTEL_CORE2) -#define CPU_INTEL_XEON (CPU_INTEL_XEON_P4 | CPU_INTEL_XEON_MP) -#define CPU_CO_AT (CPU_INTEL_CORE | CPU_INTEL_ATOM) -#define CPU_C2_AT (CPU_INTEL_CORE2 | CPU_INTEL_ATOM) -#define CPU_CX_AT (CPU_INTEL_COREX | CPU_INTEL_ATOM) -#define CPU_CX_XE (CPU_INTEL_COREX | CPU_INTEL_XEON) -#define CPU_P6_XE (CPU_INTEL_P6 | CPU_INTEL_XEON) -#define CPU_PM_CO_AT (CPU_INTEL_PENTIUM_M | CPU_CO_AT) -#define CPU_C2_AT_XE (CPU_C2_AT | CPU_INTEL_XEON) -#define CPU_CX_AT_XE (CPU_CX_AT | CPU_INTEL_XEON) -#define CPU_P6_CX_AT (CPU_INTEL_P6 | CPU_CX_AT) -#define CPU_P6_CX_XE (CPU_P6_XE | CPU_INTEL_COREX) -#define CPU_P6_CX_AT_XE (CPU_INTEL_P6 | CPU_CX_AT_XE) -#define CPU_PM_CX_AT_XE (CPU_INTEL_PENTIUM_M | CPU_CX_AT_XE) -#define CPU_PM_CX_AT (CPU_INTEL_PENTIUM_M | CPU_CX_AT) -#define CPU_PM_CX_XE (CPU_INTEL_PENTIUM_M | CPU_CX_XE) -#define CPU_PX_CX_AT (CPU_INTEL_PX | CPU_CX_AT) -#define CPU_PX_CX_AT_XE (CPU_INTEL_PX | CPU_CX_AT_XE) - -/* Select all supported Intel CPUs */ -#define CPU_INTEL_ALL (CPU_INTEL_PENTIUM | CPU_PX_CX_AT_XE) - -#define CPU_AMD_K6 (1 << CPU_AMD_K6_BIT) -#define CPU_AMD_K7 (1 << CPU_AMD_K7_BIT) -#define CPU_AMD_K8 (1 << CPU_AMD_K8_BIT) -#define CPU_AMD_0F (1 << CPU_AMD_0F_BIT) -#define CPU_AMD_10 (1 << CPU_AMD_10_BIT) -#define CPU_AMD_11 (1 << CPU_AMD_11_BIT) - -#define CPU_K10_PLUS (CPU_AMD_10 | CPU_AMD_11) -#define CPU_K0F_PLUS (CPU_AMD_0F | CPU_K10_PLUS) -#define CPU_K8_PLUS (CPU_AMD_K8 | CPU_K0F_PLUS) -#define CPU_K7_PLUS (CPU_AMD_K7 | CPU_K8_PLUS) - -/* Select all supported AMD CPUs */ -#define CPU_AMD_ALL (CPU_AMD_K6 | CPU_K7_PLUS) - -/* Select all supported CPUs */ -#define CPU_ALL (CPU_INTEL_ALL | CPU_AMD_ALL) +#define CPU_FILE_VALUE (1 << CPU_VALUE_BIT)#define MAX_CPU_FILES 512
@@ -220,7 +122,6 @@ struct cpu_debug_range {unsigned min;/* Register range min */ unsigned max;/* Register range max */ unsigned flag; /* Supported flags */ - unsigned model; /* Supported models */ };#endif /* _ASM_X86_CPU_DEBUG_H */
arch/x86/kernel/cpu/cpu_debug.c +96 -321
472 lines not on this page · raw message