qemu-ppc
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-ppc] [Qemu-devel] [RFC v3 10/56] ppc: convert to cpu_halted


From: Richard Henderson
Subject: Re: [Qemu-ppc] [Qemu-devel] [RFC v3 10/56] ppc: convert to cpu_halted
Date: Sun, 21 Oct 2018 13:56:59 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1

On 10/19/18 2:05 AM, Emilio G. Cota wrote:
> @@ -1088,11 +1088,13 @@ static target_ulong h_cede(PowerPCCPU *cpu, 
> sPAPRMachineState *spapr,
>  
>      env->msr |= (1ULL << MSR_EE);
>      hreg_compute_hflags(env);
> +    cpu_mutex_lock(cs);
>      if (!cpu_has_work(cs)) {
> -        cs->halted = 1;
> +        cpu_halted_set(cs, 1);
>          cs->exception_index = EXCP_HLT;
>          cs->exit_request = 1;
>      }
> +    cpu_mutex_unlock(cs);
>      return H_SUCCESS;

Why does this one get extra locking?


r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]