diff options
author | Leon Romanovsky <leonro@mellanox.com> | 2018-01-01 14:07:13 +0300 |
---|---|---|
committer | Jason Gunthorpe <jgg@mellanox.com> | 2018-01-02 23:36:57 +0300 |
commit | 924b8900a49df284464db5d97362801f8a2ac7b4 (patch) | |
tree | 059c1aa76bd6f7ed63ccaf4bde810443ba1a989d /drivers/infiniband/core/device.c | |
parent | b823369b6faa33cc71b65eef9bebcefe622913dc (diff) | |
download | linux-924b8900a49df284464db5d97362801f8a2ac7b4.tar.xz |
RDMA/core: Replace open-coded variant of put_device
There is an existing function to decrease reference counter
of the device, let's use it.
Reviewed-by: Mark Bloch <markb@mellanox.com>
Signed-off-by: Leon Romanovsky <leonro@mellanox.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
Diffstat (limited to 'drivers/infiniband/core/device.c')
-rw-r--r-- | drivers/infiniband/core/device.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/infiniband/core/device.c b/drivers/infiniband/core/device.c index 21302e077be1..a8757b5552de 100644 --- a/drivers/infiniband/core/device.c +++ b/drivers/infiniband/core/device.c @@ -272,7 +272,7 @@ void ib_dealloc_device(struct ib_device *device) { WARN_ON(device->reg_state != IB_DEV_UNREGISTERED && device->reg_state != IB_DEV_UNINITIALIZED); - kobject_put(&device->dev.kobj); + put_device(&device->dev); } EXPORT_SYMBOL(ib_dealloc_device); |