Thread (21 messages) flat view 21 messages, 3 authors, 23d ago

Re: [PATCH v9 3/4] ring-buffer: Cap static ring buffer nr_pages

From: Steven Rostedt <rostedt@goodmis.org>
Date: 2026-09-04 14:01:46
Also in: lkml

On Fri, 4 Sep 2026 14:04:40 +0100
Vincent Donnefort [off-list ref] wrote:
quoted
If you want to add something, we could add to the beginning of this
function:

	/* Prevent ridiculously small sizes */
	if (size < PAGE_SIZE)
		return NULL;

to shut up Sashiko about overflows :-p

-- Steve  
tracer_alloc_buffers() uses size of 1 for non-expanded buffers.

I'll test size just before 

  nr_pages = (size - sizeof(struct ring_buffer_cpu_meta)) /
  	(subbuf_size + sizeof(int));
Ack.

-- Steve
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help