From c8687915ceef3c0c1208a335df6f6758dbeac897 Mon Sep 17 00:00:00 2001 From: Ulf Magnusson Date: Thu, 21 Mar 2019 20:04:21 +0100 Subject: [PATCH] x86: gen_mmu_x86: Fix error-reporting code for non-page-aligned region %z isn't available in Python, and makes the code raise a ValueError. Use %d instead. Integers in Python 3 are not sized/signed (though it's probably a typo from C). Signed-off-by: Ulf Magnusson --- arch/x86/gen_mmu_x86.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/x86/gen_mmu_x86.py b/arch/x86/gen_mmu_x86.py index 93a01f50334..395acc8a1b8 100755 --- a/arch/x86/gen_mmu_x86.py +++ b/arch/x86/gen_mmu_x86.py @@ -470,7 +470,7 @@ def read_mmu_list(mmu_list_data): sys.exit(2) if (size & 0xFFF) != 0: - print("Memory region %d size %zu is not page-aligned" % + print("Memory region %d size %d is not page-aligned" % (region_index, size)) sys.exit(2)