xen-devel
[Xen-devel] RE: expose MWAIT to dom0
>>> On 15.08.11 at 09:57, "Tian, Kevin" <kevin.tian@xxxxxxxxx> wrote:
> So how about the change like below?
>
> emulate_forced_invalid_op:
> - __clear_bit(X86_FEATURE_MWAIT % 32, &c);
> + if ( !IS_PRIV(current->domain) || !xen_cpuidle )
> + __clear_bit(X86_FEATURE_MWAIT % 32, &c);
You'd break any Dom0 kernel that uses the flag to determine whether it
can actually use the mwait/monitor instructions. I agree with Keir that
for this particular purpose the code ought to look at the real CPUID
flag.
It should be possible to do this without changing non-Xen code, since
the use of the instructions is additionally gated on CPUID leaf 5
producing non-zero output. But again, the kernel has to do this for
itself, the hypervisor shouldn't expose the feature flag.
Jan
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread>
|
- [Xen-devel] Re: expose MWAIT to dom0, (continued)
- [Xen-devel] Re: expose MWAIT to dom0, Keir Fraser
- [Xen-devel] RE: expose MWAIT to dom0, Tian, Kevin
- [Xen-devel] Re: expose MWAIT to dom0, Keir Fraser
- [Xen-devel] RE: expose MWAIT to dom0, Tian, Kevin
- [Xen-devel] Re: expose MWAIT to dom0, Keir Fraser
- [Xen-devel] RE: expose MWAIT to dom0, Tian, Kevin
- [Xen-devel] RE: expose MWAIT to dom0, Jan Beulich
- [Xen-devel] Re: expose MWAIT to dom0, Keir Fraser
- [Xen-devel] RE: expose MWAIT to dom0, Tian, Kevin
- [Xen-devel] Re: expose MWAIT to dom0, Keir Fraser
- [Xen-devel] RE: expose MWAIT to dom0,
Jan Beulich <=
- RE: [Xen-devel] RE: expose MWAIT to dom0, Tian, Kevin
Re: [Xen-devel] expose MWAIT to dom0, Jan Beulich
- RE: [Xen-devel] expose MWAIT to dom0, Tian, Kevin
- RE: [Xen-devel] expose MWAIT to dom0, Jan Beulich
- RE: [Xen-devel] expose MWAIT to dom0, Jan Beulich
- RE: [Xen-devel] expose MWAIT to dom0, Tian, Kevin
- RE: [Xen-devel] expose MWAIT to dom0, Jan Beulich
- RE: [Xen-devel] expose MWAIT to dom0, Tian, Kevin
- RE: [Xen-devel] expose MWAIT to dom0, Jan Beulich
- RE: [Xen-devel] expose MWAIT to dom0, Tian, Kevin
|
|
|