Thread (5 messages) 5 messages, 3 authors, 2025-10-13

Re: [PATCH 2/2] tracing: Stop fortify-string from warning in tracing_mark_raw_write()

From: Steven Rostedt <rostedt@goodmis.org>
Date: 2025-10-13 17:05:37
Also in: lkml, stable

On Sun, 12 Oct 2025 12:34:08 +0900
Masami Hiramatsu (Google) [off-list ref] wrote:
quoted
Use a void pointer and get the offset via offsetof() to keep fortify
string from warning about this copy.

Cc: stable@vger.kernel.org
Fixes: 64cf7d058a00 ("tracing: Have trace_marker use per-cpu data to read user space")
Reported-by: syzbot+9a2ede1643175f350105@syzkaller.appspotmail.com
Closes: https://lore.kernel.org/all/68e973f5.050a0220.1186a4.0010.GAE@google.com/ (local)
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>  
Ah, fixed already.

Acked-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
Actually this was the wrong fix. Before submitting a pull request, I looked
to see if there was a better way to handle this and discovered "unsafe_memcpy()"
which is the proper solution:

  https://lore.kernel.org/all/20251011112032.77be18e4@gandalf.local.home/ (local)

-- 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