Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

RDMA/hns: Add missing comp_mask check in create_qp

hns has a comp_mask field that was never checked for validity, check
it.

Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>

authored by

Jason Gunthorpe and committed by
Leon Romanovsky
67820de3 676b5707

+3 -1
+3 -1
drivers/infiniband/hw/hns/hns_roce_qp.c
··· 1130 1130 } 1131 1131 1132 1132 if (udata) { 1133 - ret = ib_copy_validate_udata_in(udata, *ucmd, reserved); 1133 + ret = ib_copy_validate_udata_in_cm( 1134 + udata, *ucmd, reserved, 1135 + HNS_ROCE_CREATE_QP_MASK_CONGEST_TYPE); 1134 1136 if (ret) 1135 1137 return ret; 1136 1138