CA-141364: Remove wasted hypercalls on domain build

The HPET and VPT are enabled or otherwise within Xenguest. Doing so here is
unnecessary.

Also, at the time of writing, the binding for VPT alignment is
setting the HPET again by mistake:

https://github.com/xapi-project/xen-api-libs-transitional/blob/d6cf85fd/xenctrlext/xenctrlext_stubs.c#L128-L135

These will be removed.

Signed-off-by: Si Beaumont <simon.beaumont@citrix.com>
CA-141364: Don't ignore errors from libxc on domain build

Failures from these calls are fatal and we should not continue with any VM
build (start, resume) operations if these calls return an error.

Signed-off-by: Si Beaumont <simon.beaumont@citrix.com>
CA-141364: Remove redundant (and erroneous bindings)

We no longer need these bindings since this work is done in Xenguest. Also, it
appears both of the bindings mistakenly make the same call into libxc.

Signed-off-by: Si Beaumont <simon.beaumont@citrix.com>
Merge pull request #103 from simonjbeaumont/ca-141364

CA-141364: Handle errors during domain build
Fix indentation in VM.remove

Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
Ensure that VM_remove destroys the internal task when done

Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
Ensure that the Device_common.get_private_path does not raise an exception

Also add some extra logging in Xenstore_watch.

Returning a random string on error is not very neat, but we must avoid exceptions here.
This patch must be followed soon by a patch that changes the callers of
get_private_path{_of_device} to call by UUID, so that this code can go away.

Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
Merge pull request #104 from robhoes/bvt

Ensure that the Device_common.get_private_path does not raise an exception
CP-9229: Use new path for convert-legacy-stream

The previous path (.../legacy.py) was a symlink for backwards compatibility
with development and we would like to remove it before release.

Signed-off-by: Si Beaumont <simon.beaumont@citrix.com>
Merge pull request #105 from simonjbeaumont/cp-9229

CP-9229: Use new path for convert-legacy-stream
vif script: look for bridge in backend/vif/<domid>/<devid>/bridge first

This is where libxl puts it. We fall back to the "private" location if not
there.

Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
xl: merge in device_common and hotplug changes from xc

This includes changes to support blktap3 (note that blktap3 would still need
changes in libxl if we want to use it).

Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
xl: write bridge-MAC

Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
vif-real: log UUID

Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
xc: move no-physical-device xs key to private (as in xl)

Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
xl: use classic hotplug scripts

Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
Cleanup shutdown cancel path after use

Since private xenstore paths are now UUID-based, a shutdown cancel path persist
across a localhost migration. This causes a following localhost migration to
fail: the cancel path that still exists causes the cancellable watch that waits
for the domain to ack the shutdown request to fire immediately, and cancel the
migration.

We solve this by moving all cancel-related xenstore keys out of the
"/xapi/<uuid>" tree and into its own domid-based xenstore tree. We then zap
this tree on domain destroy.

Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
Merge pull request #108 from robhoes/bvt

Cleanup shutdown cancel path after use
CA-142107: Enable verbose logging for convert-legacy-stream

Signed-off-by: Si Beaumont <simon.beaumont@citrix.com>
CA-142107: Log arguments before spawning convert-legacy-stream

Signed-off-by: Si Beaumont <simon.beaumont@citrix.com>