From 9ea2e26aaa56129456f27c7f250ee7e4b67aa88c Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Tue, 25 Oct 2011 18:05:57 +0000 Subject: [PATCH] ib_srpt: Avoid stopping polling too early for IB completions. This resulted in unnecessary complaints about IB completions not being received in time when removing the ib_srpt kernel module during I/O. Note: it is still possible that such complaints occur, but much less frequent. git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@3899 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- srpt/src/ib_srpt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/srpt/src/ib_srpt.c b/srpt/src/ib_srpt.c index 3773b96d1..aa41693a2 100644 --- a/srpt/src/ib_srpt.c +++ b/srpt/src/ib_srpt.c @@ -1966,7 +1966,7 @@ static bool srpt_process_completion(struct ib_cq *cq, EXTRACHECKS_WARN_ON(cq != ch->cq); - keep_going = ch->state <= CH_LIVE; + keep_going = !ch->last_wqe_received; if (keep_going) ib_req_notify_cq(cq, IB_CQ_NEXT_COMP); while ((n = ib_poll_cq(cq, ARRAY_SIZE(ch->wc), wc)) > 0) {