diff options
author | Mitchel Humpherys <mitchelh@codeaurora.org> | 2015-07-29 12:45:29 -0700 |
---|---|---|
committer | David Keitel <dkeitel@codeaurora.org> | 2016-03-22 11:13:41 -0700 |
commit | 4a7ae76ea28a510f98b7c0650beb8cc792a84e9c (patch) | |
tree | 447351df8f52870b204b08a0ed51f0d030721b67 /drivers/iommu/iommu-debug.c | |
parent | d1f111a6f98c2e86471b4cc8c987f0affde1f5ae (diff) |
iommu/iommu-debug: Fix parsing of unmap size
The unmap debugfs file write handler is currently incorrectly parsing
the size to be unmapped (storing the IOVA as the size). Fix this by
parsing from the correct offset (just after the first comma).
Change-Id: I438851882052acc511c713706bc4f0cbf373353e
Signed-off-by: Mitchel Humpherys <mitchelh@codeaurora.org>
Diffstat (limited to 'drivers/iommu/iommu-debug.c')
-rw-r--r-- | drivers/iommu/iommu-debug.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/iommu/iommu-debug.c b/drivers/iommu/iommu-debug.c index f7755441b408..de7ffa7f3bc4 100644 --- a/drivers/iommu/iommu-debug.c +++ b/drivers/iommu/iommu-debug.c @@ -716,7 +716,7 @@ static ssize_t iommu_debug_unmap_write(struct file *file, if (kstrtou64(buf, 0, &iova)) goto invalid_format; - if (kstrtoul(buf, 0, &size)) + if (kstrtoul(comma1 + 1, 0, &size)) goto invalid_format; unmapped = iommu_unmap(ddev->domain, iova, size); |