On 2026-09-01 11:52 +0200, Philippe Mathieu-Daudé wrote:
> Both cpu_exec_start() and cpu_exec_end() take a non-const CPUState
> argument, however here we get that argument via PTETranslate::env
> so @in->env can not be const. Remove the const qualifier.
> 
> Fixes: 4a1e9d4d11c ("target/i386: Use atomic ops for pte updates")
> Signed-off-by: Philippe Mathieu-Daudé <[email protected]>

I think this is not really a fix, but more like a style/contract thing
anyway:
Reviewed-by: Marc-André Lureau <[email protected]>

> ---
>  target/i386/tcg/system/excp_helper.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/target/i386/tcg/system/excp_helper.c 
> b/target/i386/tcg/system/excp_helper.c
> index d7ea77c8558..44be98a3c92 100644
> --- a/target/i386/tcg/system/excp_helper.c
> +++ b/target/i386/tcg/system/excp_helper.c
> @@ -106,7 +106,7 @@ static inline uint64_t ptw_ldq(const PTETranslate *in, 
> uint64_t ra)
>   * even 64-bit ones, because PG_PRESENT_MASK, PG_ACCESSED_MASK and
>   * PG_DIRTY_MASK are all in the low 32 bits.
>   */
> -static bool ptw_setl_slow(const PTETranslate *in, uint32_t old, uint32_t new)
> +static bool ptw_setl_slow(PTETranslate *in, uint32_t old, uint32_t new)
>  {
>      uint32_t cmp;
>  
> @@ -125,7 +125,7 @@ static bool ptw_setl_slow(const PTETranslate *in, 
> uint32_t old, uint32_t new)
>      return cmp == old;
>  }
>  
> -static inline bool ptw_setl(const PTETranslate *in, uint32_t old, uint32_t 
> set)
> +static inline bool ptw_setl(PTETranslate *in, uint32_t old, uint32_t set)
>  {
>      if (set & ~old) {
>          uint32_t new = old | set;
> -- 
> 2.53.0
> 
> 
> 



Reply via email to