]> www.infradead.org Git - users/jedix/linux-maple.git/commit
maple_tree: Fix potential race condition in _ma_insert
authorLiam R. Howlett <Liam.Howlett@Oracle.com>
Mon, 7 Jan 2019 19:45:10 +0000 (14:45 -0500)
committerLiam R. Howlett <Liam.Howlett@Oracle.com>
Fri, 30 Oct 2020 18:55:08 +0000 (14:55 -0400)
commit6031be9a934c343d2d22ab55824ecc854015d59b
tree867556184a4c1606293e18bc9aca947bf43cb99e
parentb0451d157dd149c68214327572e72c6b8c06764d
maple_tree: Fix potential race condition in _ma_insert

The pivots protect readers from reading invalid data.  Without a wmb
between overwriting the end pivot (of zero), there is a potential that
the writes could be reordered and a race condition would exist between
updating both values and a reader interleaving those writes.

Signed-off-by: Liam R. Howlett <Liam.Howlett@Oracle.com>
lib/maple_tree.c