svn commit: r349276 - head/sys/compat/linuxkpi/common/include/asm
Johannes Lundberg
johalun at FreeBSD.org
Fri Jun 21 16:43:18 UTC 2019
Author: johalun
Date: Fri Jun 21 16:43:16 2019
New Revision: 349276
URL: https://svnweb.freebsd.org/changeset/base/349276
Log:
LinuxKPI: Add atomic_long_sub macro.
Reviewed by: imp (mentor), hps
Approved by: imp (mentor), hps
MFC after: 1 week
Differential Revision: D20718
Modified:
head/sys/compat/linuxkpi/common/include/asm/atomic-long.h
Modified: head/sys/compat/linuxkpi/common/include/asm/atomic-long.h
==============================================================================
--- head/sys/compat/linuxkpi/common/include/asm/atomic-long.h Fri Jun 21 16:02:26 2019 (r349275)
+++ head/sys/compat/linuxkpi/common/include/asm/atomic-long.h Fri Jun 21 16:43:16 2019 (r349276)
@@ -42,6 +42,7 @@ typedef struct {
} atomic_long_t;
#define atomic_long_add(i, v) atomic_long_add_return((i), (v))
+#define atomic_long_sub(i, v) atomic_long_add_return(-(i), (v))
#define atomic_long_inc_return(v) atomic_long_add_return(1, (v))
#define atomic_long_inc_not_zero(v) atomic_long_add_unless((v), 1, 0)
More information about the svn-src-head
mailing list