diff options
author | Steve Wise <swise@opengridcomputing.com> | 2008-01-24 17:30:16 -0500 |
---|---|---|
committer | Roland Dreier <rolandd@cisco.com> | 2008-01-25 17:17:47 -0500 |
commit | 8176d297c73a06e6076c9c31f6404047567f6324 (patch) | |
tree | d3ea63287941d458f853dc06e1e28115025cab19 /drivers/infiniband/hw/cxgb3 | |
parent | f7fca1e8a8eeb6660396327b48995e3d9a7b6dc2 (diff) |
RDMA/cxgb3: Fix the T3A workaround checks
Correctly work around T3A issues by checking "hwtype != T3A" instead of
"hwtype == T3B". This will be needed for new hardware types.
Signed-off-by: Steve Wise <swise@opengridcomputing.com>
Signed-off-by: Roland Dreier <rolandd@cisco.com>
Diffstat (limited to 'drivers/infiniband/hw/cxgb3')
-rw-r--r-- | drivers/infiniband/hw/cxgb3/cxio_hal.c | 2 | ||||
-rw-r--r-- | drivers/infiniband/hw/cxgb3/iwch_cm.c | 4 | ||||
-rw-r--r-- | drivers/infiniband/hw/cxgb3/iwch_provider.c | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/drivers/infiniband/hw/cxgb3/cxio_hal.c b/drivers/infiniband/hw/cxgb3/cxio_hal.c index 26b8c0e1cfd7..03c5ff62889a 100644 --- a/drivers/infiniband/hw/cxgb3/cxio_hal.c +++ b/drivers/infiniband/hw/cxgb3/cxio_hal.c | |||
@@ -179,7 +179,7 @@ int cxio_create_cq(struct cxio_rdev *rdev_p, struct t3_cq *cq) | |||
179 | setup.size = 1UL << cq->size_log2; | 179 | setup.size = 1UL << cq->size_log2; |
180 | setup.credits = 65535; | 180 | setup.credits = 65535; |
181 | setup.credit_thres = 1; | 181 | setup.credit_thres = 1; |
182 | if (rdev_p->t3cdev_p->type == T3B) | 182 | if (rdev_p->t3cdev_p->type != T3A) |
183 | setup.ovfl_mode = 0; | 183 | setup.ovfl_mode = 0; |
184 | else | 184 | else |
185 | setup.ovfl_mode = 1; | 185 | setup.ovfl_mode = 1; |
diff --git a/drivers/infiniband/hw/cxgb3/iwch_cm.c b/drivers/infiniband/hw/cxgb3/iwch_cm.c index 20ba372dd182..f8cb0fe748c3 100644 --- a/drivers/infiniband/hw/cxgb3/iwch_cm.c +++ b/drivers/infiniband/hw/cxgb3/iwch_cm.c | |||
@@ -1118,7 +1118,7 @@ static int act_open_rpl(struct t3cdev *tdev, struct sk_buff *skb, void *ctx) | |||
1118 | status2errno(rpl->status)); | 1118 | status2errno(rpl->status)); |
1119 | connect_reply_upcall(ep, status2errno(rpl->status)); | 1119 | connect_reply_upcall(ep, status2errno(rpl->status)); |
1120 | state_set(&ep->com, DEAD); | 1120 | state_set(&ep->com, DEAD); |
1121 | if (ep->com.tdev->type == T3B && act_open_has_tid(rpl->status)) | 1121 | if (ep->com.tdev->type != T3A && act_open_has_tid(rpl->status)) |
1122 | release_tid(ep->com.tdev, GET_TID(rpl), NULL); | 1122 | release_tid(ep->com.tdev, GET_TID(rpl), NULL); |
1123 | cxgb3_free_atid(ep->com.tdev, ep->atid); | 1123 | cxgb3_free_atid(ep->com.tdev, ep->atid); |
1124 | dst_release(ep->dst); | 1124 | dst_release(ep->dst); |
@@ -1249,7 +1249,7 @@ static void reject_cr(struct t3cdev *tdev, u32 hwtid, __be32 peer_ip, | |||
1249 | skb_trim(skb, sizeof(struct cpl_tid_release)); | 1249 | skb_trim(skb, sizeof(struct cpl_tid_release)); |
1250 | skb_get(skb); | 1250 | skb_get(skb); |
1251 | 1251 | ||
1252 | if (tdev->type == T3B) | 1252 | if (tdev->type != T3A) |
1253 | release_tid(tdev, hwtid, skb); | 1253 | release_tid(tdev, hwtid, skb); |
1254 | else { | 1254 | else { |
1255 | struct cpl_pass_accept_rpl *rpl; | 1255 | struct cpl_pass_accept_rpl *rpl; |
diff --git a/drivers/infiniband/hw/cxgb3/iwch_provider.c b/drivers/infiniband/hw/cxgb3/iwch_provider.c index 69b1204e05f0..df1838f8f94d 100644 --- a/drivers/infiniband/hw/cxgb3/iwch_provider.c +++ b/drivers/infiniband/hw/cxgb3/iwch_provider.c | |||
@@ -646,7 +646,7 @@ static struct ib_mr *iwch_reg_user_mr(struct ib_pd *pd, u64 start, u64 length, | |||
646 | if (err) | 646 | if (err) |
647 | goto err; | 647 | goto err; |
648 | 648 | ||
649 | if (udata && t3b_device(rhp)) { | 649 | if (udata && !t3a_device(rhp)) { |
650 | uresp.pbl_addr = (mhp->attr.pbl_addr - | 650 | uresp.pbl_addr = (mhp->attr.pbl_addr - |
651 | rhp->rdev.rnic_info.pbl_base) >> 3; | 651 | rhp->rdev.rnic_info.pbl_base) >> 3; |
652 | PDBG("%s user resp pbl_addr 0x%x\n", __FUNCTION__, | 652 | PDBG("%s user resp pbl_addr 0x%x\n", __FUNCTION__, |