Skip to content

Commit

Permalink
Fix new incorrect error return from do_md_stop.
Browse files Browse the repository at this point in the history
Recent commit c8c00a6
changed the exit paths in do_md_stop and was not quite
careful enough.  There is one path were 'err' now needs
to be cleared but it isn't.
So setting an array to readonly (with mdadm --readonly) will
work, but will incorrectly report and error: ENXIO.

Signed-off-by: NeilBrown <[email protected]>
  • Loading branch information
neilbrown committed Aug 18, 2009
1 parent 4d484a4 commit 80ffb3c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/md/md.c
Original file line number Diff line number Diff line change
Expand Up @@ -4364,6 +4364,7 @@ static int do_md_stop(mddev_t * mddev, int mode, int is_open)
if (mode == 1)
set_disk_ro(disk, 1);
clear_bit(MD_RECOVERY_FROZEN, &mddev->recovery);
err = 0;
}
out:
mutex_unlock(&mddev->open_mutex);
Expand Down

0 comments on commit 80ffb3c

Please sign in to comment.