Whamcloud - gitweb
LU-12904 build: Support for gcc -Wimplicit-fallthrough 77/36577/2
authorShaun Tancheff <stancheff@cray.com>
Fri, 25 Oct 2019 13:13:26 +0000 (08:13 -0500)
committerOleg Drokin <green@whamcloud.com>
Fri, 6 Dec 2019 01:12:19 +0000 (01:12 +0000)
Linux 5.3 enables -Wimplicit-fallthrough
Add decorators for implicit-fallthrough compiler checks.

Test-Parameters: trivial
Cray-bug-id: LUS-8042
Signed-off-by: Shaun Tancheff <stancheff@cray.com>
Change-Id: I740062e60e1d19b967ec6b91970cdd3ab03cbab6
Reviewed-on: https://review.whamcloud.com/36577
Tested-by: jenkins <devops@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Neil Brown <neilb@suse.de>
Reviewed-by: Petros Koutoupis <pkoutoupis@cray.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
lustre/mdt/mdt_handler.c
lustre/osd-zfs/osd_object.c

index 7603903..ac39725 100644 (file)
@@ -4319,6 +4319,7 @@ static int mdt_intent_opc(enum ldlm_intent_flags it_opc,
                break;
        case IT_GETATTR:
                check_mdt_object = true;
+               /* fallthrough */
        case IT_LOOKUP:
                it_format = &RQF_LDLM_INTENT_GETATTR;
                it_handler = &mdt_intent_getattr;
index 3329093..c281207 100644 (file)
@@ -1486,6 +1486,7 @@ static int osd_declare_create(const struct lu_env *env, struct dt_object *dt,
        switch (dof->dof_type) {
                case DFT_DIR:
                        dt->do_index_ops = &osd_dir_ops;
+                       /* fallthrough */
                case DFT_INDEX:
                        /* for zap create */
                        dmu_tx_hold_zap(oh->ot_tx, DMU_NEW_OBJECT, FALSE, NULL);