From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH 1/4] vmx: pass vcpu_vmx internally Date: Mon, 30 Jul 2007 12:02:01 +0300 Message-ID: <46ADA909.6070100@qumranet.com> References: <1185777103.12151.147.camel@localhost.localdomain> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel To: Rusty Russell Return-path: In-Reply-To: <1185777103.12151.147.camel-bi+AKbBUZKY6gyzm1THtWbp2dZbC/Bob@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org Rusty Russell wrote: > container_of is wonderful, but not casting at all is better. This > patch changes vmx.c's internal functions to pass "struct vcpu_vmx" > instead of "struct kvm_vcpu" and using container_of. > > @@ -1297,9 +1288,9 @@ static void seg_setup(int seg) > /* > * Sets up the vmcs for emulated real mode. > */ > -static int vmx_vcpu_setup(struct kvm_vcpu *vcpu) > -{ > - struct vcpu_vmx *vmx = to_vmx(vcpu); > +static int vmx_vcpu_setup(struct vcpu_vmx *vmx) > +{ > + > u32 host_sysenter_cs; > u32 junk; > unsigned long a; > I fixed this up manually and applied. Please watch for these in the future. -- error compiling committee.c: too many arguments to function ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/