From mboxrd@z Thu Jan 1 00:00:00 1970 From: Hollis Blanchard Subject: Re: [PATCH] Split kvm_vcpu to support new archs. Date: Thu, 18 Oct 2007 16:14:44 -0500 Message-ID: <1192742084.21205.22.camel@basalt> References: <42DFA526FC41B1429CE7279EF83C6BDC809A6A@pdsmsx415.ccr.corp.intel.com> <1192737702.21205.17.camel@basalt> <4717CA4B.7040307@codemonkey.ws> Reply-To: Hollis Blanchard Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org, kvm-ppc-devel , Avi Kivity , "Zhang, Xiantao" To: Anthony Liguori Return-path: In-Reply-To: <4717CA4B.7040307-rdkfGonbjUSkNkDKm+mE6A@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 On Thu, 2007-10-18 at 16:04 -0500, Anthony Liguori wrote: > Hollis Blanchard wrote: > > What is the problem with > > embedding an architecture-specific sub-structure, i.e. > > struct kvm_vcpu { > > ... > > struct arch_kvm_vcpu arch_vcpu; > > }; > > > > I think you want the opposite direction of nesting. ... > We should move to: > > struct kvm_vcpu { > /* stuff common to x86/ppc/ia64 */ > }; > > struct vcpu_x86 { > struct kvm_vcpu vcpu; > /* stuff common to vt/svm */ > } > > struct vcpu_svm { > struct vcpu_x86 vcpu; > /* svm specific stuff */ > }; Why? -- Hollis Blanchard IBM Linux Technology Center ------------------------------------------------------------------------- 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/