git: DragonFly_RELEASE_6_4 atomic(9): Add relaxed load/store variants from FreeBSD

Aaron LI aly at crater.dragonflybsd.org
Wed Sep 2 05:53:59 PDT 2026


commit 068147c8796d4d46e6983c25c848f9079e9e877c
Author: Aaron LI <aly at aaronly.me>
Date:   Sun Jan 14 15:27:33 2024 +0800

    atomic(9): Add relaxed load/store variants from FreeBSD
    
    Obtained from FreeBSD.  However, the original atomic_store_ptr() macro
    was causing '-Wcast-qual' warnings, so I changed it based on the
    NetBSD's atomic_store_relaxed().
    
    Actually, I found NetBSD's version more clean, but we import the FreeBSD
    version to help import code/drivers in the future.
    
    Discussed-with: dillon

Summary of changes:
 share/man/man9/atomic.9         |  27 +++++----
 sys/cpu/x86_64/include/atomic.h |   3 +-
 sys/sys/atomic_common.h         | 131 ++++++++++++++++++++++++++++++++++++++++
 3 files changed, 146 insertions(+), 15 deletions(-)
 create mode 100644 sys/sys/atomic_common.h

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/068147c8796d4d46e6983c25c848f9079e9e877c


-- 
DragonFly BSD source repository


More information about the Commits mailing list