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

Re: [Xen-devel] [PATCH v4 --for 4.6 COLOPre 05/25] libxl/remus: introduce libxl__remus_setup





On 07/15/2015 07:26 PM, Ian Campbell wrote:
On Wed, 2015-07-15 at 15:45 +0800, Yang Hongyang wrote:
Refactoring Remus setup by introducing libxl__remus_setup API.
All Remus setup work are done in this function.

Also remove the libxl__ prefix for static functions.

There is a subtle behavioural change here, which is that if anything
which is now done in _setup fails then the result is a call to
dss->callback( ..,..,ERROR_FAIL) rather than _start returning
AO_CREATE_FAIL(ERROR_FAIL).

I think this is probably a reasonable and correct change, but I think it
is worth mentioning in the commit log.

Yes, will update the commit log.


That said, I also wonder if the actual check for netbuffer_enabled (the
only such failure in practice) ought to be moved up such that it stays
in _start along with the other similar checks, i.e. _start would do:

     if (libxl_defbool_val(info->netbuf) && !libxl__netbuffer_enabled(gc)) {
             LOG(ERROR, "Remus: No support for network buffering");
             rc = ERROR_FAIL;
             goto out;
         }

This check is for Remus only, we want to reuse _start for COLO, so anything
related to Remus only should sit in libxl_remus.c.


while _setup would do:

     if (libxl_defbool_val(info->netbuf)) {
         // MAYBE : assert(libxl__netbuffer_enabled(gc))
         rds->device_kind_flags |= (1 << LIBXL__DEVICE_KIND_VIF);
     }

Ian.

.


--
Thanks,
Yang.

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.