Skip to content

Commit

Permalink
Btrfs: fix comparison in __btrfs_map_block()
Browse files Browse the repository at this point in the history
Add missing comparison to op in expression, which was forgotten when doing
the REQ_OP transition.

Fixes: b3d3fa5 ("btrfs: update __btrfs_map_block for REQ_OP transition")
Signed-off-by: Vincent Stehlé <[email protected]>
Reviewed-by: Mike Christie <[email protected]>
Signed-off-by: Jens Axboe <[email protected]>
  • Loading branch information
Vincent Stehlé authored and axboe committed Jul 18, 2016
1 parent 9c87471 commit df5c82a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fs/btrfs/volumes.c
Original file line number Diff line number Diff line change
Expand Up @@ -5494,7 +5494,7 @@ static int __btrfs_map_block(struct btrfs_fs_info *fs_info, int op,
}

} else if (map->type & BTRFS_BLOCK_GROUP_DUP) {
if (op == REQ_OP_WRITE || REQ_OP_DISCARD ||
if (op == REQ_OP_WRITE || op == REQ_OP_DISCARD ||
op == REQ_GET_READ_MIRRORS) {
num_stripes = map->num_stripes;
} else if (mirror_num) {
Expand Down

0 comments on commit df5c82a

Please sign in to comment.