diff options
author | Sagi Grimberg <sagig@mellanox.com> | 2014-10-01 15:02:09 +0400 |
---|---|---|
committer | Roland Dreier <roland@purestorage.com> | 2014-10-09 11:06:07 +0400 |
commit | 6aabfa76f5e5281e5db128a34420d8f33b8574f7 (patch) | |
tree | d2d2276fa85be0bb6921d1f27125250eea47e379 /drivers/infiniband/ulp/iser/iscsi_iser.h | |
parent | 183cfa434ec90897b1423ce4f916e8a237139133 (diff) | |
download | linux-6aabfa76f5e5281e5db128a34420d8f33b8574f7.tar.xz |
IB/iser: Use single CQ for RX and TX
This will solve a possible condition where we might miss TX completion
(flush error) during session teardown. Since we are using a single
CQ, we don't need to actively drain the TX CQ, instead just wait for
flush_completion (when counters reach zero) and remove iser_poll_for_flush_errors().
This patch might introduce a minor performance regression on its own,
but the next patches will enhance performance using a single CQ for RX
and TX.
Signed-off-by: Sagi Grimberg <sagig@mellanox.com>
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
Diffstat (limited to 'drivers/infiniband/ulp/iser/iscsi_iser.h')
-rw-r--r-- | drivers/infiniband/ulp/iser/iscsi_iser.h | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/infiniband/ulp/iser/iscsi_iser.h b/drivers/infiniband/ulp/iser/iscsi_iser.h index 2bc34aa50705..1617c5cce8b1 100644 --- a/drivers/infiniband/ulp/iser/iscsi_iser.h +++ b/drivers/infiniband/ulp/iser/iscsi_iser.h @@ -271,16 +271,14 @@ struct iscsi_iser_task; * struct iser_comp - iSER completion context * * @device: pointer to device handle - * @rx_cq: RX completion queue - * @tx_cq: TX completion queue + * @cq: completion queue * @tasklet: Tasklet handle * @active_qps: Number of active QPs attached * to completion context */ struct iser_comp { struct iser_device *device; - struct ib_cq *rx_cq; - struct ib_cq *tx_cq; + struct ib_cq *cq; struct tasklet_struct tasklet; int active_qps; }; @@ -342,6 +340,7 @@ struct fast_reg_descriptor { * @device: reference to iser device * @comp: iser completion context * @pi_support: Indicate device T10-PI support + * @flush_comp: completes when all connection completions consumed * @lock: protects fmr/fastreg pool * @union.fmr: * @pool: FMR pool for fast registrations @@ -361,6 +360,7 @@ struct ib_conn { struct iser_device *device; struct iser_comp *comp; bool pi_support; + struct completion flush_comp; spinlock_t lock; union { struct { @@ -395,6 +395,7 @@ struct iser_conn { u64 login_req_dma, login_resp_dma; unsigned int rx_desc_head; struct iser_rx_desc *rx_descs; + u32 num_rx_descs; }; struct iscsi_iser_task { |