Re: [PATCH v2] ktest.pl: Fix combined usage of BISECT_REVERSE andBISECT_SKIP

From: Steven Rostedt
Date: Mon Apr 23 2012 - 20:55:42 EST


On Mon, 2012-04-23 at 16:15 -0700, Russ Dill wrote:
> When BISECT_REVERSE and BISECT_SKIP are used together with boot or test testing,
> build failures are treated as boot or test failures and 'git bisect bad' is executed instead
> of 'git bisect skip'. This is because the $ret value of -1 is treated as a build failure, but
> the $reverse_bisect logic does not properly handle this.
>
> Simple fix, don't invert $ret if it is -1.
>
> Signed-off-by: Russ Dill <Russ.Dill@xxxxxx>
> ---
> tools/testing/ktest/ktest.pl | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/tools/testing/ktest/ktest.pl b/tools/testing/ktest/ktest.pl
> index 95d6a6f..5221b00 100755
> --- a/tools/testing/ktest/ktest.pl
> +++ b/tools/testing/ktest/ktest.pl
> @@ -2192,7 +2192,7 @@ sub run_bisect {
> }
>
> # Are we looking for where it worked, not failed?
> - if ($reverse_bisect) {
> + if ($reverse_bisect && $ret != -1) {

Thanks! But can you resend with the following change:

... && $ret >= 0) {

Just incase we have $ret be another negative number for something else.

-- Steve

> $ret = !$ret;
> }
>


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/