Skip to content

Commit c61a463

Browse files
zhangshkjoergroedel
authored andcommitted
iommu/dma: Remove unused variable
end_pfn is never used after commit <aa3ac9469c18> ('iommu/iova: Make dma 32bit pfn implicit'), cleanup it. Cc: Joerg Roedel <jroedel@suse.de> Cc: Robin Murphy <robin.murphy@arm.com> Cc: Zhen Lei <thunder.leizhen@huawei.com> Signed-off-by: Shaokun Zhang <zhangshaokun@hisilicon.com> Signed-off-by: Joerg Roedel <jroedel@suse.de>
1 parent bd3c2e6 commit c61a463

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

drivers/iommu/dma-iommu.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ int iommu_dma_init_domain(struct iommu_domain *domain, dma_addr_t base,
289289
{
290290
struct iommu_dma_cookie *cookie = domain->iova_cookie;
291291
struct iova_domain *iovad = &cookie->iovad;
292-
unsigned long order, base_pfn, end_pfn;
292+
unsigned long order, base_pfn;
293293
int attr;
294294

295295
if (!cookie || cookie->type != IOMMU_DMA_IOVA_COOKIE)
@@ -298,7 +298,6 @@ int iommu_dma_init_domain(struct iommu_domain *domain, dma_addr_t base,
298298
/* Use the smallest supported page size for IOVA granularity */
299299
order = __ffs(domain->pgsize_bitmap);
300300
base_pfn = max_t(unsigned long, 1, base >> order);
301-
end_pfn = (base + size - 1) >> order;
302301

303302
/* Check the domain allows at least some access to the device... */
304303
if (domain->geometry.force_aperture) {

0 commit comments

Comments
 (0)