On Thu, 13 Oct 2016, Grzegorz Andrejczuk wrote: > > +static int phi_r3mwait_disabled;
__read_mostly please. > + > /* > * Just in case our CPU detection goes bad, or you have a weird system, > * allow a way to override the automatic disabling of MPX. > @@ -61,6 +63,34 @@ void check_mpx_erratum(struct cpuinfo_x86 *c) > } > } > > +static int __init phir3mwait_disable(char *__unused) > +{ > + phi_r3mwait_disabled = 1; > + > + return 1; > +} > +__setup("phir3mwait=disable", phir3mwait_disable); This needs proper documentation in Documentation/kernel-parameters.txt > +static void __init probe_xeon_phi_r3mwait(struct cpuinfo_x86 *c) > +{ > + if (phi_r3mwait_disabled) > + return; > + > + /* > + * Setting ring 3 MONITOR/MWAIT for all threads > + * when CPU is Xeon Phi Family x200 > + * This can be disabled with phir3mwait=disable cmdline switch. And why is this information useful in this comment? > + * We preserve the reserved values and set only 2nd bit. This last sentence does not make any sense at all. Thanks, tglx