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: <20250625011144.n7rb3fejm35d33oi@master>
Date: Wed, 25 Jun 2025 01:11:44 +0000
From: Wei Yang <richard.weiyang@...il.com>
To: "Liam R. Howlett" <Liam.Howlett@...cle.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
	maple-tree@...ts.infradead.org, linux-mm@...ck.org,
	linux-kernel@...r.kernel.org, Wei Yang <richard.weiyang@...il.com>,
	kernel test robot <oliver.sang@...el.com>
Subject: Re: [PATCH 1/2] maple_tree: Fix status setup on restore to active

On Tue, Jun 24, 2025 at 11:48:22AM -0400, Liam R. Howlett wrote:
>During the initial call with a maple state, an error status may be set
>before a valid node is populated into the maple state node.  Subsequent
>calls with the maple state may restore the state into an active state
>with no node set.  This was masked by the mas_walk() always resetting
>the status to ma_state and result in an extra walk in this rare
               ^^^

Nit

s/ma_state/ma_start/

>scenario.
>
>Don't restore the state to active unless there is a value in the structs
>node.  This also allows mas_walk() to be fixed to use the active state
>without exposing an issue.
>
>User visible results are marginal performance improvements when an
>active state can be restored and used instead of rewalking the tree.
>
>Stable is not Cc'ed because the existing code is stable and the
>performance gains are not worth the risk.
>
>Link: https://lore.kernel.org/all/20250611011253.19515-1-richard.weiyang@gmail.com/
>Link: https://lore.kernel.org/all/20250407231354.11771-1-richard.weiyang@gmail.com/
>Link: https://lore.kernel.org/all/202506191556.6bfc7b93-lkp@intel.com/
>Fixes: a8091f039c1e ("maple_tree: add MAS_UNDERFLOW and MAS_OVERFLOW states")
>Reported-by: Wei Yang <richard.weiyang@...il.com>
>Reported-by: kernel test robot <oliver.sang@...el.com>
>Closes: https://lore.kernel.org/oe-lkp/202506191556.6bfc7b93-lkp@intel.com
>Signed-off-by: Liam R. Howlett <Liam.Howlett@...cle.com>

Reviewed-by: Wei Yang <richard.weiyang@...il.com>

-- 
Wei Yang
Help you, Help me

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ