From d00e5ec47da845c71ed51b9fccf9e15e9448bb47 Mon Sep 17 00:00:00 2001 From: Richard Henderson Date: Sat, 21 Mar 2020 16:40:32 -0400 Subject: [PATCH] target/arm: Use bool for unmasked in arm_excp_unmasked The value computed is fully boolean; using int8_t is odd. Backports commit 16e07f78df002067bc4bfb115ba1ee0ce278e9e5 from qemu --- qemu/target/arm/cpu.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/qemu/target/arm/cpu.c b/qemu/target/arm/cpu.c index de1a47b4..83053e4f 100644 --- a/qemu/target/arm/cpu.c +++ b/qemu/target/arm/cpu.c @@ -408,7 +408,7 @@ static inline bool arm_excp_unmasked(CPUState *cs, unsigned int excp_idx, { CPUARMState *env = cs->env_ptr; bool pstate_unmasked; - int8_t unmasked = 0; + bool unmasked = false; /* * Don't take exceptions if they target a lower EL. @@ -459,7 +459,7 @@ static inline bool arm_excp_unmasked(CPUState *cs, unsigned int excp_idx, * don't affect the masking logic, only the interrupt routing. */ if (target_el == 3 || !secure) { - unmasked = 1; + unmasked = true; } } else { /* @@ -505,7 +505,7 @@ static inline bool arm_excp_unmasked(CPUState *cs, unsigned int excp_idx, } if ((scr || hcr) && !secure) { - unmasked = 1; + unmasked = true; } } }