md: changed the switch of RAID_VERSION to if
There is only one case of this 'switch'. Change it to 'if'. Signed-off-by: Li Nan <linan122@huawei.com> Signed-off-by: Song Liu <song@kernel.org> Link: https://lore.kernel.org/r/20240226031444.3606764-3-linan666@huaweicloud.com
This commit is contained in:
parent
2fe4ffc3ec
commit
4e26593944
@ -7613,12 +7613,8 @@ static int md_ioctl(struct block_device *bdev, blk_mode_t mode,
|
||||
* Commands dealing with the RAID driver but not any
|
||||
* particular array:
|
||||
*/
|
||||
switch (cmd) {
|
||||
case RAID_VERSION:
|
||||
err = get_version(argp);
|
||||
goto out;
|
||||
default:;
|
||||
}
|
||||
if (cmd == RAID_VERSION)
|
||||
return get_version(argp);
|
||||
|
||||
/*
|
||||
* Commands creating/starting a new array:
|
||||
|
Loading…
x
Reference in New Issue
Block a user