From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:58458) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R20db-0000wI-UG for qemu-devel@nongnu.org; Fri, 09 Sep 2011 08:56:56 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R20da-0001hp-Qa for qemu-devel@nongnu.org; Fri, 09 Sep 2011 08:56:55 -0400 Received: from mx1.redhat.com ([209.132.183.28]:61530) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R20da-0001f3-IU for qemu-devel@nongnu.org; Fri, 09 Sep 2011 08:56:54 -0400 Date: Fri, 9 Sep 2011 09:56:35 -0300 From: Marcelo Tosatti Message-ID: <20110909125635.GA10198@amt.cnet> References: <4E521EF9.7020404@redhat.com> <20110823104723.GA2898@amt.cnet> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Subject: Re: [Qemu-devel] [PATCH] KVM: emulate lapic tsc deadline timer for hvm List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Liu, Jinsong" Cc: Avi Kivity , "kvm@vger.kernel.org" , "qemu-devel@nongnu.org" On Fri, Sep 09, 2011 at 01:12:51AM +0800, Liu, Jinsong wrote: > >>> --- a/arch/x86/include/asm/msr-index.h > >>> +++ b/arch/x86/include/asm/msr-index.h > >>> @@ -229,6 +229,8 @@ > >>> #define MSR_IA32_APICBASE_ENABLE (1<<11) > >>> #define MSR_IA32_APICBASE_BASE (0xfffff<<12) > >>> > >>> +#define MSR_IA32_TSCDEADLINE 0x000006e0 > >>> + > >>> #define MSR_IA32_UCODE_WRITE 0x00000079 > >>> #define MSR_IA32_UCODE_REV 0x0000008b > >> > >> Need to add to msrs_to_save so live migration works. > > > > MSR must be explicitly listed in qemu, also. > > > > Marcelo, seems MSR don't need explicitly list in qemu? > KVM side adding MSR_IA32_TSCDEADLINE to msrs_to_save is enough. Qemu will get it through KVM_GET_MSR_INDEX_LIST. > Do I miss something? Notice in target-i386/kvm.c the KVM_GET_MSR_INDEX_LIST list is only used for MSR_STAR/MSR_HSAVE_PA presence detection. Do you do need to explicitly add MSR_IA32_TSCDEADLINE to kvm_get_msrs/kvm_put_msrs routines.