From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH v2 3/3] KVM: x86 emulator: Allow PM/VM86 switch during task switch Date: Mon, 30 Jan 2012 17:44:29 +0200 Message-ID: <4F26BADD.7070800@redhat.com> References: <1327692216-20450-1-git-send-email-kwolf@redhat.com> <1327692216-20450-4-git-send-email-kwolf@redhat.com> <4F266FCB.3000102@redhat.com> <4F267981.20100@redhat.com> <4F2699CE.4000506@redhat.com> <4F26A2AF.8080108@redhat.com> <4F26A9EB.3000804@redhat.com> <4F26B68E.3030100@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: kvm@vger.kernel.org, gleb@redhat.com, joerg.roedel@amd.com, yoshikawa.takuya@oss.ntt.co.jp, mtosatti@redhat.com To: Kevin Wolf Return-path: Received: from mx1.redhat.com ([209.132.183.28]:4814 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753365Ab2A3Poh (ORCPT ); Mon, 30 Jan 2012 10:44:37 -0500 In-Reply-To: <4F26B68E.3030100@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On 01/30/2012 05:26 PM, Kevin Wolf wrote: > > > > My bet is that it will be 3 if eflags.vm=1 and unchanged otherwise -- > > the cpl update happens when the segment cache is updated. But that's > > just a guess. > > Does even anyone see the new CPL in error cases? An exception is thrown > immediately, so cs is reloaded and we get an even newer CPL. Depends on what we have on the IDT for the exception handler... > So to take > any notice of the CPL, the "complete the task switch" part would have to > fail a privilege check. The one thing that comes to mind is that pushing > an error code could fail, but I don't think this is considered part of > the task switch. Right. -- error compiling committee.c: too many arguments to function