Skip to content

Commit a92a90a

Browse files
Dan Carpenterjoergroedel
authored andcommitted
iommu/mediatek: Fix error code in probe()
This error path is supposed to return -EINVAL. It used to return directly but we added some clean up and accidentally removed the error code. Also I fixed a typo in the error message. Fixes: c0b5758 ("iommu/mediatek: Add power-domain operation") Signed-off-by: Dan Carpenter <[email protected]> Reviewed-by: Yong Wu <[email protected]> Link: https://lore.kernel.org/r/YB0+GU5akSdu29Vu@mwanda Signed-off-by: Joerg Roedel <[email protected]>
1 parent 7a56617 commit a92a90a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

drivers/iommu/mtk_iommu.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -886,7 +886,8 @@ static int mtk_iommu_probe(struct platform_device *pdev)
886886
link = device_link_add(data->smicomm_dev, dev,
887887
DL_FLAG_STATELESS | DL_FLAG_PM_RUNTIME);
888888
if (!link) {
889-
dev_err(dev, "Unable link %s.\n", dev_name(data->smicomm_dev));
889+
dev_err(dev, "Unable to link %s.\n", dev_name(data->smicomm_dev));
890+
ret = -EINVAL;
890891
goto out_runtime_disable;
891892
}
892893

0 commit comments

Comments
 (0)