|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH 1/2] x86: suppress event check IPI to MWAITing CPUs
>>> On 11.09.14 at 12:02, <andrew.cooper3@xxxxxxxxxx> wrote:
> On 11/09/14 10:40, Jan Beulich wrote:
>> @@ -349,7 +359,7 @@ void mwait_idle_with_hints(unsigned int
>> * Timer deadline passing is the event on which we will be woken via
>> * cpuidle_mwait_wakeup. So check it now that the location is armed.
>> */
>> - if ( expires > NOW() || expires == 0 )
>> + if ( (expires > NOW() || expires == 0) && !softirq_pending(cpu) )
>> {
>> cpumask_set_cpu(cpu, &cpuidle_mwait_flags);
>
> Don't you need a smp_wmb() or better here for the results of
> cpumask_set_cpu() to be guaranteed to be externally visible? mwait does
> not appear to be a serialising instruction, and doesn't appear to have
> any ordering guarantees in the manual.
I think cpumask_set_cpu() using a LOCKed r-m-w instruction should
provide all the needed ordering.
Jan
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |