From patchwork Tue Mar 8 16:37:11 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joao Martins X-Patchwork-Id: 8535761 Return-Path: X-Original-To: patchwork-xen-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 6DC7BC0554 for ; Tue, 8 Mar 2016 16:40:13 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 15DCC2020F for ; Tue, 8 Mar 2016 16:40:11 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id A69E5201EF for ; Tue, 8 Mar 2016 16:40:09 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xen.org with esmtp (Exim 4.84) (envelope-from ) id 1adKdY-0005yH-Un; Tue, 08 Mar 2016 16:37:32 +0000 Received: from mail6.bemta6.messagelabs.com ([85.158.143.247]) by lists.xen.org with esmtp (Exim 4.84) (envelope-from ) id 1adKdX-0005y4-M0 for xen-devel@lists.xen.org; Tue, 08 Mar 2016 16:37:31 +0000 Received: from [85.158.143.35] by server-3.bemta-6.messagelabs.com id 43/70-07120-ACFFED65; Tue, 08 Mar 2016 16:37:30 +0000 X-Env-Sender: joao.m.martins@oracle.com X-Msg-Ref: server-12.tower-21.messagelabs.com!1457455048!4929474!1 X-Originating-IP: [141.146.126.69] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogMTQxLjE0Ni4xMjYuNjkgPT4gMjc3MjE4\n X-StarScan-Received: X-StarScan-Version: 8.11; banners=-,-,- X-VirusChecked: Checked Received: (qmail 5384 invoked from network); 8 Mar 2016 16:37:29 -0000 Received: from aserp1040.oracle.com (HELO aserp1040.oracle.com) (141.146.126.69) by server-12.tower-21.messagelabs.com with DHE-RSA-AES256-GCM-SHA384 encrypted SMTP; 8 Mar 2016 16:37:29 -0000 Received: from userv0021.oracle.com (userv0021.oracle.com [156.151.31.71]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id u28GbLQV010450 (version=TLSv1 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Tue, 8 Mar 2016 16:37:22 GMT Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by userv0021.oracle.com (8.13.8/8.13.8) with ESMTP id u28GbLt2012582 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Tue, 8 Mar 2016 16:37:21 GMT Received: from abhmp0007.oracle.com (abhmp0007.oracle.com [141.146.116.13]) by aserv0122.oracle.com (8.13.8/8.13.8) with ESMTP id u28GbIp8017386; Tue, 8 Mar 2016 16:37:20 GMT Received: from [192.168.0.101] (/89.181.14.119) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Tue, 08 Mar 2016 08:37:18 -0800 From: Joao Martins To: Jim Fehlig References: <1456804848-13127-1-git-send-email-jfehlig@suse.com> <1456804848-13127-2-git-send-email-jfehlig@suse.com> Message-ID: <56DEFFB7.8030001@oracle.com> Date: Tue, 8 Mar 2016 16:37:11 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Icedove/38.4.0 MIME-Version: 1.0 In-Reply-To: <1456804848-13127-2-git-send-email-jfehlig@suse.com> X-Source-IP: userv0021.oracle.com [156.151.31.71] Cc: libvir-list@redhat.com, xen-devel@lists.xen.org Subject: Re: [Xen-devel] [libvirt] [PATCH V2 1/4] conf: add 'state' attribute to feature X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On 03/01/2016 04:00 AM, Jim Fehlig wrote: > Most hypervisors use Hardware Assisted Paging by default and don't > require specifying the feature in domain conf. But some hypervisors > support disabling HAP on a per-domain basis. To enable HAP by default > yet provide a knob to disable it, extend the feature with a > 'state=on|off' attribute, similar to and features. > > In the absence of , the hypervisor default (on) is used. > without the state attribute would be the same as for > backwards compatibility. And of course disables hap. > > Signed-off-by: Jim Fehlig > --- > docs/formatdomain.html.in | 6 ++++-- > docs/schemas/domaincommon.rng | 6 +++++- > src/conf/domain_conf.c | 4 ++-- > 3 files changed, 11 insertions(+), 5 deletions(-) > > diff --git a/docs/formatdomain.html.in b/docs/formatdomain.html.in > index 5016772..c06bcf3 100644 > --- a/docs/formatdomain.html.in > +++ b/docs/formatdomain.html.in > @@ -1494,8 +1494,10 @@ > Interrupt) for the guest. > >
hap
> -
Enable use of Hardware Assisted Paging if available in > - the hardware. > +
Depending on the state attribute (values on, > + off) enable or disable use of Hardware Assisted Paging. > + The default is on if the hypervisor detects availability > + of Hardware Assisted Paging. >
>
viridian
>
Enable Viridian hypervisor extensions for paravirtualizing > diff --git a/docs/schemas/domaincommon.rng b/docs/schemas/domaincommon.rng > index 67af93a..dd6e93a 100644 > --- a/docs/schemas/domaincommon.rng > +++ b/docs/schemas/domaincommon.rng > @@ -4108,7 +4108,11 @@ > > > > - > + > + > + > + > + Perhaps would be better (see chunk below) ? That one appears to be a reference of what you are adding above, and it's the same as pvspinlock. Though some other elements don't appear to use this, not sure why. Other that, Reviewed-by: Joao Martins > > > > diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c > index 79758d4..714bbfc 100644 > --- a/src/conf/domain_conf.c > +++ b/src/conf/domain_conf.c > @@ -15296,7 +15296,6 @@ virDomainDefParseXML(xmlDocPtr xml, > /* fallthrough */ > case VIR_DOMAIN_FEATURE_ACPI: > case VIR_DOMAIN_FEATURE_PAE: > - case VIR_DOMAIN_FEATURE_HAP: > case VIR_DOMAIN_FEATURE_VIRIDIAN: > case VIR_DOMAIN_FEATURE_PRIVNET: > case VIR_DOMAIN_FEATURE_HYPERV: > @@ -15321,6 +15320,7 @@ virDomainDefParseXML(xmlDocPtr xml, > ctxt->node = node; > break; > > + case VIR_DOMAIN_FEATURE_HAP: > case VIR_DOMAIN_FEATURE_PMU: > case VIR_DOMAIN_FEATURE_PVSPINLOCK: > case VIR_DOMAIN_FEATURE_VMPORT: > @@ -22043,7 +22043,6 @@ virDomainDefFormatInternal(virDomainDefPtr def, > switch ((virDomainFeature) i) { > case VIR_DOMAIN_FEATURE_ACPI: > case VIR_DOMAIN_FEATURE_PAE: > - case VIR_DOMAIN_FEATURE_HAP: > case VIR_DOMAIN_FEATURE_VIRIDIAN: > case VIR_DOMAIN_FEATURE_PRIVNET: > switch ((virTristateSwitch) def->features[i]) { > @@ -22065,6 +22064,7 @@ virDomainDefFormatInternal(virDomainDefPtr def, > > break; > > + case VIR_DOMAIN_FEATURE_HAP: > case VIR_DOMAIN_FEATURE_PMU: > case VIR_DOMAIN_FEATURE_PVSPINLOCK: > case VIR_DOMAIN_FEATURE_VMPORT: > diff --git a/docs/schemas/domaincommon.rng b/docs/schemas/domaincommon.rng index 89d3a6b..141122c 100644 --- a/docs/schemas/domaincommon.rng +++ b/docs/schemas/domaincommon.rng @@ -4132,9 +4132,7 @@ - - - +