Skip to content

Commit f844282

Browse files
mhiramatrostedt
authored andcommitted
tracing: Fix to set write permission to per-cpu buffer_size_kb
Since the per-cpu buffer_size_kb file is writable for changing per-cpu ring buffer size, the file should have the write access permission. Cc: stable@vger.kernel.org Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com> Link: https://patch.msgid.link/177071301597.2293046.11683339475076917920.stgit@mhiramat.tok.corp.google.com Fixes: 21ccc9c ("tracing: Disable "other" permission bits in the tracefs files") Signed-off-by: Masami Hiramatsu (Google) <mhiramat@kernel.org> Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
1 parent f743435 commit f844282

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

kernel/trace/trace.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8613,7 +8613,7 @@ tracing_init_tracefs_percpu(struct trace_array *tr, long cpu)
86138613
trace_create_cpu_file("stats", TRACE_MODE_READ, d_cpu,
86148614
tr, cpu, &tracing_stats_fops);
86158615

8616-
trace_create_cpu_file("buffer_size_kb", TRACE_MODE_READ, d_cpu,
8616+
trace_create_cpu_file("buffer_size_kb", TRACE_MODE_WRITE, d_cpu,
86178617
tr, cpu, &tracing_entries_fops);
86188618

86198619
if (tr->range_addr_start)

0 commit comments

Comments
 (0)