IB/srp: Fix a race condition triggered by destroying a queue pair
At least LID reassignment can trigger a race condition in the SRP initiator driver, namely the receive completion handler trying to post a request on a QP during or after QP destruction and before the CQ's have been destroyed. Avoid this race by modifying a QP into the error state and by waiting until all receive completions have been processed before destroying a QP. Reported-by: Max Gurtuvoy <maxg@mellanox.com> Signed-off-by: Bart Van Assche <bvanassche@acm.org> Reviewed-by: Sagi Grimberg <sagig@mellanox.com> Signed-off-by: Christoph Hellwig <hch@lst.de>
Esse commit está contido em:

commit de
Christoph Hellwig

pai
d92c0da71a
commit
7dad6b2e44
@@ -70,6 +70,8 @@ enum {
|
||||
|
||||
LOCAL_INV_WR_ID_MASK = 1,
|
||||
FAST_REG_WR_ID_MASK = 2,
|
||||
|
||||
SRP_LAST_WR_ID = 0xfffffffcU,
|
||||
};
|
||||
|
||||
enum srp_target_state {
|
||||
|
Referência em uma nova issue
Block a user