]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commit
eventfs: Do not treat events directory different than other directories
authorSteven Rostedt (Google) <rostedt@goodmis.org>
Thu, 2 May 2024 20:08:26 +0000 (16:08 -0400)
committerSteven Rostedt (Google) <rostedt@goodmis.org>
Sat, 4 May 2024 08:25:37 +0000 (04:25 -0400)
commit22e61e15af731dbe46704c775d2335e56fcef4e9
treed5eb4cbea4121aaad70375c1ae4e75b6be1d0cfa
parentd53891d348ac3eceaf48f4732a1f4f5c0e0a55ce
eventfs: Do not treat events directory different than other directories

Treat the events directory the same as other directories when it comes to
permissions. The events directory was considered different because it's
dentry is persistent, whereas the other directory dentries are created
when accessed. But the way tracefs now does its ownership by using the
root dentry's permissions as the default permissions, the events directory
can get out of sync when a remount is performed setting the group and user
permissions.

Remove the special case for the events directory on setting the
attributes. This allows the updates caused by remount to work properly as
well as simplifies the code.

Link: https://lore.kernel.org/linux-trace-kernel/20240502200906.002923579@goodmis.org
Cc: stable@vger.kernel.org
Cc: Masami Hiramatsu <mhiramat@kernel.org>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Fixes: 8186fff7ab649 ("tracefs/eventfs: Use root and instance inodes as default ownership")
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
fs/tracefs/event_inode.c