]> git.baikalelectronics.ru Git - kernel.git/commit
vfio/platform: fix module_put call in error flow
authorMax Gurtovoy <mgurtovoy@nvidia.com>
Tue, 18 May 2021 19:21:31 +0000 (22:21 +0300)
committerAlex Williamson <alex.williamson@redhat.com>
Mon, 24 May 2021 19:40:13 +0000 (13:40 -0600)
commit1ac966fc68165a6a156e67ef587207aeaf4ade89
tree2f8dc7a40187aec11d15447f314426d1b69159ad
parentd132dfaee086140804a84cdce1cc010741c7e8e0
vfio/platform: fix module_put call in error flow

The ->parent_module is the one that use in try_module_get. It should
also be the one the we use in module_put during vfio_platform_open().

Fixes: b0799d9a0775 ("vfio: platform: introduce vfio-platform-base module")
Signed-off-by: Max Gurtovoy <mgurtovoy@nvidia.com>
Message-Id: <20210518192133.59195-1-mgurtovoy@nvidia.com>
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
drivers/vfio/platform/vfio_platform_common.c