Re: [PATCH 1/1] io_uring/bpf-ops: restrict ctx access to BPF

Jens Axboe <[email protected]>
Newsgroups org.kernel.vger.io-uring
Message-ID <178042083663.560797.8108073756982087463.b4-ty@b4>
On Tue, 02 Jun 2026 11:08:25 +0100, Pavel Begunkov wrote:
> BPF programs should have no need in looking into struct io_ring_ctx, if
> anything, most of such cases would be anti patterns like looking up ring
> indices directly via the context.
> 
> Replace it with a new empty structure, which is just an alias to struct
> io_ring_ctx. It'll create a new BTF type and fail verification if a BPF
> program tries to access it (beyond the first byte). It'll also give more
> flexibility for the future, and otherwise it can be made aligned with
> io_ring_ctx as before with struct groups if ever needed or extended in a
> different way.
> 
> [...]

Applied, thanks!

[1/1] io_uring/bpf-ops: restrict ctx access to BPF
      commit: ec02fe217fa66d79f8a65e8d28be9295c7f85093

Best regards,
-- 
Jens Axboe
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.