From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH 2/3] Refactor hypercall infrastructure (v3) Date: Tue, 18 Sep 2007 15:12:48 +0200 Message-ID: <46EFCED0.5050209@qumranet.com> References: <1190059071649-git-send-email-aliguori@us.ibm.com> <11900590723438-git-send-email-aliguori@us.ibm.com> <46EFCE2A.1020105@qumranet.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org, Zachary Amsden , Jeremy Fitzhardinge , linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Anthony Liguori Return-path: In-Reply-To: <46EFCE2A.1020105-atKUWr5tajBWk0Htik3J/w@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org Avi Kivity wrote: > Anthony Liguori wrote: > >> This patch refactors the current hypercall infrastructure to better support live >> migration and SMP. It eliminates the hypercall page by trapping the UD >> exception that would occur if you used the wrong hypercall instruction for the >> underlying architecture and replacing it with the right one lazily. >> >> It also introduces the infrastructure to probe for hypercall available via >> CPUID leaves 0x40000000. CPUID leaf 0x40000001 should be filled out by >> userspace. >> >> A fall-out of this patch is that the unhandled hypercalls no longer trap to >> userspace. There is very little reason though to use a hypercall to communicate >> with userspace as PIO or MMIO can be used. There is no code in tree that uses >> userspace hypercalls. >> >> >> > > > Surprisingly, this patch kills Windows XP (ACPI HAL). I'll try to find > out why. > > Not trapping #UD brings things back to normal. So, Windows likes to execute undefined instructions, and we don'd handle these well. I really should start asking for unit tests for these kinds of things (execute undefined instruction, see the #UD, say ok). -- error compiling committee.c: too many arguments to function ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2005. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/