Page MenuHomeFreeBSD

atomic_common.h: Fix the volatile qualifier placement in atomic_load_ptr
ClosedPublic

Authored by jrtc27 on Sep 20 2020, 10:31 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Apr 22, 2:19 PM
Unknown Object (File)
Fri, Apr 17, 11:40 AM
Unknown Object (File)
Thu, Apr 16, 9:38 PM
Unknown Object (File)
Tue, Apr 14, 1:51 PM
Unknown Object (File)
Sat, Apr 11, 1:42 PM
Unknown Object (File)
Sat, Apr 11, 4:13 AM
Unknown Object (File)
Thu, Apr 9, 2:15 AM
Unknown Object (File)
Mon, Apr 6, 11:34 PM
Subscribers

Details

Summary

This was broken in r357940 which introduced the __typeof use. We need
the volatile qualifier to be on the pointee not the pointer otherwise it
does nothing. This was found by mhorne in D26498, noticing there was a
problem (a spin loop condition was hoisted for RISC-V boot code) but not
the root cause of it.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable