summaryrefslogtreecommitdiff
path: root/drivers/iommu/io-pgtable-dart.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/iommu/io-pgtable-dart.c')
-rw-r--r--drivers/iommu/io-pgtable-dart.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/iommu/io-pgtable-dart.c b/drivers/iommu/io-pgtable-dart.c
index ad28031e1e93..c004640640ee 100644
--- a/drivers/iommu/io-pgtable-dart.c
+++ b/drivers/iommu/io-pgtable-dart.c
@@ -245,9 +245,8 @@ static int dart_map_pages(struct io_pgtable_ops *ops, unsigned long iova,
if (WARN_ON(paddr >> cfg->oas))
return -ERANGE;
- /* If no access, then nothing to do */
if (!(iommu_prot & (IOMMU_READ | IOMMU_WRITE)))
- return 0;
+ return -EINVAL;
tbl = dart_get_table(data, iova);