summaryrefslogtreecommitdiffstats
path: root/fs/bcachefs/super-io.c
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@linux.dev>2022-10-19 18:31:33 -0400
committerKent Overstreet <kent.overstreet@linux.dev>2023-10-22 17:09:44 -0400
commit3e3e02e6bce627ed9e3a5d9fd3118e6569dc2548 (patch)
tree33fc60a2903692a2038dd4b87dfa6b87a207b7e1 /fs/bcachefs/super-io.c
parented80c5699a23c4005ba8e81d4b8fb3e1b922fa40 (diff)
downloadlinux-3e3e02e6bce627ed9e3a5d9fd3118e6569dc2548.tar.gz
linux-3e3e02e6bce627ed9e3a5d9fd3118e6569dc2548.tar.bz2
linux-3e3e02e6bce627ed9e3a5d9fd3118e6569dc2548.zip
bcachefs: Assorted checkpatch fixes
checkpatch.pl gives lots of warnings that we don't want - suggested ignore list: ASSIGN_IN_IF UNSPECIFIED_INT - bcachefs coding style prefers single token type names NEW_TYPEDEFS - typedefs are occasionally good FUNCTION_ARGUMENTS - we prefer to look at functions in .c files (hopefully with docbook documentation), not .h file prototypes MULTISTATEMENT_MACRO_USE_DO_WHILE - we have _many_ x-macros and other macros where we can't do this Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/super-io.c')
-rw-r--r--fs/bcachefs/super-io.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/fs/bcachefs/super-io.c b/fs/bcachefs/super-io.c
index 2a347efdbd83..42e3ce7c0f8c 100644
--- a/fs/bcachefs/super-io.c
+++ b/fs/bcachefs/super-io.c
@@ -101,8 +101,7 @@ void bch2_sb_field_delete(struct bch_sb_handle *sb,
void bch2_free_super(struct bch_sb_handle *sb)
{
- if (sb->bio)
- kfree(sb->bio);
+ kfree(sb->bio);
if (!IS_ERR_OR_NULL(sb->bdev))
blkdev_put(sb->bdev, sb->holder);
kfree(sb->holder);
@@ -151,8 +150,7 @@ int bch2_sb_realloc(struct bch_sb_handle *sb, unsigned u64s)
bio_init(bio, NULL, bio->bi_inline_vecs, nr_bvecs, 0);
- if (sb->bio)
- kfree(sb->bio);
+ kfree(sb->bio);
sb->bio = bio;
}