Commit a92a90ac authored by Dan Carpenter's avatar Dan Carpenter Committed by Joerg Roedel
Browse files

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: c0b57581 ("iommu/mediatek: Add power-domain operation")
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: default avatarYong Wu <yong.wu@mediatek.com>
Link: https://lore.kernel.org/r/YB0+GU5akSdu29Vu@mwanda


Signed-off-by: default avatarJoerg Roedel <jroedel@suse.de>
parent 7a566173
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -886,7 +886,8 @@ static int mtk_iommu_probe(struct platform_device *pdev)
	link = device_link_add(data->smicomm_dev, dev,
			DL_FLAG_STATELESS | DL_FLAG_PM_RUNTIME);
	if (!link) {
		dev_err(dev, "Unable link %s.\n", dev_name(data->smicomm_dev));
		dev_err(dev, "Unable to link %s.\n", dev_name(data->smicomm_dev));
		ret = -EINVAL;
		goto out_runtime_disable;
	}