]> git.baikalelectronics.ru Git - kernel.git/commit
ext4: remove an unused variable warning with CONFIG_QUOTA=n
authorAustin Kim <austindh.kim@gmail.com>
Tue, 24 Aug 2021 03:49:29 +0000 (04:49 +0100)
committerTheodore Ts'o <tytso@mit.edu>
Thu, 4 Nov 2021 14:33:25 +0000 (10:33 -0400)
commit70469878d8c688907dc091fe50fb7f91ed8feeb8
treee62391feb39edc24b40351156de6cb44c3abd3d9
parent6a38a8e807615fc853c6d3377abb27448f46dc98
ext4: remove an unused variable warning with CONFIG_QUOTA=n

The 'enable_quota' variable is only used in an CONFIG_QUOTA.
With CONFIG_QUOTA=n, compiler causes a harmless warning:

fs/ext4/super.c: In function ‘ext4_remount’:
fs/ext4/super.c:5840:6: warning: variable ‘enable_quota’ set but not used
  [-Wunused-but-set-variable]
  int enable_quota = 0;
              ^~~~~

Move 'enable_quota' into the same #ifdef CONFIG_QUOTA block
to remove an unused variable warning.

Signed-off-by: Austin Kim <austindh.kim@gmail.com>
Reviewed-by: Jan Kara <jack@suse.cz>
Link: https://lore.kernel.org/r/20210824034929.GA13415@raspberrypi
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
fs/ext4/super.c