Re: [PATCH bpf-next v3 07/17] mm: introduce BPF OOM struct ops
From: Michal Hocko
Date: Wed Jan 28 2026 - 06:20:21 EST
Once additional point I forgot to mention previously
On Mon 26-01-26 18:44:10, Roman Gushchin wrote:
> @@ -1168,6 +1180,13 @@ bool out_of_memory(struct oom_control *oc)
> return true;
> }
>
> + /*
> + * Let bpf handle the OOM first. If it was able to free up some memory,
> + * bail out. Otherwise fall back to the kernel OOM killer.
> + */
> + if (bpf_handle_oom(oc))
> + return true;
> +
> select_bad_process(oc);
> /* Found nothing?!?! */
> if (!oc->chosen) {
Should this check for is_sysrq_oom and always use the in kernel OOM
handling for Sysrq triggered ooms as a failsafe measure?
--
Michal Hocko
SUSE Labs