diff --git a/arch/riscv/mmu.cpp b/arch/riscv/mmu.cpp index 585ada6b..3804f6fa 100644 --- a/arch/riscv/mmu.cpp +++ b/arch/riscv/mmu.cpp @@ -113,7 +113,7 @@ void riscv_set_satp(uint asid, paddr_t pt) { #endif // make sure the asid is in range - DEBUG_ASSERT_MSG((asid & riscv_asid_mask) == asid, "asid %#x mask %#x\n", asid, riscv_asid_mask); + DEBUG_ASSERT_MSG((asid & riscv_asid_mask) == asid, "asid %#x mask %#lx\n", asid, riscv_asid_mask); satp |= (ulong)asid << RISCV_SATP_ASID_SHIFT; // make sure the page table is aligned diff --git a/lib/libc/include/assert.h b/lib/libc/include/assert.h index ad73058a..7b476fe6 100644 --- a/lib/libc/include/assert.h +++ b/lib/libc/include/assert.h @@ -88,6 +88,6 @@ __BEGIN_CDECLS // The following functions are called when an assert fails. void assert_fail(const char *file, int line, const char *expression) __NO_RETURN __NO_INLINE; void assert_fail_msg(const char *file, int line, const char *expression, const char *fmt, - ...) __NO_RETURN __NO_INLINE; + ...) __PRINTFLIKE(4, 5) __NO_RETURN __NO_INLINE; __END_CDECLS