]> git.baikalelectronics.ru Git - kernel.git/commit
net/smc: add missing dev_put
authorHans Wippel <hwippel@linux.vnet.ibm.com>
Thu, 21 Sep 2017 07:16:26 +0000 (09:16 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 21 Sep 2017 22:31:02 +0000 (15:31 -0700)
commitb3c0f2f723665fa1d73c0ba4dfabe7245effe58c
tree8b782521ae6440bd1b42d8738a3addaf834c58ac
parent7914be2c48833f26cbbc035d3acd41bb5b23c64d
net/smc: add missing dev_put

In the infiniband part, SMC currently uses get_netdev which calls
dev_hold on the returned net device. However, the SMC code never calls
dev_put on that net device resulting in a wrong reference count.

This patch adds a dev_put after the usage of the net device to fix the
issue.

Signed-off-by: Hans Wippel <hwippel@linux.vnet.ibm.com>
Signed-off-by: Ursula Braun <ubraun@linux.vnet.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/smc/smc_ib.c