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

Re: [Xen-devel] [PATCH] x86 linux: prevent halted VCPUs from eating up CPU bandwidth




On 29 May 2006, at 15:35, Jan Beulich wrote:

Since there was no reply to an earlier inquiry regarding this, here's a patch.

Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>

safe_halt() should simply be HYPERVISOR_block() -- the hypercall implicitly reenables interrupt delivery for the calling VCPU, so no need to call __sti() explicitly.

halt() is a bit trickier -- given that it is executed (as far as I can tell) only in contexts where the CPU has reached "end of life" (it's crashed, or offlined, or shut down for some other reason) it might make sense to define halt() as VCPUOP_down. Or, just in case it is used in places with interrupts still enabled, where the CPU may have a future: #define halt() (irqs_disabled() ? HYPERVISOR_vcpu_op(VCPUOP_down) : HYPERVISOR_block())

 -- Keir


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

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