Re: [PATCH bpf-next v1 1/3] x86/mm: Resolve BPF exception fixups for user address faults under SMAP
From: Borislav Petkov
Date: Sun Nov 22 2026 - 21:56:06 EST
On Mon, Nov 23, 2026 at 01:59:32AM +0100, Kumar Kartikeya Dwivedi wrote:
> I also don't understand your security concern.
Was:
"the only line of defense is for is_bpf_text_address() to really DTRT."
not clear?
Do you want me to elaborate?
> Thus far, I've tried to provide reasonable explanations for this
> change and clarified how it impacts nothing other than BPF's own
> behavior. At that point in the fault handler, without this exception
> handling fixup, the kernel will panic.
>
> Instead of paying instrumentation overhead to get to that point, we'd
> like to shift that cost to that path, that is already otherwise going
> to lead to a panic, to instead continue the BPF program.
>
> I don't think being dismissive, telling us to "go back to the drawing
> board" without understanding how BPF works, or arguing "BPF people
> will do bad things to the kernel if we accept this" leads to a
> productive discussion.
Lemme try to parse what you're saying: I don't understand BPF, I should not
question the BPF "design" and I should simply shut up and accept your change
because you keep repeating the same argument over and over again - performance
- and that is absolutely very important and the page fault handler should be
changed to special-case bpf programs.
Right?
Anything else I am missing?
In any case, here's my answer: NAK to that patch.
--
Regards/Gruss,
Boris.
https://people.kernel.org/tglx/notes-about-netiquette