On Thu, Feb 13, 2020 at 10:12:05PM +0800, Coly Li wrote: > + /* > + * In case previous btree check operation occupies too many > + * system memory for bcache btree node cache, and the > + * registering process is selected by OOM killer. Here just > + * ignore the SIGKILL sent by OOM killer if there is, to > + * avoid kthread_run() being failed by pending signals. The > + * bcache registering process will exit after the registration > + * done. > + */ > + if (signal_pending(current)) > + flush_signals(current); > + > + k = kthread_run(bch_allocator_thread, ca, "bcache_allocator"); This really needs to go into the kthread code itself instead of requiring cargo culting in the callers.