diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-25 15:05:17 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-25 15:05:17 -0400 |
commit | 8e9815a0f8882aaa68645b001bb7538db8886802 (patch) | |
tree | 5654a4f982ea681158185b21321acd470cb9b87c /drivers/infiniband/hw/cxgb4/cq.c | |
parent | 702c0b04978ce316ec05f4d0a9c148fac124335b (diff) | |
parent | acdc30b56abc0db7d409a13e9b6c72ea23b6f90d (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland/infiniband:
RDMA/nes: Fix incorrect unlock in nes_process_mac_intr()
RDMA/nes: Async event for closed QP causes crash
RDMA/nes: Have ethtool read hardware registers for rx/tx stats
RDMA/cxgb4: Only insert sq qid in lookup table
RDMA/cxgb4: Support IB_WR_READ_WITH_INV opcode
RDMA/cxgb4: Set fence flag for inv-local-stag work requests
RDMA/cxgb4: Update some HW limits
RDMA/cxgb4: Don't limit fastreg page list depth
RDMA/cxgb4: Return proper errors in fastreg mr/pbl allocation
RDMA/cxgb4: Fix overflow bug in CQ arm
RDMA/cxgb4: Optimize CQ overflow detection
RDMA/cxgb4: CQ size must be IQ size - 2
RDMA/cxgb4: Register RDMA provider based on LLD state_change events
RDMA/cxgb4: Detach from the LLD after unregistering RDMA device
IB/ipath: Remove support for QLogic PCIe QLE devices
IB/qib: Add new qib driver for QLogic PCIe InfiniBand adapters
IB/mad: Make needlessly global mad_sendq_size/mad_recvq_size static
IB/core: Allow device-specific per-port sysfs files
mlx4_core: Clean up mlx4_alloc_icm() a bit
mlx4_core: Fix possible chunk sg list overflow in mlx4_alloc_icm()
Diffstat (limited to 'drivers/infiniband/hw/cxgb4/cq.c')
-rw-r--r-- | drivers/infiniband/hw/cxgb4/cq.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/cxgb4/cq.c b/drivers/infiniband/hw/cxgb4/cq.c index fb1aafcc294f..2447f5295482 100644 --- a/drivers/infiniband/hw/cxgb4/cq.c +++ b/drivers/infiniband/hw/cxgb4/cq.c | |||
@@ -373,6 +373,7 @@ static void create_read_req_cqe(struct t4_wq *wq, struct t4_cqe *hw_cqe, | |||
373 | V_CQE_SWCQE(SW_CQE(hw_cqe)) | | 373 | V_CQE_SWCQE(SW_CQE(hw_cqe)) | |
374 | V_CQE_OPCODE(FW_RI_READ_REQ) | | 374 | V_CQE_OPCODE(FW_RI_READ_REQ) | |
375 | V_CQE_TYPE(1)); | 375 | V_CQE_TYPE(1)); |
376 | read_cqe->bits_type_ts = hw_cqe->bits_type_ts; | ||
376 | } | 377 | } |
377 | 378 | ||
378 | /* | 379 | /* |
@@ -780,6 +781,9 @@ struct ib_cq *c4iw_create_cq(struct ib_device *ibdev, int entries, | |||
780 | /* account for the status page. */ | 781 | /* account for the status page. */ |
781 | entries++; | 782 | entries++; |
782 | 783 | ||
784 | /* IQ needs one extra entry to differentiate full vs empty. */ | ||
785 | entries++; | ||
786 | |||
783 | /* | 787 | /* |
784 | * entries must be multiple of 16 for HW. | 788 | * entries must be multiple of 16 for HW. |
785 | */ | 789 | */ |
@@ -801,7 +805,7 @@ struct ib_cq *c4iw_create_cq(struct ib_device *ibdev, int entries, | |||
801 | 805 | ||
802 | chp->rhp = rhp; | 806 | chp->rhp = rhp; |
803 | chp->cq.size--; /* status page */ | 807 | chp->cq.size--; /* status page */ |
804 | chp->ibcq.cqe = chp->cq.size; | 808 | chp->ibcq.cqe = chp->cq.size - 1; |
805 | spin_lock_init(&chp->lock); | 809 | spin_lock_init(&chp->lock); |
806 | atomic_set(&chp->refcnt, 1); | 810 | atomic_set(&chp->refcnt, 1); |
807 | init_waitqueue_head(&chp->wait); | 811 | init_waitqueue_head(&chp->wait); |