Commit 3239f7d2 authored by Vincent Donnefort's avatar Vincent Donnefort Committed by Keir Fraser
Browse files

FROMLIST: ring-buffer: Check for empty ring-buffer with rb_num_of_entries()

Currently there are two ways of identifying an empty ring-buffer. One
relying on the current status of the commit / reader page
(rb_per_cpu_empty()) and the other on the write and read counters
(rb_num_of_entries() used in rb_get_reader_page()).

with rb_num_of_entries(). This intends to ease later
introduction of ring-buffer writers which are out of the kernel control
and with whom, the only information available is through the meta-page
counters.

Bug: 357781595
Link: https://lore.kernel.org/all/20240911093029.3279154-2-vdonnefort@google.com/


Change-Id: I143019bdaee564bddb23b5c2cb472e89d54509f1
Signed-off-by: default avatarVincent Donnefort <vdonnefort@google.com>
parent c75f42f4
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment