Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 275170
b: refs/heads/master
c: 4ab1cce
h: refs/heads/master
v: v3
  • Loading branch information
Steven Rostedt authored and Steven Rostedt committed Oct 17, 2011
1 parent b85c6c5 commit fe060f1
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 2b803365a6fa177ea7e1f64f645be1cb5dd39d55
refs/heads/master: 4ab1cce5bdd87948b75ed4fe4a8629c0f76267ae
22 changes: 20 additions & 2 deletions trunk/tools/testing/ktest/ktest.pl
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,9 @@
my %variable;
my %force_config;

# do not force reboots on config problems
my $no_reboot = 1;

$config_help{"MACHINE"} = << "EOF"
The machine hostname that you will test.
EOF
Expand Down Expand Up @@ -640,7 +643,7 @@ sub reboot {
sub do_not_reboot {
my $i = $iteration;

return $test_type eq "build" ||
return $test_type eq "build" || $no_reboot ||
($test_type eq "patchcheck" && $opt{"PATCHCHECK_TYPE[$i]"} eq "build") ||
($test_type eq "bisect" && $opt{"BISECT_TYPE[$i]"} eq "build");
}
Expand Down Expand Up @@ -1285,6 +1288,10 @@ sub build {

unlink $buildlog;

# Failed builds should not reboot the target
my $save_no_reboot = $no_reboot;
$no_reboot = 1;

if (defined($pre_build)) {
my $ret = run_command $pre_build;
if (!$ret && defined($pre_build_die) &&
Expand Down Expand Up @@ -1353,10 +1360,15 @@ sub build {

if (!$build_ret) {
# bisect may need this to pass
return 0 if ($in_bisect);
if ($in_bisect) {
$no_reboot = $save_no_reboot;
return 0;
}
fail "failed build" and return 0;
}

$no_reboot = $save_no_reboot;

return 1;
}

Expand Down Expand Up @@ -2806,6 +2818,9 @@ sub set_test_option {
# First we need to do is the builds
for (my $i = 1; $i <= $opt{"NUM_TESTS"}; $i++) {

# Do not reboot on failing test options
$no_reboot = 1;

$iteration = $i;

my $makecmd = set_test_option("MAKE_CMD", $i);
Expand Down Expand Up @@ -2941,6 +2956,9 @@ sub set_test_option {
die "failed to checkout $checkout";
}

$no_reboot = 0;


if ($test_type eq "bisect") {
bisect $i;
next;
Expand Down

0 comments on commit fe060f1

Please sign in to comment.