[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CABRcYmLg3NG3VDDojxhX0sh89CAYksYAcMHmKcobGWrXVihMdQ@mail.gmail.com>
Date: Fri, 7 Mar 2025 18:18:05 +0100
From: Florent Revest <revest@...omium.org>
To: Borislav Petkov <bp@...en8.de>
Cc: Dave Hansen <dave.hansen@...el.com>, linux-kernel@...r.kernel.org, tglx@...utronix.de,
mingo@...hat.com, dave.hansen@...ux.intel.com, x86@...nel.org, hpa@...or.com,
stable@...r.kernel.org
Subject: Re: [PATCH] x86/microcode/AMD: Fix out-of-bounds on systems with
CPU-less NUMA nodes
On Fri, Mar 7, 2025 at 5:44 PM Borislav Petkov <bp@...en8.de> wrote:
>
> On Fri, Mar 07, 2025 at 08:32:20AM -0800, Dave Hansen wrote:
> > On 3/7/25 07:58, Florent Revest wrote:
> > > One thing I'm not entirely sure about is that
> > > for_each_node_with_cpus() is implemented on top of
> > > for_each_online_node(). This differs from the current code which uses
> > > for_each_node(). I can't tell if iterating over offline nodes is a bug
>
> You better not have offlined nodes when applying microcode. The path you're
> landing in here has already hotplug disabled, tho.
>
> > > or a feature of load_microcode_amd() so this would be an extra change
> > > to the business logic which I can't really explain/justify.
> >
> > Actually, the per-node caches seem to have gone away at some point too.
> > Boris would know the history. This might need a a cleanup like Boris
> > alluded to in 05e91e7211383. This might not even need a nid loop.
>
> Nah, the cache is still there. For now...
>
> for_each_node_with_cpus() should simply work unless I'm missing some other
> angle...
Awesome - thank you both! I'll send a v2 using
for_each_node_with_cpus() ... On Monday :) Have a good weekend!
Powered by blists - more mailing lists