mirror of
https://github.com/koverstreet/bcachefs-tools.git
synced 2025-02-23 00:00:02 +03:00
libbcachefs: convert sb features mask to little endian
bch_sb.features is an array of __le64. Convert the native endian format of the features mask appropriately. This causes a bcachefs format to produce an unmountable fs when run from a big endian system. Signed-off-by: Brian Foster <bfoster@redhat.com> Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
This commit is contained in:
parent
9fe08ba354
commit
f68e0ed16e
@ -193,7 +193,7 @@ struct bch_sb *bch2_format(struct bch_opt_strs fs_opt_strs,
|
||||
sb.sb->nr_devices = nr_devs;
|
||||
|
||||
if (opts.version == bcachefs_metadata_version_current)
|
||||
sb.sb->features[0] |= BCH_SB_FEATURES_ALL;
|
||||
sb.sb->features[0] |= cpu_to_le64(BCH_SB_FEATURES_ALL);
|
||||
|
||||
uuid_generate(sb.sb->uuid.b);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user