diff options
author | Jens Axboe <axboe@fb.com> | 2016-09-13 07:58:34 -0600 |
---|---|---|
committer | Jens Axboe <axboe@fb.com> | 2016-09-13 07:58:34 -0600 |
commit | 3bc42f3f0ef13a8239138a4c00a0b782f029f23d (patch) | |
tree | d098779bb062ee740158ed4b41065172ef4aa81b /drivers/infiniband/hw/cxgb4/cm.c | |
parent | 015282c9eb6da05bfad6ff009078f91e06c0c98f (diff) | |
parent | 2cfe199ca5a8816ee80fe15bcf202dd1020aaea0 (diff) | |
download | linux-3bc42f3f0ef13a8239138a4c00a0b782f029f23d.tar.bz2 |
Merge branch 'nvmf-4.8-rc' of git://git.infradead.org/nvme-fabrics into for-linus
Sagi writes:
Here we have:
- Kconfig dependencies fix from Arnd
- nvme-rdma device removal fixes from Steve
- possible bad deref fix from Colin
Diffstat (limited to 'drivers/infiniband/hw/cxgb4/cm.c')
-rw-r--r-- | drivers/infiniband/hw/cxgb4/cm.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/infiniband/hw/cxgb4/cm.c b/drivers/infiniband/hw/cxgb4/cm.c index b6a953aed7e8..80f988984f44 100644 --- a/drivers/infiniband/hw/cxgb4/cm.c +++ b/drivers/infiniband/hw/cxgb4/cm.c @@ -333,6 +333,8 @@ static void remove_ep_tid(struct c4iw_ep *ep) spin_lock_irqsave(&ep->com.dev->lock, flags); _remove_handle(ep->com.dev, &ep->com.dev->hwtid_idr, ep->hwtid, 0); + if (idr_is_empty(&ep->com.dev->hwtid_idr)) + wake_up(&ep->com.dev->wait); spin_unlock_irqrestore(&ep->com.dev->lock, flags); } @@ -2117,8 +2119,10 @@ static int import_ep(struct c4iw_ep *ep, int iptype, __u8 *peer_ip, } ep->l2t = cxgb4_l2t_get(cdev->rdev.lldi.l2t, n, pdev, rt_tos2priority(tos)); - if (!ep->l2t) + if (!ep->l2t) { + dev_put(pdev); goto out; + } ep->mtu = pdev->mtu; ep->tx_chan = cxgb4_port_chan(pdev); ep->smac_idx = cxgb4_tp_smt_idx(adapter_type, |