Re: [Libvir] PATCH 9/9: Split out virBuffer from xml.c

2007-06-17 Thread Daniel P. Berrange
And with the patch attached this time... On Mon, Jun 18, 2007 at 03:30:11AM +0100, Daniel P. Berrange wrote: > The virBuffer functions are currently held in src/xml.c file. This patch > splits them out into a self-contained src/buf.c file. In combination with > the previous patch this will make th

Re: [Libvir] PATCH 8/9: Rename bufferNNN functions

2007-06-17 Thread Daniel P. Berrange
The subject was wrong last time. Doh. On Mon, Jun 18, 2007 at 03:27:03AM +0100, Daniel P. Berrange wrote: > The bufferNNN functions in the qemud/buf.c file are identical those already > present in the src/xml.c file, except the latter are named virBufferNNN. > This patch renames bufferNNN to virBu

Re: [Libvir] PATCH 9/9: Split out virBuffer from xml.c

2007-06-17 Thread Daniel P. Berrange
The virBuffer functions are currently held in src/xml.c file. This patch splits them out into a self-contained src/buf.c file. In combination with the previous patch this will make the move of QEMU code from qemud/ to src/ easier, since both dirs have identical buf.c/.h files now. b/src/buf.c

Re: [Libvir] PATCH 0/3: Refactor QEMU daemon

2007-06-17 Thread Daniel P. Berrange
The bufferNNN functions in the qemud/buf.c file are identical those already present in the src/xml.c file, except the latter are named virBufferNNN. This patch renames bufferNNN to virBufferNNN so that the two impls can be merged into one. No functional change buf.c| 42 +-- buf.h

Re: [Libvir] PATCH 7/9: Rename uuid functions

2007-06-17 Thread Daniel P. Berrange
The UUID functions in qemud/uuid.c have qemud_ in the name. They will be moved into the main src/ directory and so deserve a more generic name. This patch makes them use virUUID as a prefix. No functional change. conf.c |8 uuid.c | 16 uuid.h | 12 ++--

Re: [Libvir] PATCH 5/9: Adapt to virError API

2007-06-17 Thread Daniel P. Berrange
This patch switches the driver.c, conf.c and dispatch.c files over to use the virError object and associated API instead of a custom version. Makefile.am |5 + conf.c | 192 ++-- dispatch.c | 16 +++-- driver.c| 174 +++

Re: [Libvir] PATCH 4/9: Remove startup/reload handling into driver.c

2007-06-17 Thread Daniel P. Berrange
This patch moves a little more code dealing with VMs / networks out of the qemud.c file into the driver.c file. Specifically code to load configs at startup, code to re-load config files on SIGHUP, and some code to cleanup unused inactive VM / network config file structs. driver.c | 82 ++

Re: [Libvir] PATCH 0/3: Refactor QEMU daemon

2007-06-17 Thread Daniel P. Berrange
On Sun, Jun 17, 2007 at 10:48:17PM +0100, Daniel P. Berrange wrote: > The 3 patches which follow are work-in-progress to re-factor the QEMU > daemon / driver to eventually adhere to the main libvirt internal driver > API. Once this work is complete, there will only need to be a single > daemon runn

Re: [Libvir] PATCH 2/3: Move capabiities / nodeinfo code into driver.c

2007-06-17 Thread Daniel P. Berrange
In the main dispatcher.c file most methods simply call out into APIs in the driver.c or conf.c file. The capabilities and nodeinfo methods, however, containing their full logic in the dispatcher.c file. When the QEMU impl is switched to the generic driver model, the dispatcher.c file will be delet

Re: [Libvir] PATCH 1/3: Split out simple event loop

2007-06-17 Thread Daniel P. Berrange
The following patch adds a qemud/event.c & qemud/event.h file providing a general purpose event loop built around poll. Users register file handles and associated callbacks, and / or timers. The qemud.c file is changed to make use of these APIs for dealing with server, client, and VM file handles a

[Libvir] PATCH 0/3: Refactor QEMU daemon

2007-06-17 Thread Daniel P. Berrange
The 3 patches which follow are work-in-progress to re-factor the QEMU daemon / driver to eventually adhere to the main libvirt internal driver API. Once this work is complete, there will only need to be a single daemon running which can provide both remote & QEMU capabilities at once with no QEMU s

[Libvir] PATCH: Fix marshalling of ID on wire with remote

2007-06-17 Thread Daniel P. Berrange
THe code which marshalls virDomainptr objects onto the wire in the remote driver forgets to include the 'id' value. We get away with this for Xen and QEMU because they do most things based off name or UUID. The test driver however wants the ID number. The attached patch fixes this Dan -- |=- Re

[Libvir] Register libvirtd ports with IANA ?

2007-06-17 Thread Daniel P. Berrange
For the libvirtd we currently use two ports 16509 - TCP unencrypted stream 16514 - TLS encrypted stream My first thought is that we should really use consequetive port numbers eg 16510 and 16511. Second, we should register our port numbers with IANA http://www.iana.org/protocols/forms.