lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20091109075957.GH453@elte.hu>
Date:	Mon, 9 Nov 2009 08:59:57 +0100
From:	Ingo Molnar <mingo@...e.hu>
To:	Yong Wang <yong.y.wang@...ux.intel.com>,
	Borislav Petkov <borislav.petkov@....com>
Cc:	"H. Peter Anvin" <hpa@...or.com>,
	Thomas Gleixner <tglx@...utronix.de>,
	Suresh Siddha <suresh.b.siddha@...el.com>,
	Arjan van de Ven <arjan@...radead.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v3] x86: under bios control, restore AP's APIC_LVTTHMR to
 the BSP value


* Yong Wang <yong.y.wang@...ux.intel.com> wrote:

> On Mon, Nov 09, 2009 at 08:08:44AM +0100, Ingo Molnar wrote:
> > 
> > * Yong Wang <yong.y.wang@...ux.intel.com> wrote:
> > 
> > > Changes since v2:
> > > Incorporate Ingo's comments to get BSP's thermal init value in a
> > > 'boot-CPU-only' function.
> > 
> > > diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
> > > index e09f0e2..2323771 100644
> > > --- a/arch/x86/kernel/setup.c
> > > +++ b/arch/x86/kernel/setup.c
> > > @@ -1002,6 +1002,7 @@ void __init setup_arch(char **cmdline_p)
> > >  
> > >  	init_apic_mappings();
> > >  	ioapic_init_mappings();
> > > +	get_bsp_lvtthmr_init();
> > >  
> > >  	/* need to wait for io_apic is mapped */
> > >  	probe_nr_irqs_gsi();
> > 
> > Ok - it's almost good in this form - it would be nice to name the new 
> > function something more generic, like mcheck_intel_therm_init(), and 
> > call it from arch/x86/kernel/cpu/mcheck/mce.c's mcheck_init() function.
> > 
> 
> I just checked that arch/x86/kernel/cpu/mcheck/mce.c's mcheck_init() 
> will not only run on BSP but also on APs. I put get_bsp_lvtthmr_init() 
> right behind init_apic_mappings() because init_apic_mappings() will 
> setup the fixmap for LAPIC so that I can call apic_read from inside 
> get_bsp_lvtthmr_init().

That's true in Linus's tree but Boris Petkov fixed the MCE init 
functions naming mess in the x86 tree, in these commits:

 b33a636: x86, mce: Add a global MCE init helper
 5e09954: x86, mce: Fix up MCE naming nomenclature

Please base your patch on:

  http://people.redhat.com/mingo/tip.git/README

to have the latest MCE code. So if you stick that init function into 
mcheck_init() in -tip it should be called once per bootup only. (I have 
not checked the other boot dependencies, please do that.)

Thanks,

	Ingo
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ