[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v2 02/13] iommu: Add extra order argument to the IOMMU APIs and platform callbacks
Hi Oleksandr, On 25/07/17 18:26, Oleksandr Tyshchenko wrote: diff --git a/xen/drivers/passthrough/arm/smmu.c b/xen/drivers/passthrough/arm/smmu.c index 74c09b0..7c313c0 100644 --- a/xen/drivers/passthrough/arm/smmu.c +++ b/xen/drivers/passthrough/arm/smmu.c [...] +static int __must_check arm_smmu_unmap_pages(struct domain *d, + unsigned long gfn, unsigned int order) +{ + unsigned long i; + int rc = 0; + + for (i = 0; i < (1UL << order); i++) { + int ret = arm_smmu_unmap_page(d, gfn + i); Missing blank line between declaration(s) and statement(s). + if (!rc) + rc = ret; + } + + return rc; +} + static const struct iommu_ops arm_smmu_iommu_ops = { .init = arm_smmu_iommu_domain_init, .hwdom_init = arm_smmu_iommu_hwdom_init, @@ -2786,8 +2823,8 @@ static const struct iommu_ops arm_smmu_iommu_ops = { .iotlb_flush_all = arm_smmu_iotlb_flush_all, .assign_device = arm_smmu_assign_dev, .reassign_device = arm_smmu_reassign_dev, - .map_page = arm_smmu_map_page, - .unmap_page = arm_smmu_unmap_page, + .map_pages = arm_smmu_map_pages, + .unmap_pages = arm_smmu_unmap_pages, }; static __init const struct arm_smmu_device *find_smmu(const struct device *dev) [...] diff --git a/xen/drivers/passthrough/vtd/iommu.c b/xen/drivers/passthrough/vtd/iommu.c index 19328f6..b4e8c89 100644 --- a/xen/drivers/passthrough/vtd/iommu.c +++ b/xen/drivers/passthrough/vtd/iommu.c [...] +static int __must_check intel_iommu_unmap_pages(struct domain *d, + unsigned long gfn, + unsigned int order) +{ + unsigned long i; + int rc = 0; + + for ( i = 0; i < (1UL << order); i++ ) + { + int ret = intel_iommu_unmap_page(d, gfn + i); Missing blank line between declaration(s) and statement(s). + if ( !rc ) + rc = ret; + } + + return rc; +} + Cheers, -- Julien Grall _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |