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

[Xen-devel] [PATCH OSSTEST] Toolstack::xl: Support for ACPI fallback for shutdown



HVM guests which do not include PV drivers will not shutdown after a
simple "xl shutdown". Add a runvar to indicate that the guest will
shutdown in response to an ACPI power event and apply this to the win7
and winxp test jobs.

Tested with:
    test-amd64-amd64-xl-qemuu-winxpsp3
    test-amd64-amd64-xl-qemuu-win7-amd64
    test-amd64-amd64-xl-qemuu-debianhvm-amd64
    test-amd64-amd64-xl

The first two correctly used the extra flag and the domains shutdown,
the other two correctly didn't use the extra flag and still shutdown.

Not currently implemented for libvirt, since we currently have no
libvirt tests I could try it with.

Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
---
 Osstest/Toolstack/xl.pm | 4 +++-
 make-flight             | 2 ++
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/Osstest/Toolstack/xl.pm b/Osstest/Toolstack/xl.pm
index 71aefd5..dd12ae1 100644
--- a/Osstest/Toolstack/xl.pm
+++ b/Osstest/Toolstack/xl.pm
@@ -55,7 +55,9 @@ sub shutdown_wait ($$$) {
     my ($self,$gho,$timeout) = @_;
     my $ho = $self->{Host};
     my $gn = $gho->{Name};
-    target_cmd_root($ho,"$self->{_Command} shutdown -w $gn", $timeout);
+    my $acpi_fallback = guest_var($gho,'acpi_shutdown','false') eq 'true'
+       ? "F" : "";
+    target_cmd_root($ho,"$self->{_Command} shutdown -w${acpi_fallback} $gn", 
$timeout);
 }
 
 sub migrate_check ($) {
diff --git a/make-flight b/make-flight
index 70c1900..202c68d 100755
--- a/make-flight
+++ b/make-flight
@@ -188,6 +188,7 @@ do_hvm_winxp_tests () {
             
test-$xenarch$kern-$dom0arch-$toolstack$qemuu_suffix-winxpsp3$vcpus_suffix \
             test-win $toolstack $xenarch $dom0arch $qemuu_runvar \
             win_image=winxpsp3.iso $vcpus_runvars   \
+            win_acpi_shutdown=true \
             all_hostflags=$most_hostflags,hvm
 
   done
@@ -201,6 +202,7 @@ do_hvm_win7_x64_tests () {
   job_create_test test-$xenarch$kern-$dom0arch-xl$qemuu_suffix-win7-amd64 \
             test-win xl $xenarch $dom0arch $qemuu_runvar \
             win_image=win7-x64.iso \
+            win_acpi_shutdown=true \
             all_hostflags=$most_hostflags,hvm
 }
 
-- 
2.1.4


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

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