WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [PATCH 17 of 24] libxl: add libxl__spawn_confirm_offspri

To: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH 17 of 24] libxl: add libxl__spawn_confirm_offspring_startup
From: Olaf Hering <olaf@xxxxxxxxx>
Date: Wed, 26 Oct 2011 18:30:26 +0200
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Wed, 26 Oct 2011 09:31:12 -0700
Dkim-signature: v=1; a=rsa-sha1; c=relaxed/relaxed; t=1319646631; l=1346; s=domk; d=aepfle.de; h=In-Reply-To:Content-Type:MIME-Version:References:Subject:Cc:To:From: Date:X-RZG-CLASS-ID:X-RZG-AUTH; bh=cJHzT8NOmCD/usDFKJ1X0h8yPFw=; b=DcbhRYcilcFrMCQNfQhHwsjCv/uMLZGS1GnZa/K9GSgKYJF1b7rcZwuZL+kbgkdjJyH Z67yECuIthcxsvanfVB+/Iu6iR4TGPnqCZ2ia6IV3Jab0MV3swzIfPBdmBAqOVQ7a87+/ sKs2Ks5ITiCdi0aWoj8wqi1aigoVbQIu1w0=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <20134.63407.291964.492321@xxxxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <patchbomb.1317657277@xxxxxxxxxxxx> <018f63b6e4863faca16a.1317657294@xxxxxxxxxxxx> <20134.54883.620815.989672@xxxxxxxxxxxxxxxxxxxxxxxx> <20111025172159.GA11571@xxxxxxxxx> <20134.63407.291964.492321@xxxxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.21.rev5535 (2011-07-01)
On Tue, Oct 25, Ian Jackson wrote:

> Olaf Hering writes ("Re: [Xen-devel] [PATCH 17 of 24] libxl: add 
> libxl__spawn_confirm_offspring_startup"):
> > On Tue, Oct 25, Ian Jackson wrote:
> > > Olaf Hering writes ("[Xen-devel] [PATCH 17 of 24] libxl: add 
> > > libxl__spawn_confirm_offspring_startup"):
> > > > libxl: add libxl__spawn_confirm_offspring_startup
> > > > 
> > > > libxl__spawn_confirm_offspring_startup() is a generic version of
> > > > libxl__confirm_device_model_startup().
> > > 
> > > Thanks but I think it would be better to refactor this to avoid the
> > > duplication of this code.
> > 
> > The new function is used in patch #18 of this series.
> > Or do you have some other changes in mind?
> 
> I mean that you should arrange to replace
> libxl__confirm_device_model_startup with your new function
> libxl__spawn_confirm_offspring_startup.
> 
> As it is you have made a copy of libxl__confirm_device_model_startup
> and lightly edited it.  This is a cardinal sin in programming, known
> as "clone and hack".

I moved the device model specific functions and made them generic.
Perhaps I should have merged the add+use patches (15+16 / 17+18) into a
single change. Once all patches are applied I see no code duplication.

If you prefer I can send a series just for the spawn related changes in
libxl.


Olaf

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel

<Prev in Thread] Current Thread [Next in Thread>