]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
xfs: only create event xfs_file_compat_ioctl when CONFIG_COMPAT is configure
authorSteven Rostedt <rostedt@goodmis.org>
Mon, 16 Jun 2025 17:51:58 +0000 (13:51 -0400)
committerCarlos Maiolino <cem@kernel.org>
Thu, 24 Jul 2025 15:30:12 +0000 (17:30 +0200)
The trace event xfs_file_compat_ioctl is only used when CONFIG_COMPAT is
configured in the build. As trace events can take up to 5K in memory for
text and meta data regardless if they are used, they should not be created
when unused. Add #ifdef CONFIG_COMPAT around the event so that it is only
created when that is configured.

Fixes: cca28fb83d9e6 ("xfs: split xfs_itrace_entry")
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Signed-off-by: Carlos Maiolino <cem@kernel.org>
fs/xfs/xfs_trace.h

index f0bd1df576816b5ccb95248b43766ab57c77bda0..6addebd764b0e55cc2433e833705202671b2992b 100644 (file)
@@ -1079,7 +1079,9 @@ DEFINE_INODE_EVENT(xfs_get_acl);
 #endif
 DEFINE_INODE_EVENT(xfs_vm_bmap);
 DEFINE_INODE_EVENT(xfs_file_ioctl);
+#ifdef CONFIG_COMPAT
 DEFINE_INODE_EVENT(xfs_file_compat_ioctl);
+#endif
 DEFINE_INODE_EVENT(xfs_ioctl_setattr);
 DEFINE_INODE_EVENT(xfs_dir_fsync);
 DEFINE_INODE_EVENT(xfs_file_fsync);