kernel: Fix kernel panics caused by thread info flag corruption

Signed-off-by: Sultan Alsawaf <sultan@kerneltoast.com>
This commit is contained in:
Sultan Alsawaf
2025-10-18 19:37:24 -07:00
committed by ShirkNeko
parent 2fdb933acc
commit 3cdb8fd057

View File

@@ -139,9 +139,9 @@ static void disable_seccomp(struct task_struct *tsk)
// disable seccomp // disable seccomp
#if defined(CONFIG_GENERIC_ENTRY) && \ #if defined(CONFIG_GENERIC_ENTRY) && \
LINUX_VERSION_CODE >= KERNEL_VERSION(5, 11, 0) LINUX_VERSION_CODE >= KERNEL_VERSION(5, 11, 0)
current_thread_info()->syscall_work &= ~SYSCALL_WORK_SECCOMP; clear_syscall_work(SECCOMP);
#else #else
current_thread_info()->flags &= ~(TIF_SECCOMP | _TIF_SECCOMP); clear_thread_flag(TIF_SECCOMP);
#endif #endif
#ifdef CONFIG_SECCOMP #ifdef CONFIG_SECCOMP