OSDN Git Service

IB/hfi1: Unreserve a reserved request when it is completed
authorKaike Wan <kaike.wan@intel.com>
Wed, 28 Nov 2018 18:22:09 +0000 (10:22 -0800)
committerJason Gunthorpe <jgg@mellanox.com>
Fri, 7 Dec 2018 02:59:46 +0000 (19:59 -0700)
commitca95f802ef5139722acc8d30aeaab6fe5bbe939e
treeb144e55cc6723cb8bda5a5c71a87c84657e20427
parentff8b67fccdb65402df78a1695c38be805252cf8e
IB/hfi1: Unreserve a reserved request when it is completed

Currently, When a reserved operation is completed, its entry in the send
queue will not be unreserved, which leads to the miscalculation of
qp->s_avail and thus the triggering of a WARN_ON call trace. This patch
fixes the problem by unreserving the reserved operation when it is
completed.

Fixes: 856cc4c237ad ("IB/hfi1: Add the capability for reserved operations")
Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com>
Signed-off-by: Kaike Wan <kaike.wan@intel.com>
Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
drivers/infiniband/hw/hfi1/rc.c