diff options
Diffstat (limited to 'drivers/infiniband')
-rw-r--r-- | drivers/infiniband/hw/ipath/ipath_ud.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/ipath/ipath_ud.c b/drivers/infiniband/hw/ipath/ipath_ud.c index 57625b8c1b97..a518f7c8fa83 100644 --- a/drivers/infiniband/hw/ipath/ipath_ud.c +++ b/drivers/infiniband/hw/ipath/ipath_ud.c | |||
@@ -308,6 +308,11 @@ int ipath_post_ud_send(struct ipath_qp *qp, struct ib_send_wr *wr) | |||
308 | goto bail; | 308 | goto bail; |
309 | } | 309 | } |
310 | 310 | ||
311 | if (wr->wr.ud.ah->pd != qp->ibqp.pd) { | ||
312 | ret = -EPERM; | ||
313 | goto bail; | ||
314 | } | ||
315 | |||
311 | /* IB spec says that num_sge == 0 is OK. */ | 316 | /* IB spec says that num_sge == 0 is OK. */ |
312 | if (wr->num_sge > qp->s_max_sge) { | 317 | if (wr->num_sge > qp->s_max_sge) { |
313 | ret = -EINVAL; | 318 | ret = -EINVAL; |