From mboxrd@z Thu Jan 1 00:00:00 1970 From: Boris Ostrovsky Subject: Re: [PATCH] x86/HVM: type adjustments Date: Mon, 23 Nov 2015 10:47:41 -0500 Message-ID: <5653351D.2010902@oracle.com> References: <565327EF02000078000B7DA6@prv-mh.provo.novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1a0tLF-0001N7-NV for xen-devel@lists.xenproject.org; Mon, 23 Nov 2015 15:47:45 +0000 In-Reply-To: <565327EF02000078000B7DA6@prv-mh.provo.novell.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: Jan Beulich , xen-devel Cc: Kevin Tian , Keir Fraser , suravee.suthikulpanit@amd.com, Andrew Cooper , Aravind Gopalakrishnan , Jun Nakajima List-Id: xen-devel@lists.xenproject.org On 11/23/2015 08:51 AM, Jan Beulich wrote: > - constify struct hvm_trap * function parameters > - width reduce and shuffle some struct hvm_trap members > - use bool_t for boolean fields struct hvm_function_table > - use unsigned for struct hvm_function_table's hap_capabilities field > > Signed-off-by: Jan Beulich > > --- a/xen/arch/x86/hvm/svm/svm.c > +++ b/xen/arch/x86/hvm/svm/svm.c > @@ -1181,7 +1181,7 @@ static void svm_vcpu_destroy(struct vcpu > passive_domain_destroy(v); > } > > -static void svm_inject_trap(struct hvm_trap *trap) > +static void svm_inject_trap(const struct hvm_trap *trap) > { > struct vcpu *curr = current; > struct vmcb_struct *vmcb = curr->arch.hvm_svm.vmcb; > @@ -1442,7 +1442,7 @@ const struct hvm_function_table * __init > if ( !printed ) > printk(" - none\n"); > > - svm_function_table.hap_supported = cpu_has_svm_npt; > + svm_function_table.hap_supported = !!cpu_has_svm_npt; Reviewed-by: Boris Ostrovsky (Should we redefine constant_test_bit/variable_test_bit (which is what cpu_has_* is) to return bool_t?) -boris