Commit 667de03a authored by Andy Shevchenko's avatar Andy Shevchenko Committed by Theodore Ts'o
Browse files

ext4: mark ctx_*_flags() with __maybe_unused



When ctx_set_flags() is unused, it prevents kernel builds
with clang, `make W=1` and CONFIG_WERROR=y:

.../ext4/super.c:2120:1: error: unused function 'ctx_set_flags' [-Werror,-Wunused-function]
 2120 | EXT4_SET_CTX(flags); /* set only */
      | ^~~~~~~~~~~~~~~~~~~

Fix this by marking ctx_*_flags() with __maybe_unused
(mark both for the sake of symmetry).

See also commit 6863f564 ("kbuild: allow Clang to find unused static
inline functions for W=1 build").

Signed-off-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://patch.msgid.link/20240905163229.140522-1-andriy.shevchenko@linux.intel.com


Signed-off-by: default avatarTheodore Ts'o <tytso@mit.edu>
parent 150c174a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment