You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
kernel: flush delayed fput before freeing module to fix kworker crash
When a process exits while holding file-wrapper fds, fput() cannot use
task_work (the task is dying) and falls back to the system workqueue
(delayed_fput). The deferred __fput runs in a kworker and calls
f_op->release which points to module code. If rmmod frees the module
before this kworker runs, we get a fatal page fault in kworker context.
Fix: flush system_wq at the start and end of kernelsu_exit() so all
pending __fput callbacks execute while module code is still in memory.
Crash signature: kworker/u16:2, do_bad_area -> die_kernel_fault -> panic
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>