mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-05 08:26:59 +00:00
iommu/qcom: Simplify a test in 'qcom_iommu_add_device()'
'iommu_group_get_for_dev()' never returns NULL, so this test can be simplified a bit. This way, the test is consistent with all other calls to 'iommu_group_get_for_dev()'. Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr> Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Joerg Roedel <jroedel@suse.de>
This commit is contained in:
parent
4f5cafb5cb
commit
da6b05dce2
1 changed files with 2 additions and 2 deletions
|
@ -539,8 +539,8 @@ static int qcom_iommu_add_device(struct device *dev)
|
|||
}
|
||||
|
||||
group = iommu_group_get_for_dev(dev);
|
||||
if (IS_ERR_OR_NULL(group))
|
||||
return PTR_ERR_OR_ZERO(group);
|
||||
if (IS_ERR(group))
|
||||
return PTR_ERR(group);
|
||||
|
||||
iommu_group_put(group);
|
||||
iommu_device_link(&qcom_iommu->iommu, dev);
|
||||
|
|
Loading…
Reference in a new issue