]> git.baikalelectronics.ru Git - kernel.git/commit
xfs: fix variable state usage
authorDarrick J. Wong <djwong@kernel.org>
Mon, 6 Jun 2022 01:51:22 +0000 (18:51 -0700)
committerDarrick J. Wong <djwong@kernel.org>
Thu, 16 Jun 2022 06:13:32 +0000 (23:13 -0700)
commit48c2ca93e1529595f1bf8a0c4eb0732d9ecd867c
treea4ce83de600ff391f074e15d53a7ca404c3b6d3a
parent676e39f80795f73aa28a06eb16b829dedcea46e1
xfs: fix variable state usage

The variable @args is fed to a tracepoint, and that's the only place
it's used.  This is fine for the kernel, but for userspace, tracepoints
are #define'd out of existence, which results in this warning on gcc
11.2:

xfs_attr.c: In function ‘xfs_attr_node_try_addname’:
xfs_attr.c:1440:42: warning: unused variable ‘args’ [-Wunused-variable]
 1440 |         struct xfs_da_args              *args = attr->xattri_da_args;
      |                                          ^~~~

Clean this up.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Allison Henderson <allison.henderson@oracle.com>
fs/xfs/libxfs/xfs_attr.c