* [for-next][PATCH 0/2] ktest: Added CLOSE_CONSOLE_SIGNAL
@ 2013-12-03 17:07 Steven Rostedt
2013-12-03 17:07 ` [for-next][PATCH 1/2] ktest: Make the signal to terminate the console configurable Steven Rostedt
2013-12-03 17:07 ` [for-next][PATCH 2/2] ktest: Add documentation of CLOSE_CONSOLE_SIGNAL Steven Rostedt
0 siblings, 2 replies; 3+ messages in thread
From: Steven Rostedt @ 2013-12-03 17:07 UTC (permalink / raw)
To: linux-kernel; +Cc: Andrew Morton
ktest updates for linux-next.
git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-ktest.git
for-next
Head SHA1: 298a0d1d575026edec7fbb9b7e8cbb8fe18498cd
Satoru Takeuchi (1):
ktest: Make the signal to terminate the console configurable
Steven Rostedt (Red Hat) (1):
ktest: Add documentation of CLOSE_CONSOLE_SIGNAL
----
tools/testing/ktest/ktest.pl | 5 ++++-
tools/testing/ktest/sample.conf | 7 +++++++
2 files changed, 11 insertions(+), 1 deletion(-)
^ permalink raw reply [flat|nested] 3+ messages in thread* [for-next][PATCH 1/2] ktest: Make the signal to terminate the console configurable 2013-12-03 17:07 [for-next][PATCH 0/2] ktest: Added CLOSE_CONSOLE_SIGNAL Steven Rostedt @ 2013-12-03 17:07 ` Steven Rostedt 2013-12-03 17:07 ` [for-next][PATCH 2/2] ktest: Add documentation of CLOSE_CONSOLE_SIGNAL Steven Rostedt 1 sibling, 0 replies; 3+ messages in thread From: Steven Rostedt @ 2013-12-03 17:07 UTC (permalink / raw) To: linux-kernel; +Cc: Andrew Morton, Satoru Takeuchi [-- Attachment #1: 0001-ktest-Make-the-signal-to-terminate-the-console-confi.patch --] [-- Type: text/plain, Size: 1983 bytes --] From: Satoru Takeuchi <satoru.takeuchi@gmail.com> Currently ktest sends SIGINT to terminate the console. However, there are consoles which do not exit by this signal, for example, in my case, "virsh console <guest OS>". In such case, ktest is blocked in close_console(). It prevents this automate test. This patch adds new option CLOSE_CONSOLE_SIGNAL which mean the signal to terminate the console. Since its default value is "INT", the original behavior isn't changed. Link: http://lkml.kernel.org/r/87zjol8pl5.wl%satoru.takeuchi@gmail.com Signed-off-by: Satoru Takeuchi <satoru.takeuchi@gmail.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> --- tools/testing/ktest/ktest.pl | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tools/testing/ktest/ktest.pl b/tools/testing/ktest/ktest.pl index 0d7fd8b..5dc5704 100755 --- a/tools/testing/ktest/ktest.pl +++ b/tools/testing/ktest/ktest.pl @@ -25,6 +25,7 @@ my %default = ( "TEST_TYPE" => "build", "BUILD_TYPE" => "randconfig", "MAKE_CMD" => "make", + "CLOSE_CONSOLE_SIGNAL" => "INT", "TIMEOUT" => 120, "TMP_DIR" => "/tmp/ktest/\${MACHINE}", "SLEEP_TIME" => 60, # sleep time between tests @@ -163,6 +164,7 @@ my $timeout; my $booted_timeout; my $detect_triplefault; my $console; +my $close_console_signal; my $reboot_success_line; my $success_line; my $stop_after_success; @@ -285,6 +287,7 @@ my %option_map = ( "TIMEOUT" => \$timeout, "BOOTED_TIMEOUT" => \$booted_timeout, "CONSOLE" => \$console, + "CLOSE_CONSOLE_SIGNAL" => \$close_console_signal, "DETECT_TRIPLE_FAULT" => \$detect_triplefault, "SUCCESS_LINE" => \$success_line, "REBOOT_SUCCESS_LINE" => \$reboot_success_line, @@ -1296,7 +1299,7 @@ sub close_console { my ($fp, $pid) = @_; doprint "kill child process $pid\n"; - kill 2, $pid; + kill $close_console_signal, $pid; print "closing!\n"; close($fp); -- 1.8.4.rc3 ^ permalink raw reply [flat|nested] 3+ messages in thread
* [for-next][PATCH 2/2] ktest: Add documentation of CLOSE_CONSOLE_SIGNAL 2013-12-03 17:07 [for-next][PATCH 0/2] ktest: Added CLOSE_CONSOLE_SIGNAL Steven Rostedt 2013-12-03 17:07 ` [for-next][PATCH 1/2] ktest: Make the signal to terminate the console configurable Steven Rostedt @ 2013-12-03 17:07 ` Steven Rostedt 1 sibling, 0 replies; 3+ messages in thread From: Steven Rostedt @ 2013-12-03 17:07 UTC (permalink / raw) To: linux-kernel; +Cc: Andrew Morton, Satoru Takeuchi [-- Attachment #1: 0002-ktest-Add-documentation-of-CLOSE_CONSOLE_SIGNAL.patch --] [-- Type: text/plain, Size: 1032 bytes --] From: "Steven Rostedt (Red Hat)" <rostedt@goodmis.org> The sample.conf file needs to document all available options. With the new CLOSE_CONSOE_SIGNAL option, it too needs to be document. Cc: Satoru Takeuchi <satoru.takeuchi@gmail.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org> --- tools/testing/ktest/sample.conf | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/tools/testing/ktest/sample.conf b/tools/testing/ktest/sample.conf index 0a290fb..2eb4bd2 100644 --- a/tools/testing/ktest/sample.conf +++ b/tools/testing/ktest/sample.conf @@ -328,6 +328,13 @@ # For a virtual machine with guest name "Guest". #CONSOLE = virsh console Guest +# Signal to send to kill console. +# ktest.pl will create a child process to monitor the console. +# When the console is finished, ktest will kill the child process +# with this signal. +# (default INT) +#CLOSE_CONSOLE_SIGNAL = HUP + # Required version ending to differentiate the test # from other linux builds on the system. #LOCALVERSION = -test -- 1.8.4.rc3 ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-12-03 17:08 UTC | newest] Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2013-12-03 17:07 [for-next][PATCH 0/2] ktest: Added CLOSE_CONSOLE_SIGNAL Steven Rostedt 2013-12-03 17:07 ` [for-next][PATCH 1/2] ktest: Make the signal to terminate the console configurable Steven Rostedt 2013-12-03 17:07 ` [for-next][PATCH 2/2] ktest: Add documentation of CLOSE_CONSOLE_SIGNAL Steven Rostedt
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox
Powered by JetHome