Re: [PATCH 6/5] x86/nmi: Support watchdogs on Intel Fam18/19 CPUs
Jan Beulich <[email protected]>
| Newsgroups | gmane.comp.emulators.xen.devel |
|---|---|
| Message-ID | <[email protected]> |
On 17.08.2026 19:23, Andrew Cooper wrote: > It is the Pentium 4 (Fam15) which is the odd-one-out. The counter indicies > used in the P6 went on to be declared architectural, and Fam18/19 continue > using the architectural indices. Do you really mean P6? The code in hunk context uses both P6_EVENT_CPU_CLOCKS_NOT_HALTED, CORE_EVENT_CPU_CLOCKS_NOT_HALTED, and I'm pretty sure that if anything became architectural, it would be what Core uses. > Signed-off-by: Andrew Cooper <[email protected]> > --- > CC: Jan Beulich <[email protected]> > CC: Roger Pau Monné <[email protected]> > CC: Teddy Astie <[email protected]> > > This wants backporting to 4.21. So does "Check MSR_MISC_ENABLE for all Intel > platforms" on which it texturally depends. Sure; that other one first has to go in though. For both - why do you say specifically 4.21? Stuff to support newer families may be reasonably natural to go onto the most recent major release. If it was to also go further back, I then wouldn't quite see why to stop at 4.21. Surely the MSR_MISC_ENABLE one I intend to put onto everything back to 4.20. > --- a/xen/arch/x86/nmi.c > +++ b/xen/arch/x86/nmi.c > @@ -329,17 +329,12 @@ void setup_apic_nmi_watchdog(void) > break; > } > > - switch ( boot_cpu_data.family ) > - { > - case 6: > + if ( boot_cpu_data.family == 15 ) > + setup_p4_watchdog(misc); > + else > setup_p6_watchdog((boot_cpu_data.model < 14) This model check surely applies to family 6 only? Hence why we may be better off sticking to the use of switch(). Jan > ? P6_EVENT_CPU_CLOCKS_NOT_HALTED > : CORE_EVENT_CPU_CLOCKS_NOT_HALTED); > - break; > - case 15: > - setup_p4_watchdog(misc); > - break; > - } > break; > } >