]> Git Repo - linux.git/commitdiff
Merge tag 'vfio-v6.12-rc1' of https://github.com/awilliam/linux-vfio
authorLinus Torvalds <[email protected]>
Tue, 24 Sep 2024 19:07:47 +0000 (12:07 -0700)
committerLinus Torvalds <[email protected]>
Tue, 24 Sep 2024 19:07:47 +0000 (12:07 -0700)
Pull VFIO updates from Alex Williamson:
 "Just a few cleanups this cycle:

   - Remove several unused structure and function declarations, and
     unused variables (Dr. David Alan Gilbert, Yue Haibing, Zhang Zekun)

   - Constify unmodified structure in mdev (Hongbo Li)

   - Convert to unsigned type to catch overflow with less fanfare than
     passing a negative value to kcalloc() (Dan Carpenter)"

* tag 'vfio-v6.12-rc1' of https://github.com/awilliam/linux-vfio:
  vfio/pci: clean up a type in vfio_pci_ioctl_pci_hot_reset_groups()
  vfio/mdev: Constify struct kobj_type
  vfio: mdev: Remove unused function declarations
  vfio/fsl-mc: Remove unused variable 'hwirq'
  vfio/pci: Remove unused struct 'vfio_pci_mmap_vma'

drivers/vfio/fsl-mc/vfio_fsl_mc_intr.c
drivers/vfio/mdev/mdev_private.h
drivers/vfio/mdev/mdev_sysfs.c
drivers/vfio/pci/vfio_pci_core.c

index 82b2afa9b7e3134b37107fb3ba31b0c74f4e5683..7e7988c4258fa56014ea37966def12ae9556801d 100644 (file)
@@ -108,10 +108,10 @@ static int vfio_fsl_mc_set_irq_trigger(struct vfio_fsl_mc_device *vdev,
                                       void *data)
 {
        struct fsl_mc_device *mc_dev = vdev->mc_dev;
-       int ret, hwirq;
        struct vfio_fsl_mc_irq *irq;
        struct device *cont_dev = fsl_mc_cont_dev(&mc_dev->dev);
        struct fsl_mc_device *mc_cont = to_fsl_mc_device(cont_dev);
+       int ret;
 
        if (!count && (flags & VFIO_IRQ_SET_DATA_NONE))
                return vfio_set_trigger(vdev, index, -1);
@@ -136,8 +136,6 @@ static int vfio_fsl_mc_set_irq_trigger(struct vfio_fsl_mc_device *vdev,
                return vfio_set_trigger(vdev, index, fd);
        }
 
-       hwirq = vdev->mc_dev->irqs[index]->virq;
-
        irq = &vdev->mc_irqs[index];
 
        if (flags & VFIO_IRQ_SET_DATA_NONE) {
index 63a1316b08b72aef8b790a0901a0db5ca3f1cd75..5f61acd0fe42b93b78cfd816be9e5857635ba16f 100644 (file)
@@ -10,9 +10,6 @@
 #ifndef MDEV_PRIVATE_H
 #define MDEV_PRIVATE_H
 
-int  mdev_bus_register(void);
-void mdev_bus_unregister(void);
-
 extern const struct bus_type mdev_bus_type;
 extern const struct attribute_group *mdev_device_groups[];
 
index 9d2738e10c0b9d4d2b1018e4c948bf427d0315a9..e44bb44c581e2fb6ca5dc07a81fccf70eb51bd66 100644 (file)
@@ -160,7 +160,7 @@ static void mdev_type_release(struct kobject *kobj)
        put_device(type->parent->dev);
 }
 
-static struct kobj_type mdev_type_ktype = {
+static const struct kobj_type mdev_type_ktype = {
        .sysfs_ops      = &mdev_type_sysfs_ops,
        .release        = mdev_type_release,
        .default_groups = mdev_type_groups,
index 2d7478e9a62dd630896a57c963ca0b01628a00f7..1ab58da9f38a6eae6077cbb88efb1d667215efee 100644 (file)
@@ -58,11 +58,6 @@ struct vfio_pci_vf_token {
        int                     users;
 };
 
-struct vfio_pci_mmap_vma {
-       struct vm_area_struct   *vma;
-       struct list_head        vma_next;
-};
-
 static inline bool vfio_vga_disabled(void)
 {
 #ifdef CONFIG_VFIO_PCI_VGA
@@ -1329,7 +1324,7 @@ out:
 
 static int
 vfio_pci_ioctl_pci_hot_reset_groups(struct vfio_pci_core_device *vdev,
-                                   int array_count, bool slot,
+                                   u32 array_count, bool slot,
                                    struct vfio_pci_hot_reset __user *arg)
 {
        int32_t *group_fds;
This page took 0.067826 seconds and 4 git commands to generate.