[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [PATCH v4 10/13] Implement driver interface domainSetMemoryParamters for LXC



On Wed, Oct 13, 2010 at 11:07:47AM +0530, Nikunj A. Dadhania wrote:
> On Tue, 12 Oct 2010 18:32:19 +0200, Daniel Veillard <veillard redhat com> wrote:
> > On Fri, Oct 08, 2010 at 05:46:28PM +0530, Nikunj A. Dadhania wrote:
> > > From: Nikunj A. Dadhania <nikunj linux vnet ibm com>
> > > 
> > > Add support in the lxc driver for various memory controllable parameters
> > > 
> > > v4:
> > > + prototype change: add unsigned int flags
> > > 
> > > v2:
> > > + Use #define string constants for "hard_limit", etc
> > > + fix typo: min_guarantee
> > > 
> > > Acked-by: "Daniel P. Berrange" <berrange redhat com>
> > > Signed-off-by: Nikunj A. Dadhania <nikunj linux vnet ibm com>
> [...]
> > > +    if (vm == NULL) {
> > > +        char uuidstr[VIR_UUID_STRING_BUFLEN];
> > > +        virUUIDFormat(dom->uuid, uuidstr);
> > > +        lxcError(VIR_ERR_NO_DOMAIN,
> > > +                 _("No domain with matching uuid '%s'"), uuidstr);
> > > +        goto cleanup;
> > > +    }
> > 
> >   Hum, the qemu driver was reporting
> > 
> >     if (vm == NULL) {
> >         qemuReportError(VIR_ERR_INTERNAL_ERROR,
> >         _("No such domain %s"), dom->uuid);
> >         goto cleanup;
> >     }
> > 
> > the 2 should be harmonized I guess, but since the LXC reporting is better
> > I left this as a TODO, seems that's a more general cleanup needed between
> > drivers.
> > 
> Let me look at this and I will provide a patch.

  Probably too complex and outside the scope of this patch, I would
rather prefer if you focused on the documentation patch(es) still needed
at this point,

> >   Same problem of error reporting as in the QEmu driver, I moved ret = 0;
> > before the loop and et ret = -1; on all errors !
> >
> One clarification:
> Will it return error back immediately if an error occurs?

  No

> Or will it try setting all of them one by one and if anyone of them succeed,
> success is returned.

  Check the code from git ! It will try all of them. If any of them
  fails it will return an error.

Daniel

-- 
Daniel Veillard      | libxml Gnome XML XSLT toolkit  http://xmlsoft.org/
daniel veillard com  | Rpmfind RPM search engine http://rpmfind.net/
http://veillard.com/ | virtualization library  http://libvirt.org/


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]