linux/drivers/s390
Jason Gunthorpe 9c799c224d vfio/mdev: add mdev available instance checking to the core
Many of the mdev drivers use a simple counter for keeping track of the
available instances. Move this code to the core code and store the counter
in the mdev_parent. Implement it using correct locking, fixing mdpy.

Drivers just provide the value in the mdev_driver at registration time
and the core code takes care of maintaining it and exposing the value in
sysfs.

[hch: count instances per-parent instead of per-type, use an atomic_t
 to avoid taking mdev_list_lock in the show method]

Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Kevin Tian <kevin.tian@intel.com>
Reviewed-by: Kirti Wankhede <kwankhede@nvidia.com>
Reviewed-by: Eric Farman <farman@linux.ibm.com>
Link: https://lore.kernel.org/r/20220923092652.100656-15-hch@lst.de
Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
2022-10-04 12:06:58 -06:00
..
block s390/dasd: Establish DMA alignment 2022-08-04 16:19:15 -06:00
char s390 updates for 5.20 merge window 2022-08-06 17:05:21 -07:00
cio vfio/mdev: add mdev available instance checking to the core 2022-10-04 12:06:58 -06:00
crypto vfio/mdev: add mdev available instance checking to the core 2022-10-04 12:06:58 -06:00
net s390/qeth: cache link_info for ethtool 2022-08-08 20:57:56 -07:00
scsi scsi: zfcp: Fix missing auto port scan and thus missing target ports 2022-08-01 19:50:00 -04:00
virtio virtio: Revert "virtio: find_vqs() add arg sizes" 2022-08-16 01:40:24 -04:00
Makefile