On 22.01.2026 17:47, Oleksii Kurochko wrote:
> --- a/xen/arch/riscv/domain.c
> +++ b/xen/arch/riscv/domain.c
> @@ -259,3 +259,21 @@ void sync_local_execstate(void)
>  {
>      /* Nothing to do -- no lazy switching */
>  }
> +
> +void sync_vcpu_execstate(struct vcpu *v)
> +{
> +    /*
> +     * We don't support lazy switching.
> +     *
> +     * However the context may have been saved from a remote pCPU so we
> +     * need a barrier to ensure it is observed before continuing.
> +     *
> +     * Per vcpu_context_saved(), the context can be observed when
> +     * v->is_running is false (the caller should check it before calling
> +     * this function).
> +     *
> +     * Note this is a full barrier to also prevent update of the context
> +     * to happen before it was observed.
> +     */
> +    smp_mb();
> +}

Where's the counterpart of this barrier (going to be)?

Jan

Reply via email to