Re: [PATCH bpf-next v3 10/11] bpf: Allow nospec-protected var-offset stack access

2025-05-13 Thread Kumar Kartikeya Dwivedi
On Thu, 1 May 2025 at 04:17, Luis Gerhorst wrote: > > Insert a nospec before the access to prevent it from ever using an index > that is subject to speculative scalar-confusion. > > The access itself can either happen directly in the BPF program (reads > only, check_stack_read_var_off()) or in a h

Re: [PATCH bpf-next v3 10/11] bpf: Allow nospec-protected var-offset stack access

2025-05-01 Thread Kumar Kartikeya Dwivedi
On Thu, 1 May 2025 at 10:17, Luis Gerhorst wrote: > > Insert a nospec before the access to prevent it from ever using an index > that is subject to speculative scalar-confusion. > > The access itself can either happen directly in the BPF program (reads > only, check_stack_read_var_off()) or in a h

[PATCH bpf-next v3 10/11] bpf: Allow nospec-protected var-offset stack access

2025-05-01 Thread Luis Gerhorst
Insert a nospec before the access to prevent it from ever using an index that is subject to speculative scalar-confusion. The access itself can either happen directly in the BPF program (reads only, check_stack_read_var_off()) or in a helper (read/write, check_helper_mem_access()). This relies on