diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2021-02-05 15:46:17 +0300 |
---|---|---|
committer | Joerg Roedel <jroedel@suse.de> | 2021-02-08 09:11:06 +0100 |
commit | a92a90ac62d3284a8deaef43c6ea4dbd5dd878b0 (patch) | |
tree | 52183cd15748bd75d5d116766a8526d8fe8cc550 /drivers/iommu | |
parent | 7a5661739d4bf23cd356fb13bb1e0790e09df3c5 (diff) | |
download | linux-a92a90ac62d3284a8deaef43c6ea4dbd5dd878b0.tar.gz linux-a92a90ac62d3284a8deaef43c6ea4dbd5dd878b0.tar.bz2 linux-a92a90ac62d3284a8deaef43c6ea4dbd5dd878b0.zip |
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: c0b57581b73b ("iommu/mediatek: Add power-domain operation")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: Yong Wu <yong.wu@mediatek.com>
Link: https://lore.kernel.org/r/YB0+GU5akSdu29Vu@mwanda
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Diffstat (limited to 'drivers/iommu')
-rw-r--r-- | drivers/iommu/mtk_iommu.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/iommu/mtk_iommu.c b/drivers/iommu/mtk_iommu.c index 1f262621ef19..6ecc007f07cd 100644 --- a/drivers/iommu/mtk_iommu.c +++ b/drivers/iommu/mtk_iommu.c @@ -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; } |