xenlight: allow VMs to boot with empty CDROMs

Fixes #26

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
xenlight: enable emulated NICs (as well as PV)

libxl wants us to say NIC_TYPE_VIF_IOEMU to request both a VIF and
an emulated interface, rather than only NIC_TYPE_VIF.

Simplify the hotplug scripts: now that we're using the VM's uuid
it's easier to find the xenopsd state on disk -- there's no need
for a separate 'Interface' link table.

Fixes #25

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
Bump version to 0.9.12
Signed-off-by: David Scott <dave.scott@eu.citrix.com>
Share the Bootloader module across multiple backends

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
xenlight: PV NICs should be NIC_TYPE_VIF; HVM NICs should be NIC_TYPE_VIF_IOEMU

It's an error to request a NIC_TYPE_VIF_IOEMU for PV domains.
We want HVM domains always to have an emulated NIC in case the VM has
no PV drivers.

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
xenlight: use eliloader to install PV guests

Since eliloader uses a different argument passing convention to
pygrub, we simply run it first and then tell libxl that we have
a kernel and ramdisk in our hand.

Fixes #21

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
xenlight: fix deadlock in VM clean shutdown

Instead of calling down into libxl to perform a blocking wait (which
causes a deadlock with the background event thread) we block on
a condition variable in xenopsd itself, and have the existing background
shutdown event thread wake us up.

Fixes #27

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
Update to 0.9.13

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
xenlight: suspend and resume now work.

Note the bugfix to the ShutdownWatchers: we need to check whether
the domain has already shutdown before we block (forever)

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
Update to 0.9.14

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
Add a hacky workaround to choose between libxl disk types

We need to use PHY for things which really are block devices but
we can't tell. For now we assume 'xenstore_data=[]' implies block
device.

We need to use QDISK for things which are virtual network block
device things.

Proper fix depends on issue xcp-idl#8

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
Attack a frontend to dom0 for pygrub to use

Unfortunately pvgrub seems to be grub1 only, making it hard to use.

Fixes #29

Signed-off-by: David Scott <dave.scott@eu.citrix.com>
Update to 0.9.15

Signed-off-by: David Scott <dave.scott@eu.citrix.com>