]> www.infradead.org Git - users/jedix/linux-maple.git/commit
sif: sqflush: Handle duplicate completions in poll_cq
authorWei Lin Guay <wei.lin.guay@oracle.com>
Thu, 4 Aug 2016 09:02:44 +0000 (11:02 +0200)
committerKnut Omang <knut.omang@oracle.com>
Fri, 9 Sep 2016 10:31:59 +0000 (12:31 +0200)
commit9db36855abfdbd7bdc05e1e2aaa66f3ed32cda8a
treede806e8f8c6f6f4f25d38279f00b4a7526c0a319
parent2fcb703df519414bf5241d48eca0f36d335eef9d
sif: sqflush: Handle duplicate completions in poll_cq

Orabug: 23759723

During the QP transition from RTS-> ERR, the HW might generate
duplicate FLUSHED-IN-ERR completion. The SIF driver inverses the
sq_seq in a dedicated completion entry and sets the
CQ_POLLING_IGNORED_SEQ bit in the cq_sw flags. Nevertheless, this bit
is cleared once a duplicate FLUSHED-IN-ERR completion is detected in
poll_cq.

The above mentioned method cannot handle a scenario where HW generates
multiple duplicate completions. Thus, this patch moves the detection
of the duplicate completions to translate_wr_id. Then, SIF driver
will only return non duplicate completions to the user.

Signed-off-by: Wei Lin Guay <wei.lin.guay@oracle.com>
Reviewed-by: Knut Omang <knut.omang@oracle.com>
drivers/infiniband/hw/sif/sif_cq.c
drivers/infiniband/hw/sif/sif_defs.c
drivers/infiniband/hw/sif/sif_defs.h
drivers/infiniband/hw/sif/sif_int_user.h
drivers/infiniband/hw/sif/sif_qp.c
drivers/infiniband/hw/sif/sif_r3.c
drivers/infiniband/hw/sif/sif_user.h