On Tue, May 28, 2024 at 9:32 AM Shankar Seal <Shankar.Seal=40microsoft.com@xxxxxxxxxxxxxx> wrote: > > Adding bpf@xxxxxxxxxxxxxxx > > A common use case of an BPF ring buffer map to use as a queue of events generated by BPF programs that can be read in-order by user space applications. I have a scenario requirement for a user space application to write into a ring buffer (or similar) map, such that events by BPF programs in kernel and user space applications are interleaved in the order they were generated, that can be consumed by another user space application > > I would like to implement this new feature in the https://github.com/microsoft/ebpf-for-windows project. But before I go ahead with the implementation, I wanted to check if there is any way to accomplish this in Linux today? If not, is there any reason why this should not be done? Yes, there is. See user_ring_buffer ([0], [1]). [0] https://github.com/torvalds/linux/blob/master/tools/testing/selftests/bpf/prog_tests/user_ringbuf.c [1] https://github.com/torvalds/linux/blob/master/tools/testing/selftests/bpf/progs/user_ringbuf_success.c > > Thanks, > Shankar > শংকর শীল > > > > ________________________________ > From: Shankar Seal > Sent: Tuesday, May 28, 2024 12:40 AM > To: bpf@xxxxxxxx <bpf@xxxxxxxx> > Subject: Writing into a ring buffer map from user space > > > I have a scenario requirement for a user space application to write into a ring buffer eBPF map that I would like to implement in the https://github.com/microsoft/ebpf-for-windows project. Is there any way to accomplish this in Linux today? If not, is there any reason why this should not be done? > > > Thanks, > Shankar > শংকর শীল > > > > -- > Bpf mailing list -- bpf@xxxxxxxx > To unsubscribe send an email to bpf-leave@xxxxxxxx