vfio: Use ERR_CAST() instead of open coding it
It's a small cleanup to use ERR_CAST() here. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Alex Williamson <alex.williamson@redhat.com>
This commit is contained in:
Родитель
7d57e5e933
Коммит
7b3a10df1d
|
@ -382,7 +382,7 @@ static struct vfio_group *vfio_create_group(struct iommu_group *iommu_group)
|
|||
if (IS_ERR(dev)) {
|
||||
vfio_free_group_minor(minor);
|
||||
vfio_group_unlock_and_free(group);
|
||||
return (struct vfio_group *)dev; /* ERR_PTR */
|
||||
return ERR_CAST(dev);
|
||||
}
|
||||
|
||||
group->minor = minor;
|
||||
|
|
Загрузка…
Ссылка в новой задаче