Steven Rostedt (Google) 6e3d7c903c eventfs: Cleanup permissions in creation of inodes
The permissions being set during the creation of the inodes was updating
eventfs_inode attributes as well. Those attributes should only be touched
by the setattr or remount operations, not during the creation of inodes.
The eventfs_inode attributes should only be used to set the inodes and
should not be modified during the inode creation.

Simplify the code and fix the situation by:

 1) Removing the eventfs_find_events() and doing a simple lookup for
    the events descriptor in eventfs_get_inode()

 2) Remove update_events_attr() as the attributes should only be used
    to update the inode and should not be modified here.

 3) Add update_inode_attr() that uses the attributes to determine what
    the inode permissions should be.

 4) As the parent_inode of the eventfs_root_inode structure is no longer
    needed, remove it.

Now on creation, the inode gets the proper permissions without causing
side effects to the ei->attr field.

Link: https://lore.kernel.org/lkml/20240522165031.944088388@goodmis.org

Cc: Linus Torvalds <torvalds@linux-foundation.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>
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
2024-05-23 09:31:50 -04:00
..
2024-05-01 18:07:38 +01:00
2024-05-13 12:14:03 -07:00
2024-01-11 20:11:35 -08:00
2024-05-13 11:40:06 -07:00
2024-05-14 19:42:24 -07:00
2024-03-27 13:17:15 +01:00
2024-05-13 14:14:05 -07:00
\n
2024-03-13 14:30:58 -07:00
2024-05-13 11:40:06 -07:00
2024-05-13 11:40:06 -07:00
2024-05-14 17:35:22 -07:00
2023-12-29 11:58:34 -08:00
2024-04-09 10:53:44 +02:00
2024-03-27 13:17:15 +01:00
2024-03-12 14:27:37 -07:00
2024-05-13 12:14:03 -07:00
2024-04-29 14:22:24 -07:00
2024-05-13 11:40:06 -07:00
2024-05-15 08:43:02 -07:00
2024-05-17 17:31:24 -07:00
2024-05-13 14:14:05 -07:00
2024-03-27 13:17:15 +01:00
2024-05-13 11:40:06 -07:00
2024-05-13 11:40:06 -07:00
2024-03-12 20:03:34 -07:00
2024-03-11 10:07:03 -07:00
2024-05-10 08:26:31 +02:00
2024-03-12 20:03:34 -07:00
2023-12-12 14:24:14 +01:00
2024-03-15 09:00:09 -07:00
2024-03-13 12:53:53 -07:00
2024-04-17 13:49:44 +02:00
2024-03-11 10:21:06 -07:00
2024-05-13 11:40:06 -07:00
2024-03-13 12:53:53 -07:00
2024-03-12 20:03:34 -07:00
2024-03-13 12:53:53 -07:00
2024-02-02 13:11:49 +01:00
2024-03-12 20:03:34 -07:00
2024-04-07 13:49:02 +02:00
2024-05-02 16:28:20 +02:00
2024-04-10 16:23:04 -06:00
2024-03-26 09:01:18 +01:00
2024-03-27 13:17:15 +01:00
2024-04-10 16:23:02 -06:00
2024-05-13 12:23:17 -07:00
2024-02-15 23:43:47 -05:00