diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2025-01-12 08:06:45 +0000 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2025-01-15 13:14:35 +0100 |
commit | 268b36116f2f048d2fb0cd13aa3036705fcac068 (patch) | |
tree | 8653ef6c0458d6456f5ec2f2941bacebe35f8590 /fs/debugfs/internal.h | |
parent | ee9c69388e3bad6c595fe38f34aa1126d2d07a11 (diff) |
debugfs: separate cache for debugfs inodes
Embed them into container (struct debugfs_inode_info, with nothing
else in it at the moment), set the cache up, etc.
Just the infrastructure changes letting us augment debugfs inodes
here; adding stuff will come at the next step.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Reviewed-by: Christian Brauner <brauner@kernel.org>
Link: https://lore.kernel.org/r/20250112080705.141166-1-viro@zeniv.linux.org.uk
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/debugfs/internal.h')
-rw-r--r-- | fs/debugfs/internal.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/fs/debugfs/internal.h b/fs/debugfs/internal.h index bbae4a228ef4..5cb940b0b8f6 100644 --- a/fs/debugfs/internal.h +++ b/fs/debugfs/internal.h @@ -11,6 +11,15 @@ struct file_operations; +struct debugfs_inode_info { + struct inode vfs_inode; +}; + +static inline struct debugfs_inode_info *DEBUGFS_I(struct inode *inode) +{ + return container_of(inode, struct debugfs_inode_info, vfs_inode); +} + /* declared over in file.c */ extern const struct file_operations debugfs_noop_file_operations; extern const struct file_operations debugfs_open_proxy_file_operations; |