svn commit: r335425 - stable/11/sys/compat/linuxkpi/common/include/linux
Hans Petter Selasky
hselasky at FreeBSD.org
Wed Jun 20 06:49:27 UTC 2018
Author: hselasky
Date: Wed Jun 20 06:49:26 2018
New Revision: 335425
URL: https://svnweb.freebsd.org/changeset/base/335425
Log:
MFC r334715:
Implement the might_sleep_if() function macro in the LinuxKPI.
Submitted by: Johannes Lundberg <johalun0 at gmail.com>
Sponsored by: Mellanox Technologies
Sponsored by: Limelight Networks
Modified:
stable/11/sys/compat/linuxkpi/common/include/linux/wait.h
Directory Properties:
stable/11/ (props changed)
Modified: stable/11/sys/compat/linuxkpi/common/include/linux/wait.h
==============================================================================
--- stable/11/sys/compat/linuxkpi/common/include/linux/wait.h Wed Jun 20 06:48:41 2018 (r335424)
+++ stable/11/sys/compat/linuxkpi/common/include/linux/wait.h Wed Jun 20 06:49:26 2018 (r335425)
@@ -47,6 +47,10 @@
#define might_sleep() \
WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL, "might_sleep()")
+#define might_sleep_if(cond) do { \
+ if (cond) { might_sleep(); } \
+} while (0)
+
struct wait_queue;
struct wait_queue_head;
More information about the svn-src-stable
mailing list