x86/cpu: Print CPU Family/Vendor infomation in both decimal and hexidecimal
PATCH 1/1 x86/cpu: Print CPU Family/Vendor infomation in both decimal and hexidecimal
Different manuals use different representations.
A new sample looks like:
(XEN) CPU Vendor: Intel, Family 6 (0x6), Model 60 (0x3c), Stepping 3 (raw 000306c3)
---
CC: Jan Beulich <[email protected]>
--- xen/arch/x86/cpu/common.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)
xen/arch/x86/cpu/common.c +4 -2
@@ -238,8 +238,10 @@ static void __init early_cpu_detect(void) c->x86_capability[cpufeat_word (X86_FEATURE_SSE3 )] = ecx;printk (XENLOG_INFO -"CPU Vendor: %s, Family %u, Model %u, Stepping %u (raw %08x)\n" , - this_cpu->c_vendor, c->x86, c->x86_model, c->x86_mask, eax); +"CPU Vendor: %s, Family %u (%#x), Model %u (%#x), " +"Stepping %u (raw %08x)\n" , + this_cpu->c_vendor, c->x86, c->x86, + c->x86_model, c->x86_model, c->x86_mask, eax); eax =cpuid_eax (0x80000000 );if ((eax >>16 ) ==0x8000 && eax >=0x80000008 ) {
Signature · 7 lines
2.1.4 _______________________________________________ Xen-devel mailing list [email protected] https://lists.xen.org/xen-devel
Quoted 9 lines
Quoted 1 line
Quoted 1 line · On 12.09.16 at 11:30, <[email protected]> wrote:
Different manuals use different representations.
A new sample looks like:
(XEN) CPU Vendor: Intel, Family 6 (
0x6), Model 60 (0x3c), Stepping 3 (raw000306c3)Signed-off-by Andrew Cooper <[email protected]>
provided ...
xen/arch/x86/cpu/common.c static void __init early_cpu_detect(void) · line 244
Quoted 12 lines
xen/arch/x86/cpu/common.c +4
-2@@ -238,8 +238,10 @@ static void __init early_cpu_detect(void) c->x86_capability[cpufeat_word (X86_FEATURE_SSE3 )] = ecx;printk (XENLOG_INFO -"CPU Vendor: %s, Family %u, Model %u, Stepping %u (raw %08x)\n" , - this_cpu->c_vendor, c->x86, c->x86_model, c->x86_mask, eax); +"CPU Vendor: %s, Family %u (%#x), Model %u (%#x), " +"Stepping %u (raw %08x)\n" , + this_cpu->c_vendor, c->x86, c->x86, + c->x86_model, c->x86_model, c->x86_mask, eax);
... you switch back to Linux indentation here. I'd also prefer if you didn't break the format string across lines, despite if it getting long.
Jan
_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel
Quoted 18 lines · Jan Beulich
Quoted 9 lines
Quoted 1 line
Quoted 1 line · On 12.09.16 at 11:30, <[email protected]> wrote:
Different manuals use different representations.
A new sample looks like:
(XEN) CPU Vendor: Intel, Family 6 (
0x6), Model 60 (0x3c), Stepping 3 (raw000306c3)Signed-off-by Andrew Cooper <[email protected]>Acked-by Jan Beulich <[email protected]>provided ...
Quoted 5 lines
xen/arch/x86/cpu/common.c +0
-0@@ -238,8 +238,10 @@ static void __init early_cpu_detect(void) c->x86_capability[cpufeat_word (X86_FEATURE_SSE3 )] = ecx;
Quoted 8 lines
xen/arch/x86/cpu/common.c static void __init early_cpu_detect(void) · line 244
Quoted 7 lines
xen/arch/x86/cpu/common.c +4
-2printk (XENLOG_INFO -"CPU Vendor: %s, Family %u, Model %u, Stepping %u (raw %08x)\n" , - this_cpu->c_vendor, c->x86, c->x86_model, c->x86_mask, eax); +"CPU Vendor: %s, Family %u (%#x), Model %u (%#x), " +"Stepping %u (raw %08x)\n" , + this_cpu->c_vendor, c->x86, c->x86, + c->x86_model, c->x86_model, c->x86_mask, eax);... you switch back to Linux indentation here.
I already noticed and fixed up locally.
Quoted 3 lines
I'd also prefer if
you didn't break the format string across lines, despite if it getting long.
Ok - will do.
~Andrew
_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel