summaryrefslogtreecommitdiffstats
path: root/sys/sys
diff options
context:
space:
mode:
authorRenato Botelho <renato@netgate.com>2016-03-17 09:59:28 -0300
committerRenato Botelho <renato@netgate.com>2016-03-17 09:59:28 -0300
commit89ba6d490219156dc7e7779431d9de445220df9d (patch)
tree714514bba8b7b4581df0f7be45c61b01049b6b4f /sys/sys
parent56930d706911fdcf5e574a23ce39a1757907ee67 (diff)
parent3ea5fe04508eac3ddd7ebff9a4049f219d3037a6 (diff)
downloadFreeBSD-src-89ba6d490219156dc7e7779431d9de445220df9d.zip
FreeBSD-src-89ba6d490219156dc7e7779431d9de445220df9d.tar.gz
Merge remote-tracking branch 'origin/releng/10.3' into RELENG_2_3
Diffstat (limited to 'sys/sys')
-rw-r--r--sys/sys/callout.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/sys/sys/callout.h b/sys/sys/callout.h
index 6e18ae7..d3f2bca 100644
--- a/sys/sys/callout.h
+++ b/sys/sys/callout.h
@@ -62,6 +62,12 @@ struct callout_handle {
struct callout *callout;
};
+/* Flags for callout_stop_safe() */
+#define CS_DRAIN 0x0001 /* callout_drain(), wait allowed */
+#define CS_MIGRBLOCK 0x0002 /* Block migration, return value
+ indicates that the callout was
+ executing */
+
#ifdef _KERNEL
/*
* Note the flags field is actually *two* fields. The c_flags
@@ -81,7 +87,7 @@ struct callout_handle {
*/
#define callout_active(c) ((c)->c_flags & CALLOUT_ACTIVE)
#define callout_deactivate(c) ((c)->c_flags &= ~CALLOUT_ACTIVE)
-#define callout_drain(c) _callout_stop_safe(c, 1)
+#define callout_drain(c) _callout_stop_safe(c, CS_DRAIN)
void callout_init(struct callout *, int);
void _callout_init_lock(struct callout *, struct lock_object *, int);
#define callout_init_mtx(c, mtx, flags) \
OpenPOWER on IntegriCloud