Skip to content

Commit 12119cf

Browse files
committed
Merge tag 'vfio-v5.16-rc4' of git://github.com/awilliam/linux-vfio
Pull VFIO fixes from Alex Williamson: - Fix OpRegion pointer arithmetic (Zhenyu Wang) - Fix comment format triggering kernel-doc warnings (Randy Dunlap) * tag 'vfio-v5.16-rc4' of git://github.com/awilliam/linux-vfio: vfio/pci: Fix OpRegion read vfio: remove all kernel-doc notation
2 parents 4ec6afd + 8704e89 commit 12119cf

File tree

2 files changed

+17
-16
lines changed

2 files changed

+17
-16
lines changed

drivers/vfio/pci/vfio_pci_igd.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,8 @@ static ssize_t vfio_pci_igd_rw(struct vfio_pci_core_device *vdev,
9898
version = cpu_to_le16(0x0201);
9999

100100
if (igd_opregion_shift_copy(buf, &off,
101-
&version + (pos - OPREGION_VERSION),
101+
(u8 *)&version +
102+
(pos - OPREGION_VERSION),
102103
&pos, &remaining, bytes))
103104
return -EFAULT;
104105
}
@@ -121,7 +122,7 @@ static ssize_t vfio_pci_igd_rw(struct vfio_pci_core_device *vdev,
121122
OPREGION_SIZE : 0);
122123

123124
if (igd_opregion_shift_copy(buf, &off,
124-
&rvda + (pos - OPREGION_RVDA),
125+
(u8 *)&rvda + (pos - OPREGION_RVDA),
125126
&pos, &remaining, bytes))
126127
return -EFAULT;
127128
}

drivers/vfio/vfio.c

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,7 @@ static inline bool vfio_iommu_driver_allowed(struct vfio_container *container,
232232
}
233233
#endif /* CONFIG_VFIO_NOIOMMU */
234234

235-
/**
235+
/*
236236
* IOMMU driver registration
237237
*/
238238
int vfio_register_iommu_driver(const struct vfio_iommu_driver_ops *ops)
@@ -285,7 +285,7 @@ static int vfio_iommu_group_notifier(struct notifier_block *nb,
285285
unsigned long action, void *data);
286286
static void vfio_group_get(struct vfio_group *group);
287287

288-
/**
288+
/*
289289
* Container objects - containers are created when /dev/vfio/vfio is
290290
* opened, but their lifecycle extends until the last user is done, so
291291
* it's freed via kref. Must support container/group/device being
@@ -309,7 +309,7 @@ static void vfio_container_put(struct vfio_container *container)
309309
kref_put(&container->kref, vfio_container_release);
310310
}
311311

312-
/**
312+
/*
313313
* Group objects - create, release, get, put, search
314314
*/
315315
static struct vfio_group *
@@ -488,7 +488,7 @@ static struct vfio_group *vfio_group_get_from_dev(struct device *dev)
488488
return group;
489489
}
490490

491-
/**
491+
/*
492492
* Device objects - create, release, get, put, search
493493
*/
494494
/* Device reference always implies a group reference */
@@ -595,7 +595,7 @@ static int vfio_dev_viable(struct device *dev, void *data)
595595
return ret;
596596
}
597597

598-
/**
598+
/*
599599
* Async device support
600600
*/
601601
static int vfio_group_nb_add_dev(struct vfio_group *group, struct device *dev)
@@ -689,7 +689,7 @@ static int vfio_iommu_group_notifier(struct notifier_block *nb,
689689
return NOTIFY_OK;
690690
}
691691

692-
/**
692+
/*
693693
* VFIO driver API
694694
*/
695695
void vfio_init_group_dev(struct vfio_device *device, struct device *dev,
@@ -831,7 +831,7 @@ int vfio_register_emulated_iommu_dev(struct vfio_device *device)
831831
}
832832
EXPORT_SYMBOL_GPL(vfio_register_emulated_iommu_dev);
833833

834-
/**
834+
/*
835835
* Get a reference to the vfio_device for a device. Even if the
836836
* caller thinks they own the device, they could be racing with a
837837
* release call path, so we can't trust drvdata for the shortcut.
@@ -965,7 +965,7 @@ void vfio_unregister_group_dev(struct vfio_device *device)
965965
}
966966
EXPORT_SYMBOL_GPL(vfio_unregister_group_dev);
967967

968-
/**
968+
/*
969969
* VFIO base fd, /dev/vfio/vfio
970970
*/
971971
static long vfio_ioctl_check_extension(struct vfio_container *container,
@@ -1183,7 +1183,7 @@ static const struct file_operations vfio_fops = {
11831183
.compat_ioctl = compat_ptr_ioctl,
11841184
};
11851185

1186-
/**
1186+
/*
11871187
* VFIO Group fd, /dev/vfio/$GROUP
11881188
*/
11891189
static void __vfio_group_unset_container(struct vfio_group *group)
@@ -1536,7 +1536,7 @@ static const struct file_operations vfio_group_fops = {
15361536
.release = vfio_group_fops_release,
15371537
};
15381538

1539-
/**
1539+
/*
15401540
* VFIO Device fd
15411541
*/
15421542
static int vfio_device_fops_release(struct inode *inode, struct file *filep)
@@ -1611,7 +1611,7 @@ static const struct file_operations vfio_device_fops = {
16111611
.mmap = vfio_device_fops_mmap,
16121612
};
16131613

1614-
/**
1614+
/*
16151615
* External user API, exported by symbols to be linked dynamically.
16161616
*
16171617
* The protocol includes:
@@ -1659,7 +1659,7 @@ struct vfio_group *vfio_group_get_external_user(struct file *filep)
16591659
}
16601660
EXPORT_SYMBOL_GPL(vfio_group_get_external_user);
16611661

1662-
/**
1662+
/*
16631663
* External user API, exported by symbols to be linked dynamically.
16641664
* The external user passes in a device pointer
16651665
* to verify that:
@@ -1725,7 +1725,7 @@ long vfio_external_check_extension(struct vfio_group *group, unsigned long arg)
17251725
}
17261726
EXPORT_SYMBOL_GPL(vfio_external_check_extension);
17271727

1728-
/**
1728+
/*
17291729
* Sub-module support
17301730
*/
17311731
/*
@@ -2272,7 +2272,7 @@ struct iommu_domain *vfio_group_iommu_domain(struct vfio_group *group)
22722272
}
22732273
EXPORT_SYMBOL_GPL(vfio_group_iommu_domain);
22742274

2275-
/**
2275+
/*
22762276
* Module/class support
22772277
*/
22782278
static char *vfio_devnode(struct device *dev, umode_t *mode)

0 commit comments

Comments
 (0)