File tree Expand file tree Collapse file tree 1 file changed +3
-11
lines changed Expand file tree Collapse file tree 1 file changed +3
-11
lines changed Original file line number Diff line number Diff line change @@ -3203,7 +3203,6 @@ static int raid1_set_limits(struct mddev *mddev)
3203
3203
return queue_limits_set (mddev -> gendisk -> queue , & lim );
3204
3204
}
3205
3205
3206
- static void raid1_free (struct mddev * mddev , void * priv );
3207
3206
static int raid1_run (struct mddev * mddev )
3208
3207
{
3209
3208
struct r1conf * conf ;
@@ -3237,7 +3236,7 @@ static int raid1_run(struct mddev *mddev)
3237
3236
if (!mddev_is_dm (mddev )) {
3238
3237
ret = raid1_set_limits (mddev );
3239
3238
if (ret )
3240
- goto abort ;
3239
+ return ret ;
3241
3240
}
3242
3241
3243
3242
mddev -> degraded = 0 ;
@@ -3251,8 +3250,7 @@ static int raid1_run(struct mddev *mddev)
3251
3250
*/
3252
3251
if (conf -> raid_disks - mddev -> degraded < 1 ) {
3253
3252
md_unregister_thread (mddev , & conf -> thread );
3254
- ret = - EINVAL ;
3255
- goto abort ;
3253
+ return - EINVAL ;
3256
3254
}
3257
3255
3258
3256
if (conf -> raid_disks - mddev -> degraded == 1 )
@@ -3276,14 +3274,8 @@ static int raid1_run(struct mddev *mddev)
3276
3274
md_set_array_sectors (mddev , raid1_size (mddev , 0 , 0 ));
3277
3275
3278
3276
ret = md_integrity_register (mddev );
3279
- if (ret ) {
3277
+ if (ret )
3280
3278
md_unregister_thread (mddev , & mddev -> thread );
3281
- goto abort ;
3282
- }
3283
- return 0 ;
3284
-
3285
- abort :
3286
- raid1_free (mddev , conf );
3287
3279
return ret ;
3288
3280
}
3289
3281
You can’t perform that action at this time.
0 commit comments