Skip to content

Commit 9a52a57

Browse files
Wei Yongjunpaulmckrcu
authored andcommitted
scftorture: Make symbol 'scf_torture_rand' static
The sparse tool complains as follows kernel/scftorture.c:124:1: warning: symbol '__pcpu_scope_scf_torture_rand' was not declared. Should it be static? And this per-CPU variable is not used outside of scftorture.c, so this commit marks it static. Reported-by: Hulk Robot <hulkci@huawei.com> Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com> Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
1 parent ee7035d commit 9a52a57

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

kernel/scftorture.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ static atomic_t n_alloc_errs;
134134
static bool scfdone;
135135
static char *bangstr = "";
136136

137-
DEFINE_TORTURE_RANDOM_PERCPU(scf_torture_rand);
137+
static DEFINE_TORTURE_RANDOM_PERCPU(scf_torture_rand);
138138

139139
// Print torture statistics. Caller must ensure serialization.
140140
static void scf_torture_stats_print(void)

0 commit comments

Comments
 (0)