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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZnnXNCOJ91C_CSZg@pavilion.home>
Date: Mon, 24 Jun 2024 22:29:40 +0200
From: Frederic Weisbecker <frederic@...nel.org>
To: Anna-Maria Behnsen <anna-maria@...utronix.de>
Cc: Thomas Gleixner <tglx@...utronix.de>, linux-kernel@...r.kernel.org,
	Borislav Petkov <bp@...en8.de>
Subject: Re: [PATCH v2 1/5] timer_migration: Do not rely always on
 group->parent

Le Mon, Jun 24, 2024 at 04:53:53PM +0200, Anna-Maria Behnsen a écrit :
> When reading group->parent without holding the group lock it is racy
> against CPUs coming online the first time and thereby creating another
> level of the hierarchy. This is not a problem when this value is read once
> to decide whether to abort a propagation or not. The worst outcome is an
> unnecessary/early CPU wake up. But it is racy when reading it several times
> during a single 'action' (like activation, deactivation, checking for
> remote timer expiry,...) and relying on the consitency of this value
> without holding the lock. This happens at the moment e.g. in
> tmigr_inactive_up() which is also calling tmigr_udpate_events(). Code relys
> on group->parent not to change during this 'action'.
> 
> Update parent struct member description to explain the above only
> once. Remove parent pointer checks when they are not mandatory (like update
> of data->childmask). Remove a warning, which would be nice but the trigger
> of this warning is not reliable and add expand the data structure member
> description instead. Expand a comment, why it is safe to rely on parent
> pointer here (inside hierarchy update).
> 
> Fixes: 7ee988770326 ("timers: Implement the hierarchical pull model")
> Reported-by: Borislav Petkov <bp@...en8.de>
> Signed-off-by: Anna-Maria Behnsen <anna-maria@...utronix.de>

Reviewed-by: Frederic Weisbecker <frederic@...nel.org>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ