• Gustavo A. R. Silva's avatar
    xfs: Fix multiple fall-through warnings for Clang · 5937e000
    Gustavo A. R. Silva authored
    In preparation to enable -Wimplicit-fallthrough for Clang, fix
    the following warnings by replacing /* fallthrough */ comments,
    and its variants, with the new pseudo-keyword macro fallthrough:
    
    fs/xfs/libxfs/xfs_attr.c:487:2: warning: unannotated fall-through between switch labels [-Wimplicit-fallthrough]
    fs/xfs/libxfs/xfs_attr.c:500:2: warning: unannotated fall-through between switch labels [-Wimplicit-fallthrough]
    fs/xfs/libxfs/xfs_attr.c:532:2: warning: unannotated fall-through between switch labels [-Wimplicit-fallthrough]
    fs/xfs/libxfs/xfs_attr.c:594:2: warning: unannotated fall-through between switch labels [-Wimplicit-fallthrough]
    fs/xfs/libxfs/xfs_attr.c:607:2: warning: unannotated fall-through between switch labels [-Wimplicit-fallthrough]
    fs/xfs/libxfs/xfs_attr.c:1410:2: warning: unannotated fall-through between switch labels [-Wimplicit-fallthrough]
    fs/xfs/libxfs/xfs_attr.c:1445:2: warning: unannotated fall-through between switch labels [-Wimplicit-fallthrough]
    fs/xfs/libxfs/xfs_attr.c:1473:2: warning: unannotated fall-through between switch labels [-Wimplicit-fallthrough]
    
    Notice that Clang doesn't recognize /* fallthrough */ comments as
    implicit fall-through markings, so in order to globally enable
    -Wimplicit-fallthrough for Clang, these comments need to be
    replaced with fallthrough; in the whole codebase.
    
    Link: https://github.com/KSPP/linux/issues/115Reviewed-by: default avatarKees Cook <keescook@chromium.org>
    Signed-off-by: default avatarGustavo A. R. Silva <gustavoars@kernel.org>
    5937e000
xfs_attr.c 40.5 KB