Commit 4e265939 authored by Li Nan's avatar Li Nan Committed by Song Liu
Browse files

md: changed the switch of RAID_VERSION to if



There is only one case of this 'switch'. Change it to 'if'.

Signed-off-by: default avatarLi Nan <linan122@huawei.com>
Signed-off-by: default avatarSong Liu <song@kernel.org>
Link: https://lore.kernel.org/r/20240226031444.3606764-3-linan666@huaweicloud.com
parent 2fe4ffc3
Loading
Loading
Loading
Loading
+2 −6
Original line number Diff line number Diff line
@@ -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: