Skip to contentSkip to conversation

bcachefs: Remove the unused variable block_size

PATCH New Jiapeng Chong 1 participant 1 message Feb 24, 2025

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 bcachefs: Remove the unused variable block_size

Variable block_size is not effectively used, so delete it.

fs/bcachefs/super-io.c:369:6: warning: variable ‘block_size’ set but not used.

---
 fs/bcachefs/super-io.c | 3 ---
 1 file changed, 3 deletions(-)
fs/bcachefs/super-io.c +0 -3
index 0edc8814eb7e..ab99a2fb9356 100644
@@ -366,7 +366,6 @@ static int bch2_sb_validate(struct bch_sb_handle *disk_sb,
 	struct bch_sb *sb = disk_sb->sb;
 	struct bch_sb_field_members_v1 *mi;
 	enum bch_opt_id opt_id;
-	u16 block_size;
 	int ret;
 
 	ret = bch2_sb_compatible(sb, out);
@@ -385,8 +384,6 @@ static int bch2_sb_validate(struct bch_sb_handle *disk_sb,
 		return -BCH_ERR_invalid_sb_features;
 	}
 
-	block_size = le16_to_cpu(sb->block_size);
-
 	if (bch2_is_zero(sb->user_uuid.b, sizeof(sb->user_uuid))) {
 		prt_printf(out, "Bad user UUID (got zeroes)");
 		return -BCH_ERR_invalid_sb_uuid;
Signature · 1 line
2.32.0.3.g01195cf9f