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

[OSSTEST PATCH 1/4] Executive: Do not print "shared ... marked ready" when not shared



Signed-off-by: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
---
 Osstest/Executive.pm | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/Osstest/Executive.pm b/Osstest/Executive.pm
index e741f529..c3dc1261 100644
--- a/Osstest/Executive.pm
+++ b/Osstest/Executive.pm
@@ -1017,11 +1017,12 @@ sub executive_resource_shared_mark_ready ($$$) {
     my ($restype, $resname, $sharetype) = @_;
     # must run outside transaction
 
+    my $oldshr;
     my $what= "resource $restype $resname";
     $sharetype .= ' '.get_harness_rev();
 
     db_retry($dbh_tests, [qw(resources)], sub {
-        my $oldshr= resource_check_allocated_core($restype, $resname);
+        $oldshr= resource_check_allocated_core($restype, $resname);
         if (defined $oldshr) {
             die "$what shared $oldshr->{Type} not $sharetype"
                 unless $oldshr->{Type} eq $sharetype;
@@ -1053,7 +1054,11 @@ END
     }) {
        logm("post-mark-ready queue daemon prod failed: $@");
     }
-    logm("$restype $resname shared $sharetype marked ready");
+    if ($oldshr) {
+       logm("$restype $resname shared $sharetype marked ready");
+    } else {
+       logm("$restype $resname (not shared, $sharetype) is ready");
+    }
 }
 
 # hostalloc_maxwait_starvation
-- 
2.20.1




 


Rackspace

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