diff options
| author | Guo Ren <[email protected]> | 2025-01-03 02:46:16 +0000 |
|---|---|---|
| committer | Joerg Roedel <[email protected]> | 2025-01-17 07:58:06 +0000 |
| commit | 10c62c38b073ecea775b7e23fa7c7a3995a84ff3 (patch) | |
| tree | 891e100f8f4522c725054deafaead4ab9465fbad | |
| parent | iommu/riscv: Add shutdown function for iommu driver (diff) | |
| download | kernel-10c62c38b073ecea775b7e23fa7c7a3995a84ff3.tar.gz kernel-10c62c38b073ecea775b7e23fa7c7a3995a84ff3.zip | |
iommu/riscv: Fixup compile warning
When __BITS_PER_LONG == 32, size_t is defined as unsigned int rather
than unsigned long. Therefore, we should use size_t to avoid
type-checking errors.
Fixes: 488ffbf18171 ("iommu/riscv: Paging domain support")
Signed-off-by: Guo Ren <[email protected]>
Signed-off-by: Guo Ren <[email protected]>
Cc: Tomasz Jeznach <[email protected]>
Reviewed-by: Charlie Jenkins <[email protected]>
Reviewed-by: Tomasz Jeznach <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Joerg Roedel <[email protected]>
| -rw-r--r-- | drivers/iommu/riscv/iommu.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/iommu/riscv/iommu.c b/drivers/iommu/riscv/iommu.c index 670b4302aca8..8f049d4a0e2c 100644 --- a/drivers/iommu/riscv/iommu.c +++ b/drivers/iommu/riscv/iommu.c @@ -1278,7 +1278,7 @@ static phys_addr_t riscv_iommu_iova_to_phys(struct iommu_domain *iommu_domain, dma_addr_t iova) { struct riscv_iommu_domain *domain = iommu_domain_to_riscv(iommu_domain); - unsigned long pte_size; + size_t pte_size; unsigned long *ptr; ptr = riscv_iommu_pte_fetch(domain, iova, &pte_size); |
