mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-07-23 07:12:09 +00:00
Btrfs: make profile_is_valid() check more strict
"0" is a valid value for an on-disk chunk profile, but it is not a valid extended profile. (We have a separate bit for single chunks in extended case) Also rename it to alloc_profile_is_valid() for clarity. Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
This commit is contained in:
parent
899c81eac8
commit
e8920a640b
3 changed files with 17 additions and 12 deletions
|
@ -3400,7 +3400,7 @@ static int do_chunk_alloc(struct btrfs_trans_handle *trans,
|
|||
int wait_for_alloc = 0;
|
||||
int ret = 0;
|
||||
|
||||
BUG_ON(!profile_is_valid(flags, 0));
|
||||
BUG_ON(!alloc_profile_is_valid(flags, 0));
|
||||
|
||||
space_info = __find_space_info(extent_root->fs_info, flags);
|
||||
if (!space_info) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue