diff mbox series

btrfs: Use fallthrough;

Message ID 20200616185429.1648-1-marcos@mpdesouza.com (mailing list archive)
State New, archived
Headers show
Series btrfs: Use fallthrough; | expand

Commit Message

Marcos Paulo de Souza June 16, 2020, 6:54 p.m. UTC
From: Marcos Paulo de Souza <mpdesouza@suse.com>

Convert /* Fallthrough */ comments to fallthrough;

Signed-off-by: Marcos Paulo de Souza <mpdesouza@suse.com>
---
 fs/btrfs/ctree.c | 2 +-
 fs/btrfs/super.c | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

Comments

Johannes Thumshirn June 17, 2020, 8:21 a.m. UTC | #1
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
David Sterba June 17, 2020, 4:07 p.m. UTC | #2
On Tue, Jun 16, 2020 at 03:54:29PM -0300, Marcos Paulo de Souza wrote:
> From: Marcos Paulo de Souza <mpdesouza@suse.com>
> 
> Convert /* Fallthrough */ comments to fallthrough;

You should convert all instances of the fall through comments.
Marcos Paulo de Souza June 17, 2020, 4:59 p.m. UTC | #3
On Wed, 2020-06-17 at 18:07 +0200, David Sterba wrote:
> On Tue, Jun 16, 2020 at 03:54:29PM -0300, Marcos Paulo de Souza
> wrote:
> > From: Marcos Paulo de Souza <mpdesouza@suse.com>
> > 
> > Convert /* Fallthrough */ comments to fallthrough;
> 
> You should convert all instances of the fall through comments.

Indeed, just found more cases. I'll send a v2 soon.
diff mbox series

Patch

diff --git a/fs/btrfs/ctree.c b/fs/btrfs/ctree.c
index de7ad39bcafd..70e49d8d4f6c 100644
--- a/fs/btrfs/ctree.c
+++ b/fs/btrfs/ctree.c
@@ -1196,7 +1196,7 @@  __tree_mod_log_rewind(struct btrfs_fs_info *fs_info, struct extent_buffer *eb,
 		switch (tm->op) {
 		case MOD_LOG_KEY_REMOVE_WHILE_FREEING:
 			BUG_ON(tm->slot < n);
-			/* Fallthrough */
+			fallthrough;
 		case MOD_LOG_KEY_REMOVE_WHILE_MOVING:
 		case MOD_LOG_KEY_REMOVE:
 			btrfs_set_node_key(eb, &tm->key, tm->slot);
diff --git a/fs/btrfs/super.c b/fs/btrfs/super.c
index 893fd7145724..a213b3f6a6ea 100644
--- a/fs/btrfs/super.c
+++ b/fs/btrfs/super.c
@@ -637,7 +637,7 @@  int btrfs_parse_options(struct btrfs_fs_info *info, char *options,
 		case Opt_compress_force:
 		case Opt_compress_force_type:
 			compress_force = true;
-			/* Fallthrough */
+			fallthrough;
 		case Opt_compress:
 		case Opt_compress_type:
 			saved_compress_type = btrfs_test_opt(info,
@@ -736,7 +736,7 @@  int btrfs_parse_options(struct btrfs_fs_info *info, char *options,
 			btrfs_set_opt(info->mount_opt, NOSSD);
 			btrfs_clear_and_info(info, SSD,
 					     "not using ssd optimizations");
-			/* Fallthrough */
+			fallthrough;
 		case Opt_nossd_spread:
 			btrfs_clear_and_info(info, SSD_SPREAD,
 					     "not using spread ssd allocation scheme");