diff --git a/tools/testing/ktest/ktest.pl b/tools/testing/ktest/ktest.pl index c518b0fb6d01..bf1398180785 100755 --- a/tools/testing/ktest/ktest.pl +++ b/tools/testing/ktest/ktest.pl @@ -2736,15 +2736,17 @@ sub bisect { run_command "git bisect start$start_files" or dodie "could not start bisect"; - run_command "git bisect good $good" or - dodie "could not set bisect good to $good"; - - run_git_bisect "git bisect bad $bad" or - dodie "could not set bisect bad to $bad"; - if (defined($replay)) { run_command "git bisect replay $replay" or dodie "failed to run replay"; + } else { + + run_command "git bisect good $good" or + dodie "could not set bisect good to $good"; + + run_git_bisect "git bisect bad $bad" or + dodie "could not set bisect bad to $bad"; + } if (defined($start)) {