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

Re: [Xen-devel] [PATCH V5 32/32] libxl: synchronize configuration when we plug / unplug device

Wei Liu writes ("[PATCH V5 32/32] libxl: synchronize configuration when we plug 
/ unplug device"):
> This approach cannot deal with half-baked device state (say, if AO
> returns success but for various reasons other parts just fail and we
> have some xenstore entries written / resource allocated). However we
> cannot make thing worse as the original code cannot handle that either.
> The good side of this approach is that in the future we can compare the
> stored configuration and xenstore entries to spot any half-baked device
> state so it can help fix that issue in the future.

I'm still concerned about this.

And seeing the code which results from doing it this way hasn't really
convinced me otherwise.  These macros are going to need to be adjusted

Wouldn't it be better to write something which can merge (a) the
information currently obtained by libxl_device_disk_list,
libxl__device_disk_from_xs_be et al and (b) the new JSON
configuration ?

Then you could arrange to add the device to the JSON config before
doing anything else, and remove it afterwards, and then there would be
no undesirable states etc.


Xen-devel mailing list



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