]> git.baikalelectronics.ru Git - kernel.git/commit
vfio: Change struct vfio_group::opened from an atomic to bool
authorJason Gunthorpe <jgg@nvidia.com>
Mon, 16 May 2022 23:41:18 +0000 (20:41 -0300)
committerAlex Williamson <alex.williamson@redhat.com>
Tue, 17 May 2022 19:07:09 +0000 (13:07 -0600)
commitcc0fc2d1dc044dfdb88d2012000b73edf672c83d
tree3f567232c420ea465993379fdff9c76f8d59c7aa
parent8419f4408ed527677640f9cce7ccf9fae89e8c58
vfio: Change struct vfio_group::opened from an atomic to bool

This is not a performance path, just use the group_rwsem to protect the
value.

Reviewed-by: Kevin Tian <kevin.tian@intel.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Tested-by: Nicolin Chen <nicolinc@nvidia.com>
Tested-by: Matthew Rosato <mjrosato@linux.ibm.com>
Link: https://lore.kernel.org/r/2-v2-d035a1842d81+1bf-vfio_group_locking_jgg@nvidia.com
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
drivers/vfio/vfio.c