Commit 1e6419b
tracing: Have the error of __tracing_resize_ring_buffer() passed to user
[ Upstream commit 60b8f71 ]
Currently if __tracing_resize_ring_buffer() returns an error, the
tracing_resize_ringbuffer() returns -ENOMEM. But it may not be a memory
issue that caused the function to fail. If the ring buffer is memory
mapped, then the resizing of the ring buffer will be disabled. But if the
user tries to resize the buffer, it will get an -ENOMEM returned, which is
confusing because there is plenty of memory. The actual error returned was
-EBUSY, which would make much more sense to the user.
Cc: stable@vger.kernel.org
Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Cc: Vincent Donnefort <vdonnefort@google.com>
Link: https://lore.kernel.org/20250213134132.7e4505d7@gandalf.local.home
Fixes: 117c392 ("ring-buffer: Introducing ring-buffer mapping functions")
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Reviewed-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>1 parent 3284fbf commit 1e6419b
1 file changed
+1
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5998 | 5998 | | |
5999 | 5999 | | |
6000 | 6000 | | |
6001 | | - | |
6002 | | - | |
6003 | 6001 | | |
6004 | 6002 | | |
6005 | 6003 | | |
| |||
6008 | 6006 | | |
6009 | 6007 | | |
6010 | 6008 | | |
6011 | | - | |
6012 | | - | |
6013 | | - | |
6014 | | - | |
6015 | | - | |
| 6009 | + | |
6016 | 6010 | | |
6017 | 6011 | | |
6018 | 6012 | | |
| |||
0 commit comments