Commit 3410f6fd5e3e96de4b557a62b7a2fbf19d74b1cd
Committed by
Steven Rostedt
1 parent
c23dca7cd2
Exists in
master
and in
4 other branches
ktest: Add BISECT_FILES to run git bisect on paths
Add the config option BISECT_FILES that allows the user to specify what path in the kernel to run the git bisect on. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Showing 2 changed files with 17 additions and 1 deletions Side-by-side Diff
tools/testing/ktest/ktest.pl
... | ... | @@ -1280,7 +1280,14 @@ |
1280 | 1280 | my $type = $opt{"BISECT_TYPE[$i]"}; |
1281 | 1281 | my $start = $opt{"BISECT_START[$i]"}; |
1282 | 1282 | my $replay = $opt{"BISECT_REPLAY[$i]"}; |
1283 | + my $start_files = $opt{"BISECT_FILES[$i]"}; | |
1283 | 1284 | |
1285 | + if (defined($start_files)) { | |
1286 | + $start_files = " -- " . $start_files; | |
1287 | + } else { | |
1288 | + $start_files = ""; | |
1289 | + } | |
1290 | + | |
1284 | 1291 | # convert to true sha1's |
1285 | 1292 | $good = get_sha1($good); |
1286 | 1293 | $bad = get_sha1($bad); |
... | ... | @@ -1333,7 +1340,7 @@ |
1333 | 1340 | die "Failed to checkout $head"; |
1334 | 1341 | } |
1335 | 1342 | |
1336 | - run_command "git bisect start" or | |
1343 | + run_command "git bisect start$start_files" or | |
1337 | 1344 | dodie "could not start bisect"; |
1338 | 1345 | |
1339 | 1346 | run_command "git bisect good $good" or |
tools/testing/ktest/sample.conf
... | ... | @@ -528,6 +528,15 @@ |
528 | 528 | # when something other than the BISECT_TYPE fails, ktest.pl will |
529 | 529 | # run "git bisect skip" and try again. |
530 | 530 | # |
531 | +# BISECT_FILES = <path> (optional, default undefined) | |
532 | +# | |
533 | +# To just run the git bisect on a specific path, set BISECT_FILES. | |
534 | +# For example: | |
535 | +# | |
536 | +# BISECT_FILES = arch/x86 kernel/time | |
537 | +# | |
538 | +# Will run the bisect with "git bisect start -- arch/x86 kernel/time" | |
539 | +# | |
531 | 540 | # BISECT_REVERSE = 1 (optional, default 0) |
532 | 541 | # |
533 | 542 | # In those strange instances where it was broken forever |