From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matt Wilson Subject: Re: [PATCH] xen/x86: add a comment regarding how to get the VCPU ID on HVM Date: Mon, 23 Sep 2013 13:10:34 -0400 Message-ID: <20130923171034.GA25148@u109add4315675089e695.ant.amazon.com> References: <1379955329-46730-1-git-send-email-roger.pau@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1VO9el-0004tO-Ft for xen-devel@lists.xenproject.org; Mon, 23 Sep 2013 17:10:43 +0000 Received: by mail-qa0-f52.google.com with SMTP id k4so1668367qaq.4 for ; Mon, 23 Sep 2013 10:10:40 -0700 (PDT) Content-Disposition: inline In-Reply-To: <1379955329-46730-1-git-send-email-roger.pau@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Roger Pau Monne Cc: xen-devel@lists.xenproject.org, Keir Fraser , Jan Beulich , Matt Wilson List-Id: xen-devel@lists.xenproject.org On Mon, Sep 23, 2013 at 06:55:29PM +0200, Roger Pau Monne wrote: > Add a note to the public headers regarding how to get the VCPU ID for > HVM guests (on x86). > > Signed-off-by: Roger Pau Monn=E9 > Cc: Jan Beulich > Cc: Keir Fraser > Cc: Konrad Rzeszutek Wilk > Cc: Matt Wilson > --- > This is what Linux PVHVM does AFAIK, and also what I've been using in > my FreeBSD PVHVM series, but it's not written anywere. What about rewording slightly to: For x86 HVM domains that use VCPU operations the VCPU ID is the ACPI Processor ID of the CPU (not to be confused with the APIC ID), as fetched from the MADT table. The field is "ACPI Processor ID" in the spec. Otherwise: Acked-by: Matt Wilson --msw > --- > xen/include/public/vcpu.h | 3 +++ > 1 files changed, 3 insertions(+), 0 deletions(-) > = > diff --git a/xen/include/public/vcpu.h b/xen/include/public/vcpu.h > index e888daf..a5ca44d 100644 > --- a/xen/include/public/vcpu.h > +++ b/xen/include/public/vcpu.h > @@ -35,6 +35,9 @@ > * @cmd =3D=3D VCPUOP_??? (VCPU operation). > * @vcpuid =3D=3D VCPU to operate on. > * @extra_args =3D=3D Operation-specific extra arguments (NULL if none). > + * > + * For x86 HVM domains that use VCPU operations the VCPU ID is the ACPI = ID > + * of the CPU, as fetched from the MADT table. > */ > = > /*