From: He Zhe <zhe...@windriver.com>

commit 8d7b6374d5af2c31ce9501d3502808e3c7a9ea68 upstream

A compilation -Wimplicit-fallthrough warning was enabled by commit
a035d552a93b ("Makefile: Globally enable fall-through warning")
and triggers the following warning.

fs/aufs/opts.h:78:11:
warning: this statement may fall through [-Wimplicit-fallthrough=]

This patch adds comments according GNU manual.
https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html#Warning-Options

Signed-off-by: He Zhe <zhe...@windriver.com>
See-also: 
https://www.mail-archive.com/aufs-users@lists.sourceforge.net/msg05685.html
(cherry picked from commit e7619996b014c5d8fd2f6ad89542c545a207667f)
---
 fs/aufs/opts.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/fs/aufs/opts.c b/fs/aufs/opts.c
index d370108..01fae8b 100644
--- a/fs/aufs/opts.c
+++ b/fs/aufs/opts.c
@@ -1499,8 +1499,10 @@ static int au_opt_br(struct super_block *sb, struct 
au_opt *opt,
                if (opt->add.bindex < 0)
                        opt->add.bindex = 0;
                goto add;
+               /* Always goto add, not fallthrough */
        case Opt_prepend:
                opt->add.bindex = 0;
+               /* fallthrough */
        add: /* indented label */
        case Opt_add:
                err = au_br_add(sb, &opt->add,
-- 
2.7.4

-- 
_______________________________________________
linux-yocto mailing list
linux-yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/linux-yocto

Reply via email to