Our implementation of the Xen driver doesn't support autostart[*]. However xen_unified.c has a loop for get/setAutostart which causes it to return an error without setting virterror first. This patch removes that loop.
Rich.[*] Although Xen supports it, by putting files in /etc/xen/autostart/ (at least that was the "old Xen" way before the current insanity of getting rid of config files was invented).
-- Emerging Technologies, Red Hat - http://et.redhat.com/~rjones/ Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SL4 1TE, United Kingdom. Registered in England and Wales under Company Registration No. 03798903
Index: src/xen_unified.c =================================================================== RCS file: /data/cvs/libvirt/src/xen_unified.c,v retrieving revision 1.12 diff -u -r1.12 xen_unified.c --- src/xen_unified.c 20 Jun 2007 17:25:39 -0000 1.12 +++ src/xen_unified.c 22 Jun 2007 13:04:39 -0000 @@ -783,34 +783,6 @@ return -1; } -static int -xenUnifiedDomainGetAutostart (virDomainPtr dom, int *autostart) -{ - GET_PRIVATE(dom->conn); - int i; - - for (i = 0; i < XEN_UNIFIED_NR_DRIVERS; ++i) - if (priv->opened[i] && drivers[i]->domainGetAutostart && - drivers[i]->domainGetAutostart (dom, autostart) == 0) - return 0; - - return -1; -} - -static int -xenUnifiedDomainSetAutostart (virDomainPtr dom, int autostart) -{ - GET_PRIVATE(dom->conn); - int i; - - for (i = 0; i < XEN_UNIFIED_NR_DRIVERS; ++i) - if (priv->opened[i] && drivers[i]->domainSetAutostart && - drivers[i]->domainSetAutostart (dom, autostart) == 0) - return 0; - - return -1; -} - static char * xenUnifiedDomainGetSchedulerType (virDomainPtr dom, int *nparams) { @@ -912,8 +884,6 @@ .domainUndefine = xenUnifiedDomainUndefine, .domainAttachDevice = xenUnifiedDomainAttachDevice, .domainDetachDevice = xenUnifiedDomainDetachDevice, - .domainGetAutostart = xenUnifiedDomainGetAutostart, - .domainSetAutostart = xenUnifiedDomainSetAutostart, .domainGetSchedulerType = xenUnifiedDomainGetSchedulerType, .domainGetSchedulerParameters = xenUnifiedDomainGetSchedulerParameters, .domainSetSchedulerParameters = xenUnifiedDomainSetSchedulerParameters,
Attachment:
smime.p7s
Description: S/MIME Cryptographic Signature