diff options
Diffstat (limited to 'sys/security')
-rw-r--r-- | sys/security/mac/mac_framework.c | 5 | ||||
-rw-r--r-- | sys/security/mac/mac_internal.h | 5 | ||||
-rw-r--r-- | sys/security/mac/mac_net.c | 5 | ||||
-rw-r--r-- | sys/security/mac/mac_pipe.c | 5 | ||||
-rw-r--r-- | sys/security/mac/mac_process.c | 5 | ||||
-rw-r--r-- | sys/security/mac/mac_syscalls.c | 5 | ||||
-rw-r--r-- | sys/security/mac/mac_system.c | 5 | ||||
-rw-r--r-- | sys/security/mac/mac_vfs.c | 5 |
8 files changed, 24 insertions, 16 deletions
diff --git a/sys/security/mac/mac_framework.c b/sys/security/mac/mac_framework.c index e9d9eeb..e98a50c 100644 --- a/sys/security/mac/mac_framework.c +++ b/sys/security/mac/mac_framework.c @@ -264,7 +264,7 @@ static int mac_policy_list_busy; } while (0) /* - * We manually invoke WITNESS_SLEEP() to allow Witness to generate + * We manually invoke WITNESS_WARN() to allow Witness to generate * warnings even if we don't end up ever triggering the wait at * run-time. The consumer of the exclusive interface must not hold * any locks (other than potentially Giant) since we may sleep for @@ -273,7 +273,8 @@ static int mac_policy_list_busy; * be made. */ #define MAC_POLICY_LIST_EXCLUSIVE() do { \ - WITNESS_SLEEP(1, NULL); \ + WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL, \ + "mac_policy_list_exclusive() at %s:%d", __FILE__, __LINE__);\ mtx_lock(&mac_policy_list_lock); \ while (mac_policy_list_busy != 0) \ cv_wait(&mac_policy_list_not_busy, \ diff --git a/sys/security/mac/mac_internal.h b/sys/security/mac/mac_internal.h index e9d9eeb..e98a50c 100644 --- a/sys/security/mac/mac_internal.h +++ b/sys/security/mac/mac_internal.h @@ -264,7 +264,7 @@ static int mac_policy_list_busy; } while (0) /* - * We manually invoke WITNESS_SLEEP() to allow Witness to generate + * We manually invoke WITNESS_WARN() to allow Witness to generate * warnings even if we don't end up ever triggering the wait at * run-time. The consumer of the exclusive interface must not hold * any locks (other than potentially Giant) since we may sleep for @@ -273,7 +273,8 @@ static int mac_policy_list_busy; * be made. */ #define MAC_POLICY_LIST_EXCLUSIVE() do { \ - WITNESS_SLEEP(1, NULL); \ + WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL, \ + "mac_policy_list_exclusive() at %s:%d", __FILE__, __LINE__);\ mtx_lock(&mac_policy_list_lock); \ while (mac_policy_list_busy != 0) \ cv_wait(&mac_policy_list_not_busy, \ diff --git a/sys/security/mac/mac_net.c b/sys/security/mac/mac_net.c index e9d9eeb..e98a50c 100644 --- a/sys/security/mac/mac_net.c +++ b/sys/security/mac/mac_net.c @@ -264,7 +264,7 @@ static int mac_policy_list_busy; } while (0) /* - * We manually invoke WITNESS_SLEEP() to allow Witness to generate + * We manually invoke WITNESS_WARN() to allow Witness to generate * warnings even if we don't end up ever triggering the wait at * run-time. The consumer of the exclusive interface must not hold * any locks (other than potentially Giant) since we may sleep for @@ -273,7 +273,8 @@ static int mac_policy_list_busy; * be made. */ #define MAC_POLICY_LIST_EXCLUSIVE() do { \ - WITNESS_SLEEP(1, NULL); \ + WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL, \ + "mac_policy_list_exclusive() at %s:%d", __FILE__, __LINE__);\ mtx_lock(&mac_policy_list_lock); \ while (mac_policy_list_busy != 0) \ cv_wait(&mac_policy_list_not_busy, \ diff --git a/sys/security/mac/mac_pipe.c b/sys/security/mac/mac_pipe.c index e9d9eeb..e98a50c 100644 --- a/sys/security/mac/mac_pipe.c +++ b/sys/security/mac/mac_pipe.c @@ -264,7 +264,7 @@ static int mac_policy_list_busy; } while (0) /* - * We manually invoke WITNESS_SLEEP() to allow Witness to generate + * We manually invoke WITNESS_WARN() to allow Witness to generate * warnings even if we don't end up ever triggering the wait at * run-time. The consumer of the exclusive interface must not hold * any locks (other than potentially Giant) since we may sleep for @@ -273,7 +273,8 @@ static int mac_policy_list_busy; * be made. */ #define MAC_POLICY_LIST_EXCLUSIVE() do { \ - WITNESS_SLEEP(1, NULL); \ + WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL, \ + "mac_policy_list_exclusive() at %s:%d", __FILE__, __LINE__);\ mtx_lock(&mac_policy_list_lock); \ while (mac_policy_list_busy != 0) \ cv_wait(&mac_policy_list_not_busy, \ diff --git a/sys/security/mac/mac_process.c b/sys/security/mac/mac_process.c index e9d9eeb..e98a50c 100644 --- a/sys/security/mac/mac_process.c +++ b/sys/security/mac/mac_process.c @@ -264,7 +264,7 @@ static int mac_policy_list_busy; } while (0) /* - * We manually invoke WITNESS_SLEEP() to allow Witness to generate + * We manually invoke WITNESS_WARN() to allow Witness to generate * warnings even if we don't end up ever triggering the wait at * run-time. The consumer of the exclusive interface must not hold * any locks (other than potentially Giant) since we may sleep for @@ -273,7 +273,8 @@ static int mac_policy_list_busy; * be made. */ #define MAC_POLICY_LIST_EXCLUSIVE() do { \ - WITNESS_SLEEP(1, NULL); \ + WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL, \ + "mac_policy_list_exclusive() at %s:%d", __FILE__, __LINE__);\ mtx_lock(&mac_policy_list_lock); \ while (mac_policy_list_busy != 0) \ cv_wait(&mac_policy_list_not_busy, \ diff --git a/sys/security/mac/mac_syscalls.c b/sys/security/mac/mac_syscalls.c index e9d9eeb..e98a50c 100644 --- a/sys/security/mac/mac_syscalls.c +++ b/sys/security/mac/mac_syscalls.c @@ -264,7 +264,7 @@ static int mac_policy_list_busy; } while (0) /* - * We manually invoke WITNESS_SLEEP() to allow Witness to generate + * We manually invoke WITNESS_WARN() to allow Witness to generate * warnings even if we don't end up ever triggering the wait at * run-time. The consumer of the exclusive interface must not hold * any locks (other than potentially Giant) since we may sleep for @@ -273,7 +273,8 @@ static int mac_policy_list_busy; * be made. */ #define MAC_POLICY_LIST_EXCLUSIVE() do { \ - WITNESS_SLEEP(1, NULL); \ + WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL, \ + "mac_policy_list_exclusive() at %s:%d", __FILE__, __LINE__);\ mtx_lock(&mac_policy_list_lock); \ while (mac_policy_list_busy != 0) \ cv_wait(&mac_policy_list_not_busy, \ diff --git a/sys/security/mac/mac_system.c b/sys/security/mac/mac_system.c index e9d9eeb..e98a50c 100644 --- a/sys/security/mac/mac_system.c +++ b/sys/security/mac/mac_system.c @@ -264,7 +264,7 @@ static int mac_policy_list_busy; } while (0) /* - * We manually invoke WITNESS_SLEEP() to allow Witness to generate + * We manually invoke WITNESS_WARN() to allow Witness to generate * warnings even if we don't end up ever triggering the wait at * run-time. The consumer of the exclusive interface must not hold * any locks (other than potentially Giant) since we may sleep for @@ -273,7 +273,8 @@ static int mac_policy_list_busy; * be made. */ #define MAC_POLICY_LIST_EXCLUSIVE() do { \ - WITNESS_SLEEP(1, NULL); \ + WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL, \ + "mac_policy_list_exclusive() at %s:%d", __FILE__, __LINE__);\ mtx_lock(&mac_policy_list_lock); \ while (mac_policy_list_busy != 0) \ cv_wait(&mac_policy_list_not_busy, \ diff --git a/sys/security/mac/mac_vfs.c b/sys/security/mac/mac_vfs.c index e9d9eeb..e98a50c 100644 --- a/sys/security/mac/mac_vfs.c +++ b/sys/security/mac/mac_vfs.c @@ -264,7 +264,7 @@ static int mac_policy_list_busy; } while (0) /* - * We manually invoke WITNESS_SLEEP() to allow Witness to generate + * We manually invoke WITNESS_WARN() to allow Witness to generate * warnings even if we don't end up ever triggering the wait at * run-time. The consumer of the exclusive interface must not hold * any locks (other than potentially Giant) since we may sleep for @@ -273,7 +273,8 @@ static int mac_policy_list_busy; * be made. */ #define MAC_POLICY_LIST_EXCLUSIVE() do { \ - WITNESS_SLEEP(1, NULL); \ + WITNESS_WARN(WARN_GIANTOK | WARN_SLEEPOK, NULL, \ + "mac_policy_list_exclusive() at %s:%d", __FILE__, __LINE__);\ mtx_lock(&mac_policy_list_lock); \ while (mac_policy_list_busy != 0) \ cv_wait(&mac_policy_list_not_busy, \ |