From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jiang Liu Subject: Re: [PATCH 02/13] KVM: Initialize VT-d Posted-Interrtups Descriptor Date: Thu, 20 Nov 2014 13:00:52 +0800 Message-ID: <546D7584.6070505@linux.intel.com> References: <1415600812-27773-1-git-send-email-feng.wu@intel.com> <1415600812-27773-3-git-send-email-feng.wu@intel.com> <546210B1.7060007@linux.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Errors-To: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: "Wu, Feng" , "gleb-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org" , "pbonzini-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org" , "dwmw2-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org" , "joro-zLv9SwRftAIdnm+yROfE0A@public.gmane.org" , "tglx-hfZtesqFncYOwBW4kG4KsQ@public.gmane.org" , "mingo-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org" , "hpa-YMNOUZJC4hwAvxtiuMwx3w@public.gmane.org" , "x86-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org" Cc: "iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org" , "linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" , "kvm-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" List-Id: iommu@lists.linux-foundation.org On 2014/11/20 12:53, Wu, Feng wrote: > > >> -----Original Message----- >>> + /* >>> + * Initialize Posted-Interrupt Descriptor >>> + */ >>> + >>> + pi_clear_sn(&vmx->pi_desc); >>> + vmx->pi_desc.nv = POSTED_INTR_VECTOR; >>> + >>> + /* Physical mode for Notificaiton Event */ >>> + vmx->pi_desc.ndm = 0; >>> + dest = cpu_physical_id(vmx->vcpu.cpu); >>> + >>> + if (x2apic_mode) >> Hi Feng, >> Could you try to use x2apic_enabled() here so you don't >> need to export x2apic_mode? >> Regards! >> Gerry > > In that case, we should also export x2apic_enabled(), right? Hi Feng, x2apic_enabled() is a static inline function:) Regards! Gerry