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: <20250520200448.GRaCzgYFnfIjKAgAg2@fat_crate.local>
Date: Tue, 20 May 2025 22:04:48 +0200
From: Borislav Petkov <bp@...en8.de>
To: Vijay Balakrishna <vijayb@...ux.microsoft.com>
Cc: Tony Luck <tony.luck@...el.com>, Rob Herring <robh@...nel.org>,
	Krzysztof Kozlowski <krzk+dt@...nel.org>,
	Conor Dooley <conor+dt@...nel.org>,
	James Morse <james.morse@....com>,
	Mauro Carvalho Chehab <mchehab@...nel.org>,
	Robert Richter <rric@...nel.org>, linux-edac@...r.kernel.org,
	linux-kernel@...r.kernel.org, Tyler Hicks <code@...icks.com>,
	Marc Zyngier <maz@...nel.org>,
	Sascha Hauer <s.hauer@...gutronix.de>,
	Lorenzo Pieralisi <lpieralisi@...nel.org>,
	devicetree@...r.kernel.org
Subject: Re: [PATCH 1/3] drivers/edac: Add L1 and L2 error detection for A72

On Tue, May 20, 2025 at 12:54:32PM -0700, Vijay Balakrishna wrote:
> On 5/20/2025 9:09 AM, Vijay Balakrishna wrote:
> > On 5/19/2025 1:51 AM, Borislav Petkov wrote:
> > > I'd venture a guess you need to protect here against CPU hotplug...
> > > 
> > > > +    for_each_cpu_and(cpu, cpu_online_mask, &compat_mask) {
> > > > +        smp_call_function_single(cpu, read_errors, &merrsr, true);
> > > > +        report_errors(edac_ctl, cpu, &merrsr);
> > > > +    }
> > > > +}
> > > > +
> > 
> > Hi Boris,
> > 
> > I appreciate you highlighting the CPU hotplug issue. Upon further review
> > of surrounding code, I realized we must ensure that the data passed to
> > read_errors() is per-CPU.
> 
> Actually, per-CPU data not needed as we are passing true -- wait until
> function has completed on other CPUs.

What happens if @cpu above gets offlined right before you do
smp_call_function_single() ?


-- 
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ