aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/infiniband/hw/bnxt_re/bnxt_re.h
diff options
context:
space:
mode:
authorSelvin Xavier <selvin.xavier@broadcom.com>2018-02-15 21:20:13 -0800
committerDoug Ledford <dledford@redhat.com>2018-02-20 11:59:47 -0500
commit7374fbd9e167ddc4f380d056ca74518be5d45518 (patch)
tree6481dd80c9b23c758b48285cb462ce72e6909034 /drivers/infiniband/hw/bnxt_re/bnxt_re.h
parentRDMA/bnxt_re: Fix system crash during load/unload (diff)
downloadlinux-dev-7374fbd9e167ddc4f380d056ca74518be5d45518.tar.xz
linux-dev-7374fbd9e167ddc4f380d056ca74518be5d45518.zip
RDMA/bnxt_re: Avoid system hang during device un-reg
BNXT_RE_FLAG_TASK_IN_PROG doesn't handle multiple work requests posted together. Track schedule of multiple workqueue items by maintaining a per device counter and proceed with IB dereg only if this counter is zero. flush_workqueue is no longer required from NETDEV_UNREGISTER path. Signed-off-by: Selvin Xavier <selvin.xavier@broadcom.com> Signed-off-by: Doug Ledford <dledford@redhat.com>
Diffstat (limited to 'drivers/infiniband/hw/bnxt_re/bnxt_re.h')
-rw-r--r--drivers/infiniband/hw/bnxt_re/bnxt_re.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/bnxt_re/bnxt_re.h b/drivers/infiniband/hw/bnxt_re/bnxt_re.h
index ca32057e886f..3eb7a8387116 100644
--- a/drivers/infiniband/hw/bnxt_re/bnxt_re.h
+++ b/drivers/infiniband/hw/bnxt_re/bnxt_re.h
@@ -120,7 +120,6 @@ struct bnxt_re_dev {
#define BNXT_RE_FLAG_HAVE_L2_REF 3
#define BNXT_RE_FLAG_RCFW_CHANNEL_EN 4
#define BNXT_RE_FLAG_QOS_WORK_REG 5
-#define BNXT_RE_FLAG_TASK_IN_PROG 6
#define BNXT_RE_FLAG_ISSUE_ROCE_STATS 29
struct net_device *netdev;
unsigned int version, major, minor;
@@ -158,6 +157,7 @@ struct bnxt_re_dev {
atomic_t srq_count;
atomic_t mr_count;
atomic_t mw_count;
+ atomic_t sched_count;
/* Max of 2 lossless traffic class supported per port */
u16 cosq[2];