From mboxrd@z Thu Jan 1 00:00:00 1970 From: Olaf Hering Subject: Re: [PATCH v4] libxl: add option for discard support to xl disk configuration Date: Mon, 5 May 2014 16:35:07 +0200 Message-ID: <20140505143507.GA6377@aepfle.de> References: <1399298661-25947-1-git-send-email-olaf@aepfle.de> <20140505142713.GB3878@phenom.dumpdata.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <20140505142713.GB3878@phenom.dumpdata.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: Konrad Rzeszutek Wilk Cc: Stefano Stabellini , Ian Jackson , Ian Campbell , xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org On Mon, May 05, Konrad Rzeszutek Wilk wrote: > > +++ b/tools/libxl/libxlu_disk_l.l > > @@ -174,6 +174,10 @@ backendtype=[^,]*,? { STRIP(','); setbackendtype(DPC,FROMEQUALS); } > > vdev=[^,]*,? { STRIP(','); SAVESTRING("vdev", vdev, FROMEQUALS); } > > script=[^,]*,? { STRIP(','); SAVESTRING("script", script, FROMEQUALS); } > > direct-io-safe,? { DPC->disk->direct_io_safe = 1; } > > +discard=on,? { libxl_defbool_set(&DPC->disk->discard_enable, true); } > > +discard=1,? { libxl_defbool_set(&DPC->disk->discard_enable, true); } > > +discard=off,? { libxl_defbool_set(&DPC->disk->discard_enable, false); } > > +discard=0,? { libxl_defbool_set(&DPC->disk->discard_enable, false); } > > I think this automatically generated? Yes, bison/flex should be rerun after applying this change. > > + * backend driver should ignore the property if the property is set but > > + * the backing storage does not support the feature. > ? I think you want to say: "The backend driver should ignore the propery > if the backing storage does not expose this functionality." That would be ok as well, if your version is better english anyway. Olaf