diff options
author | Joachim Fenkes <fenkes@de.ibm.com> | 2008-01-24 11:59:08 -0500 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2008-02-04 23:20:42 -0500 |
commit | 2b7274c39228d7a8c81a411dc3969763e9069c56 (patch) | |
tree | 596f69786ab9957a69a1d1e5da82d2fc900602c1 /drivers/infiniband | |
parent | 3971c9f6dbf26f077b929dbe14ced60a697ebcf0 (diff) |
IB/ehca: Prevent sending UD packets to QP0
The IB spec doesn't allow packets to QP0 sent on any other VL than VL15.
Hardware doesn't filter those packets on the send side, so we need to do
this in the driver and firmware.
As eHCA doesn't support QP0, we can just filter out all traffic going to
QP0, regardless of SL or VL.
Signed-off-by: Joachim Fenkes <fenkes@de.ibm.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers/infiniband')
-rw-r--r-- | drivers/infiniband/hw/ehca/ehca_reqs.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/infiniband/hw/ehca/ehca_reqs.c b/drivers/infiniband/hw/ehca/ehca_reqs.c index 3aacc8cf1e44..2ce8cffb8664 100644 --- a/drivers/infiniband/hw/ehca/ehca_reqs.c +++ b/drivers/infiniband/hw/ehca/ehca_reqs.c | |||
@@ -209,6 +209,10 @@ static inline int ehca_write_swqe(struct ehca_qp *qp, | |||
209 | ehca_gen_err("wr.ud.ah is NULL. qp=%p", qp); | 209 | ehca_gen_err("wr.ud.ah is NULL. qp=%p", qp); |
210 | return -EINVAL; | 210 | return -EINVAL; |
211 | } | 211 | } |
212 | if (unlikely(send_wr->wr.ud.remote_qpn == 0)) { | ||
213 | ehca_gen_err("dest QP# is 0. qp=%x", qp->real_qp_num); | ||
214 | return -EINVAL; | ||
215 | } | ||
212 | my_av = container_of(send_wr->wr.ud.ah, struct ehca_av, ib_ah); | 216 | my_av = container_of(send_wr->wr.ud.ah, struct ehca_av, ib_ah); |
213 | wqe_p->u.ud_av.ud_av = my_av->av; | 217 | wqe_p->u.ud_av.ud_av = my_av->av; |
214 | 218 | ||