From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wei Liu Subject: Re: [RFC PATCH] libxl: basic virtio disk / nic configuration support. Date: Sat, 30 Jul 2011 10:40:23 +0800 Message-ID: <20110730024023.GC2303@limbo> References: <1311818929.1800.21.camel@limbo> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Stefano Stabellini Cc: Ian Campbell , "xen-devel@lists.xensource.com" , Ian Jackson List-Id: xen-devel@lists.xenproject.org On Thu, Jul 28, 2011 at 02:05:08PM +0100, Stefano Stabellini wrote: > > I think you need to add a new field in libxl_device_disk to specify the > protocol, something like libxl_disk_protocol, that can be: > > LIBXL_DISK_PROTOCOL_XENVBD > LIBXL_DISK_PROTOCOL_VIRTIO > > then parse_disk_config can be modified to distinguish xen disks from > virtio disks and set the field accordingly. Hmm... wait... Adding this field is easy. But I don't know if I fully understand your idea. I am just about to modify the parser. But looking back your replay, you are not suggesting adding configuration syntax support in config file (sort of `disk=["...,protocol=virito"]`). So essentially the new patch will be of no difference to the original one. But one advantage is that your plan seems cleaner (not exposing hacks to other functions). Do I get your point? Wei.