Skip to content

Commit 7154cbd

Browse files
committed
iommu/dma: Fix compile warning in 32-bit builds
Compiling the recent dma-iommu changes under 32-bit x86 triggers this compile warning: drivers/iommu/dma-iommu.c:249:5: warning: format ‘%llx’ expects argument of type ‘long long unsigned int’, but argument 3 has type ‘phys_addr_t’ {aka ‘unsigned int’} [-Wformat=] The reason is that %llx is used to print a variable of type phys_addr_t. Fix it by using the correct %pa format specifier for phys_addr_t. Cc: Srinath Mannam <[email protected]> Cc: Robin Murphy <[email protected]> Cc: Oza Pawandeep <[email protected]> Fixes: 571f316 ("iommu/dma: Fix IOVA reserve dma ranges") Signed-off-by: Joerg Roedel <[email protected]> Link: https://lore.kernel.org/r/[email protected]
1 parent a4099d4 commit 7154cbd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/iommu/dma-iommu.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -246,8 +246,8 @@ static int iova_reserve_pci_windows(struct pci_dev *dev,
246246
} else if (end < start) {
247247
/* dma_ranges list should be sorted */
248248
dev_err(&dev->dev,
249-
"Failed to reserve IOVA [%#010llx-%#010llx]\n",
250-
start, end);
249+
"Failed to reserve IOVA [%pa-%pa]\n",
250+
&start, &end);
251251
return -EINVAL;
252252
}
253253

0 commit comments

Comments
 (0)