Since the CPUState argument is simply read-only accessed, make it const.
Signed-off-by: Philippe Mathieu-Daudé <[email protected]>
Reviewed-by: Richard Henderson <[email protected]>
Message-Id: <[email protected]>
---
include/exec/cpu-common.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/exec/cpu-common.h b/include/exec/cpu-common.h
index db67c7bb864..919ba41a013 100644
--- a/include/exec/cpu-common.h
+++ b/include/exec/cpu-common.h
@@ -73,7 +73,7 @@ void list_cpus(void);
* call can be used to check if it makes sense to return to the main loop
* or to continue executing the interruptible instruction.
*/
-static inline bool cpu_loop_exit_requested(CPUState *cpu)
+static inline bool cpu_loop_exit_requested(const CPUState *cpu)
{
return (int32_t)qatomic_read(&cpu->neg.icount_decr.u32) < 0;
}
--
2.53.0