Fix kernel panic while using XRC_TGT QP type in ibcore.

Attempt to modify XRC_TGT QP type from the user space (ibv_xsrq_pingpong
invocation) will trigger the following kernel panic. It is caused by the
fact that such QPs missed uobject initialization.

Linux commit:
f45765872e7aae7b81feb3044aaf9886b21885ef

MFC after:		1 week
Sponsored by:		Mellanox Technologies
This commit is contained in:
Hans Petter Selasky 2018-07-17 09:18:16 +00:00
parent 765bd83cca
commit 083cdbac35
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=336377

View File

@ -1943,6 +1943,9 @@ static int create_qp(struct ib_uverbs_file *file,
atomic_inc(&attr.srq->usecnt);
if (ind_tbl)
atomic_inc(&ind_tbl->usecnt);
} else {
/* It is done in _ib_create_qp for other QP types */
qp->uobject = &obj->uevent.uobject;
}
qp->uobject = &obj->uevent.uobject;