• Steve Wise's avatar
    iw_cxgb4: atomically flush the qp · bc52e9ca
    Steve Wise authored
    __flush_qp() has a race condition where during the flush operation,
    the qp lock is released allowing another thread to possibly post a WR,
    which corrupts the queue state, possibly causing crashes.  The lock was
    released to preserve the cq/qp locking hierarchy of cq first, then qp.
    However releasing the qp lock is not necessary; both RQ and SQ CQ locks
    can be acquired first, followed by the qp lock, and then the RQ and SQ
    flushing can be done w/o unlocking.
    Signed-off-by: default avatarSteve Wise <swise@opengridcomputing.com>
    Signed-off-by: default avatarDoug Ledford <dledford@redhat.com>
    bc52e9ca
qp.c 54.7 KB