]> git.baikalelectronics.ru Git - kernel.git/commit
rapidio: fix the missed put_device() for rio_mport_add_riodev
authorJing Xiangfeng <jingxiangfeng@huawei.com>
Fri, 16 Oct 2020 03:13:18 +0000 (20:13 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 16 Oct 2020 18:11:22 +0000 (11:11 -0700)
commit8f7a66d43036b17b095ffaaa55db3a0334543bbf
tree4bc4c1683fd8e42367f1f2ffcb7706ebbcd18d94
parentdfda469971cd502860e72b9d17c3694ffef1342e
rapidio: fix the missed put_device() for rio_mport_add_riodev

rio_mport_add_riodev() misses to call put_device() when the device already
exists.  Add the missed function call to fix it.

Fixes: d77b359ee139 ("rapidio: add mport char device driver")
Signed-off-by: Jing Xiangfeng <jingxiangfeng@huawei.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com>
Cc: Matt Porter <mporter@kernel.crashing.org>
Cc: Alexandre Bounine <alex.bou9@gmail.com>
Cc: Gustavo A. R. Silva <gustavoars@kernel.org>
Cc: John Hubbard <jhubbard@nvidia.com>
Cc: Kees Cook <keescook@chromium.org>
Cc: Madhuparna Bhowmik <madhuparnabhowmik10@gmail.com>
Link: https://lkml.kernel.org/r/20200922072525.42330-1-jingxiangfeng@huawei.com
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/rapidio/devices/rio_mport_cdev.c