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

Re: [Xen-devel] [PATCH RFC v1 47/74] x86/guest: fix upcall vector setup



>>> On 04.01.18 at 14:05, <wei.liu2@xxxxxxxxxx> wrote:
> From: Roger Pau Monne <roger.pau@xxxxxxxxxx>
> 
> Instead of forcing no pending event on the vCPU, just mask all event
> channels when setting up the BSP and further patches will unmask them
> as event channels are being setup.
> 
> Signed-off-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>
> ---
> To be squashed with "x86/guest: enable event channels upcalls"

Yes please.

> @@ -95,6 +95,10 @@ static void map_shared_info(void)
>          panic("Failed to map shared_info page");
>  
>      set_fixmap(FIX_XEN_SHARED_INFO, mfn_x(mfn) << PAGE_SHIFT);
> +
> +    /* Mask all upcalls */
> +    for ( i = 0; i < ARRAY_SIZE(XEN_shared_info->evtchn_mask); i++ )
> +        xchg(&XEN_shared_info->evtchn_mask[i], ~0ul);

Just like there, write_atomic() would likely be better than xchg().

Jan

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.