[RESEND] btrfs: raid56: Remove out label in __raid56_parity_recover
diff mbox series

Message ID 20200715110217.19698-1-nborisov@suse.com
State New
Headers show
Series
  • [RESEND] btrfs: raid56: Remove out label in __raid56_parity_recover
Related show

Commit Message

Nikolay Borisov July 15, 2020, 11:02 a.m. UTC
There's no cleanup that occurs so we can simply return 0 directly.

Signed-off-by: Nikolay Borisov <nborisov@suse.com>
---
 fs/btrfs/raid56.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--
2.17.1

Comments

David Sterba July 15, 2020, 1:38 p.m. UTC | #1
On Wed, Jul 15, 2020 at 02:02:17PM +0300, Nikolay Borisov wrote:
> There's no cleanup that occurs so we can simply return 0 directly.
> 
> Signed-off-by: Nikolay Borisov <nborisov@suse.com>

Added to misc-next, thanks.

> @@ -2083,7 +2083,7 @@ static int __raid56_parity_recover(struct btrfs_raid_bio *rbio)
>  		 */
>  		if (atomic_read(&rbio->error) <= rbio->bbio->max_errors) {
>  			__raid_recover_end_io(rbio);
> -			goto out;
> +			return 0;

The rest of the function can be seen from that point so readability is
not hurt.

Patch
diff mbox series

diff --git a/fs/btrfs/raid56.c b/fs/btrfs/raid56.c
index 61ff77392357..255490f42b5d 100644
--- a/fs/btrfs/raid56.c
+++ b/fs/btrfs/raid56.c
@@ -2083,7 +2083,7 @@  static int __raid56_parity_recover(struct btrfs_raid_bio *rbio)
 		 */
 		if (atomic_read(&rbio->error) <= rbio->bbio->max_errors) {
 			__raid_recover_end_io(rbio);
-			goto out;
+			return 0;
 		} else {
 			goto cleanup;
 		}
@@ -2103,7 +2103,7 @@  static int __raid56_parity_recover(struct btrfs_raid_bio *rbio)

 		submit_bio(bio);
 	}
-out:
+
 	return 0;

 cleanup: