diff options
author | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2014-01-30 18:49:29 -0500 |
---|---|---|
committer | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2014-02-23 12:01:12 -0500 |
commit | 36970bb91d89618d3495babf44b934e9c9db6bbc (patch) | |
tree | cee37f3089c868338f626124124fe2f90c26cdbd /include/linux/torture.h | |
parent | 4622b487ecf0094401ac10e504606e5cbdea5a6e (diff) |
rcutorture: Privatize fullstop
This commit introduces the torture_must_stop() function in order to
keep use of the fullstop variable local to kernel/torture.c. There
is also a torture_must_stop_irq() counterpart for use from RCU callbacks,
timeout handlers, and the like.
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Diffstat (limited to 'include/linux/torture.h')
-rw-r--r-- | include/linux/torture.h | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/include/linux/torture.h b/include/linux/torture.h index 742d8a402f19..0259db38bfb0 100644 --- a/include/linux/torture.h +++ b/include/linux/torture.h | |||
@@ -41,12 +41,6 @@ | |||
41 | module_param(name, type, 0444); \ | 41 | module_param(name, type, 0444); \ |
42 | MODULE_PARM_DESC(name, msg); | 42 | MODULE_PARM_DESC(name, msg); |
43 | 43 | ||
44 | /* Mediate rmmod and system shutdown. Concurrent rmmod & shutdown illegal! */ | ||
45 | #define FULLSTOP_DONTSTOP 0 /* Normal operation. */ | ||
46 | #define FULLSTOP_SHUTDOWN 1 /* System shutdown with rcutorture running. */ | ||
47 | #define FULLSTOP_RMMOD 2 /* Normal rmmod of rcutorture. */ | ||
48 | extern int fullstop; | ||
49 | |||
50 | #define TORTURE_FLAG "-torture:" | 44 | #define TORTURE_FLAG "-torture:" |
51 | #define TOROUT_STRING(s) \ | 45 | #define TOROUT_STRING(s) \ |
52 | pr_alert("%s" TORTURE_FLAG s "\n", torture_type) | 46 | pr_alert("%s" TORTURE_FLAG s "\n", torture_type) |
@@ -85,5 +79,7 @@ void torture_shutdown_absorb(const char *title); | |||
85 | void torture_init_begin(char *ttype, bool v); | 79 | void torture_init_begin(char *ttype, bool v); |
86 | void torture_init_end(void); | 80 | void torture_init_end(void); |
87 | bool torture_cleanup(void); | 81 | bool torture_cleanup(void); |
82 | bool torture_must_stop(void); | ||
83 | bool torture_must_stop_irq(void); | ||
88 | 84 | ||
89 | #endif /* __LINUX_TORTURE_H */ | 85 | #endif /* __LINUX_TORTURE_H */ |