diff options
author | Joerg Roedel <jroedel@suse.de> | 2014-08-19 00:19:26 +0200 |
---|---|---|
committer | Jiri Slaby <jslaby@suse.cz> | 2015-04-09 14:13:47 +0200 |
commit | c45f743a171baa54cc18783f954799e2b30452e8 (patch) | |
tree | 812c2e785e338f849405493cc6c3c9bfc1eebd14 /drivers | |
parent | f22ce19ac3c767fbf4467bc02fa216ec329f007f (diff) |
iommu/core: Check for the right function pointer in iommu_map()
commit 9db4ad9183aad0e9567f6afb23db1bdc9aa6c2a9 upstream.
Check for the ->map and not the ->unmap pointer.
Signed-off-by: Joerg Roedel <jroedel@suse.de>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/iommu/iommu.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/iommu/iommu.c b/drivers/iommu/iommu.c index fbe9ca734f8f..9d71a57c96b1 100644 --- a/drivers/iommu/iommu.c +++ b/drivers/iommu/iommu.c @@ -794,7 +794,7 @@ int iommu_map(struct iommu_domain *domain, unsigned long iova, size_t orig_size = size; int ret = 0; - if (unlikely(domain->ops->unmap == NULL || + if (unlikely(domain->ops->map == NULL || domain->ops->pgsize_bitmap == 0UL)) return -ENODEV; |