Skip to content

Commit

Permalink
btrfs: raid56: don't opencode swap() in __raid_recover_end_io
Browse files Browse the repository at this point in the history
Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
  • Loading branch information
Nikolay Borisov authored and David Sterba committed Jul 27, 2020
1 parent 8302586 commit b7d2083
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions fs/btrfs/raid56.c
Original file line number Diff line number Diff line change
Expand Up @@ -1862,11 +1862,8 @@ static void __raid_recover_end_io(struct btrfs_raid_bio *rbio)
}

/* make sure our ps and qs are in order */
if (faila > failb) {
int tmp = failb;
failb = faila;
faila = tmp;
}
if (faila > failb)
swap(faila, failb);

/* if the q stripe is failed, do a pstripe reconstruction
* from the xors.
Expand Down

0 comments on commit b7d2083

Please sign in to comment.