A better overall fix would be to have size always being specified as size_t.
Signed-off-by: Andrea Bastoni <[email protected]> --- hypervisor/arch/arm-common/include/asm/dcaches.h | 2 +- hypervisor/arch/arm/mmu_hyp.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/hypervisor/arch/arm-common/include/asm/dcaches.h b/hypervisor/arch/arm-common/include/asm/dcaches.h index 73c2722e..87c316dc 100644 --- a/hypervisor/arch/arm-common/include/asm/dcaches.h +++ b/hypervisor/arch/arm-common/include/asm/dcaches.h @@ -22,7 +22,7 @@ enum dcache_flush { DCACHE_CLEAN_AND_INVALIDATE, }; -void arm_dcaches_flush(void *addr, long size, enum dcache_flush flush); +void arm_dcaches_flush(void *addr, unsigned long size, enum dcache_flush flush); void arm_cell_dcaches_flush(struct cell *cell, enum dcache_flush flush); #endif /* !__ASSEMBLY__ */ diff --git a/hypervisor/arch/arm/mmu_hyp.c b/hypervisor/arch/arm/mmu_hyp.c index 8a897f2b..676c7fda 100644 --- a/hypervisor/arch/arm/mmu_hyp.c +++ b/hypervisor/arch/arm/mmu_hyp.c @@ -47,7 +47,7 @@ static inline unsigned int hvc(unsigned int r0, unsigned int r1) return __r0; } -static int set_id_map(int i, unsigned long address, unsigned long size) +static int set_id_map(unsigned int i, unsigned long address, unsigned long size) { if (i >= ARRAY_SIZE(id_maps)) return -ENOMEM; @@ -368,7 +368,7 @@ void __attribute__((noreturn)) arch_shutdown_mmu(struct per_cpu *cpu_data) __builtin_unreachable(); } -void arm_dcaches_flush(void *addr, long size, enum dcache_flush flush) +void arm_dcaches_flush(void *addr, unsigned long size, enum dcache_flush flush) { while (size > 0) { /* clean / invalidate by MVA to PoC */ -- 2.28.0 -- You received this message because you are subscribed to the Google Groups "Jailhouse" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jailhouse-dev/20201028210933.138379-12-andrea.bastoni%40tum.de.
