Commit 25541f00 authored by Christoph Hellwig's avatar Christoph Hellwig Committed by Yongqiang Liu
Browse files

nbd: validate the block size in nbd_set_size

mainline inclusion
from mainline-v5.1-rc1
commit dcbddf54
category: bugfix
bugzilla: 188268, https://gitee.com/openeuler/kernel/issues/I6DC67


CVE: NA

----------------------------------------

Move the validation of the block from the callers into nbd_set_size.

Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
Reviewed-by: default avatarJosef Bacik <josef@toxicpanda.com>
Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>

conflict:
	drivers/block/nbd.c

Signed-off-by: default avatarZhong Jinghua <zhongjinghua@huawei.com>
Reviewed-by: default avatarYu Kuai <yukuai3@huawei.com>
Reviewed-by: default avatarHou Tao <houtao1@huawei.com>
Signed-off-by: default avatarYongqiang Liu <liuyongqiang13@huawei.com>
parent b99f764b
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment