On Fri, Mar 24, 2017 at 10:00:24AM +0800, Qu Wenruo wrote:
> --- a/fs/btrfs/scrub.c
> +++ b/fs/btrfs/scrub.c
> @@ -1065,6 +1065,7 @@ static int scrub_handle_errored_block(struct 
> scrub_block *sblock_to_check)
>       unsigned int have_csum;
>       struct scrub_block *sblocks_for_recheck; /* holds one for each mirror */
>       struct scrub_block *sblock_bad;
> +     int lock_ret;

No need to introduce another variable, just use 'ret'.

>       int ret;
>       int mirror_index;
>       int page_num;
> @@ -1428,6 +1440,9 @@ static int scrub_handle_errored_block(struct 
> scrub_block *sblock_to_check)
>               kfree(sblocks_for_recheck);
>       }
>  
> +     lock_ret = unlock_full_stripe(fs_info, logical);
> +     if (lock_ret < 0)
> +             return lock_ret;
>       return 0;

Here.
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to