diff options
author | Ralph Campbell <ralph.campbell@qlogic.com> | 2007-06-18 17:24:38 -0400 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2007-07-09 23:12:26 -0400 |
commit | 1dd6a1be1416be48cafda9e63a614f26f0428d10 (patch) | |
tree | a20e33515a80c2da5153d66754cb194503b9974d | |
parent | 6d2fad0472ca0d6caba7c36d2823a527e2a0e4f5 (diff) |
IB/ipath: Set M bit in BTH according to IB spec
According to chapter 17.2.8.1.1, QPs start in the migrated state and
should send packets with the M bit set in the BTH.
Signed-off-by: Ralph Campbell <ralph.campbell@qlogic.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
-rw-r--r-- | drivers/infiniband/hw/ipath/ipath_rc.c | 6 | ||||
-rw-r--r-- | drivers/infiniband/hw/ipath/ipath_uc.c | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/drivers/infiniband/hw/ipath/ipath_rc.c b/drivers/infiniband/hw/ipath/ipath_rc.c index 1915771fd038..9ba80d107dcd 100644 --- a/drivers/infiniband/hw/ipath/ipath_rc.c +++ b/drivers/infiniband/hw/ipath/ipath_rc.c | |||
@@ -188,7 +188,7 @@ static int ipath_make_rc_ack(struct ipath_qp *qp, | |||
188 | } | 188 | } |
189 | qp->s_hdrwords = hwords; | 189 | qp->s_hdrwords = hwords; |
190 | qp->s_cur_size = len; | 190 | qp->s_cur_size = len; |
191 | *bth0p = bth0; | 191 | *bth0p = bth0 | (1 << 22); /* Set M bit */ |
192 | *bth2p = bth2; | 192 | *bth2p = bth2; |
193 | return 1; | 193 | return 1; |
194 | 194 | ||
@@ -240,7 +240,7 @@ int ipath_make_rc_req(struct ipath_qp *qp, | |||
240 | 240 | ||
241 | /* header size in 32-bit words LRH+BTH = (8+12)/4. */ | 241 | /* header size in 32-bit words LRH+BTH = (8+12)/4. */ |
242 | hwords = 5; | 242 | hwords = 5; |
243 | bth0 = 0; | 243 | bth0 = 1 << 22; /* Set M bit */ |
244 | 244 | ||
245 | /* Send a request. */ | 245 | /* Send a request. */ |
246 | wqe = get_swqe_ptr(qp, qp->s_cur); | 246 | wqe = get_swqe_ptr(qp, qp->s_cur); |
@@ -604,7 +604,7 @@ static void send_rc_ack(struct ipath_qp *qp) | |||
604 | } | 604 | } |
605 | /* read pkey_index w/o lock (its atomic) */ | 605 | /* read pkey_index w/o lock (its atomic) */ |
606 | bth0 = ipath_get_pkey(dev->dd, qp->s_pkey_index) | | 606 | bth0 = ipath_get_pkey(dev->dd, qp->s_pkey_index) | |
607 | OP(ACKNOWLEDGE) << 24; | 607 | (OP(ACKNOWLEDGE) << 24) | (1 << 22); |
608 | if (qp->r_nak_state) | 608 | if (qp->r_nak_state) |
609 | ohdr->u.aeth = cpu_to_be32((qp->r_msn & IPATH_MSN_MASK) | | 609 | ohdr->u.aeth = cpu_to_be32((qp->r_msn & IPATH_MSN_MASK) | |
610 | (qp->r_nak_state << | 610 | (qp->r_nak_state << |
diff --git a/drivers/infiniband/hw/ipath/ipath_uc.c b/drivers/infiniband/hw/ipath/ipath_uc.c index 49d650cabccf..243d7c61e18d 100644 --- a/drivers/infiniband/hw/ipath/ipath_uc.c +++ b/drivers/infiniband/hw/ipath/ipath_uc.c | |||
@@ -86,7 +86,7 @@ int ipath_make_uc_req(struct ipath_qp *qp, | |||
86 | 86 | ||
87 | /* header size in 32-bit words LRH+BTH = (8+12)/4. */ | 87 | /* header size in 32-bit words LRH+BTH = (8+12)/4. */ |
88 | hwords = 5; | 88 | hwords = 5; |
89 | bth0 = 0; | 89 | bth0 = 1 << 22; /* Set M bit */ |
90 | 90 | ||
91 | /* Get the next send request. */ | 91 | /* Get the next send request. */ |
92 | wqe = get_swqe_ptr(qp, qp->s_last); | 92 | wqe = get_swqe_ptr(qp, qp->s_last); |