iommu/omap: Return ERR_PTR in device_group call-back
Make sure that the device_group callback returns an ERR_PTR instead of NULL. Signed-off-by: Joerg Roedel <jroedel@suse.de>
This commit is contained in:
parent
7f7a2304aa
commit
8faf5e5a12
|
@ -1309,7 +1309,7 @@ static void omap_iommu_remove_device(struct device *dev)
|
||||||
static struct iommu_group *omap_iommu_device_group(struct device *dev)
|
static struct iommu_group *omap_iommu_device_group(struct device *dev)
|
||||||
{
|
{
|
||||||
struct omap_iommu_arch_data *arch_data = dev->archdata.iommu;
|
struct omap_iommu_arch_data *arch_data = dev->archdata.iommu;
|
||||||
struct iommu_group *group = NULL;
|
struct iommu_group *group = ERR_PTR(-EINVAL);
|
||||||
|
|
||||||
if (arch_data->iommu_dev)
|
if (arch_data->iommu_dev)
|
||||||
group = arch_data->iommu_dev->group;
|
group = arch_data->iommu_dev->group;
|
||||||
|
|
Loading…
Reference in New Issue