HomeFreeBSD

powerpc/atomic: Fix atomic_testand_*_long on powerpc64

Description

powerpc/atomic: Fix atomic_testand_*_long on powerpc64

After b5d227b0 FreeBSD was panicking on boot with "Duplicate free" in
UMA. Analyzing the asm, the '1' mask was treated as an integer, rather
than a long, causing 'slw' (shift left word) to be used for the shifting
instruction, not 'sld' (shift left double). This means the upper bits
of the bitfield were not getting used, resulting in corruption of the
bitfield.

While fixing this, the 'and' check of the mask does not need to be
recorded, so don't record (drop the '.').

Details

Provenance
jhibbitsAuthored on Feb 3 2022, 11:20 PM
Parents
rG3b248a211382: APEI: Make sure event data fit into the buffer.
Branches
Unknown
Tags
Unknown