Skip to content

Commit ae9e557

Browse files
committed
time: Export tick start/stop functions for rcutorture
It turns out that rcutorture needs to ensure that the scheduling-clock interrupt is enabled in CONFIG_NO_HZ_FULL kernels before starting on CPU-bound in-kernel processing. This commit therefore exports tick_nohz_dep_set_task(), tick_nohz_dep_clear_task(), and tick_nohz_full_setup() to GPL kernel modules. Reported-by: kbuild test robot <[email protected]> Signed-off-by: Paul E. McKenney <[email protected]>
1 parent 01b4c39 commit ae9e557

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

kernel/time/tick-sched.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,7 @@ static void tick_sched_handle(struct tick_sched *ts, struct pt_regs *regs)
172172
#ifdef CONFIG_NO_HZ_FULL
173173
cpumask_var_t tick_nohz_full_mask;
174174
bool tick_nohz_full_running;
175+
EXPORT_SYMBOL_GPL(tick_nohz_full_running);
175176
static atomic_t tick_dep_mask;
176177

177178
static bool check_tick_dependency(atomic_t *dep)
@@ -351,11 +352,13 @@ void tick_nohz_dep_set_task(struct task_struct *tsk, enum tick_dep_bits bit)
351352
*/
352353
tick_nohz_dep_set_all(&tsk->tick_dep_mask, bit);
353354
}
355+
EXPORT_SYMBOL_GPL(tick_nohz_dep_set_task);
354356

355357
void tick_nohz_dep_clear_task(struct task_struct *tsk, enum tick_dep_bits bit)
356358
{
357359
atomic_andnot(BIT(bit), &tsk->tick_dep_mask);
358360
}
361+
EXPORT_SYMBOL_GPL(tick_nohz_dep_clear_task);
359362

360363
/*
361364
* Set a per-taskgroup tick dependency. Posix CPU timers need this in order to elapse
@@ -404,6 +407,7 @@ void __init tick_nohz_full_setup(cpumask_var_t cpumask)
404407
cpumask_copy(tick_nohz_full_mask, cpumask);
405408
tick_nohz_full_running = true;
406409
}
410+
EXPORT_SYMBOL_GPL(tick_nohz_full_setup);
407411

408412
static int tick_nohz_cpu_down(unsigned int cpu)
409413
{

0 commit comments

Comments
 (0)