Skip to content

Commit dd8389d

Browse files
kerneltoastrsuntk
authored andcommitted
kernel: Fix kernel panics caused by thread info flag corruption
Signed-off-by: Sultan Alsawaf <[email protected]>
1 parent cc388ce commit dd8389d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

kernel/core_hook.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,9 +129,9 @@ static void disable_seccomp(struct task_struct *tsk)
129129
// disable seccomp
130130
#if defined(CONFIG_GENERIC_ENTRY) && \
131131
LINUX_VERSION_CODE >= KERNEL_VERSION(5, 11, 0)
132-
current_thread_info()->syscall_work &= ~SYSCALL_WORK_SECCOMP;
132+
clear_syscall_work(SECCOMP);
133133
#else
134-
current_thread_info()->flags &= ~(TIF_SECCOMP | _TIF_SECCOMP);
134+
clear_thread_flag(TIF_SECCOMP);
135135
#endif
136136

137137
#ifdef CONFIG_SECCOMP

0 commit comments

Comments
 (0)