core.c (3e7759b94a0fcfdd6771caa64a37dda7ce825874) core.c (a9da6ddaef9ef7d9afd3f89e447c60e38f74bf44)
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * Data Access Monitor
4 *
5 * Author: SeongJae Park <sjpark@amazon.de>
6 */
7
8#define pr_fmt(fmt) "damon: " fmt

--- 694 unchanged lines hidden (view full) ---

703{
704 struct task_struct *tsk;
705
706 mutex_lock(&ctx->kdamond_lock);
707 tsk = ctx->kdamond;
708 if (tsk) {
709 get_task_struct(tsk);
710 mutex_unlock(&ctx->kdamond_lock);
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * Data Access Monitor
4 *
5 * Author: SeongJae Park <sjpark@amazon.de>
6 */
7
8#define pr_fmt(fmt) "damon: " fmt

--- 694 unchanged lines hidden (view full) ---

703{
704 struct task_struct *tsk;
705
706 mutex_lock(&ctx->kdamond_lock);
707 tsk = ctx->kdamond;
708 if (tsk) {
709 get_task_struct(tsk);
710 mutex_unlock(&ctx->kdamond_lock);
711 kthread_stop(tsk);
712 put_task_struct(tsk);
711 kthread_stop_put(tsk);
713 return 0;
714 }
715 mutex_unlock(&ctx->kdamond_lock);
716
717 return -EPERM;
718}
719
720/**

--- 811 unchanged lines hidden ---
712 return 0;
713 }
714 mutex_unlock(&ctx->kdamond_lock);
715
716 return -EPERM;
717}
718
719/**

--- 811 unchanged lines hidden ---