Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7ce64ccc authored by Li Nan's avatar Li Nan Committed by Vegard Nossum
Browse files

md: clean up invalid BUG_ON in md_ioctl



[ Upstream commit 9dd8702e7cd28ebf076ff838933f29cf671165ec ]

'disk->private_data' is set to mddev in md_alloc() and never set to NULL,
and users need to open mddev before submitting ioctl. So mddev must not
have been freed during ioctl, and there is no need to check mddev here.
Clean up it.

Signed-off-by: default avatarLi Nan <linan122@huawei.com>
Reviewed-by: default avatarYu Kuai <yukuai3@huawei.com>
Signed-off-by: default avatarSong Liu <song@kernel.org>
Link: https://lore.kernel.org/r/20240226031444.3606764-4-linan666@huaweicloud.com


Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
(cherry picked from commit 5c11581df1f58c43ce8b2e9c14184ab1f75c883f)
Signed-off-by: default avatarVegard Nossum <vegard.nossum@oracle.com>
parent 8ab663cd
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment