ktest.pl: Give back console on Ctrt^C on monitor
authorSteven Rostedt <rostedt@goodmis.org>
Wed, 18 Jan 2023 21:32:13 +0000 (16:32 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 10 Mar 2023 08:34:26 +0000 (09:34 +0100)
commit76c2ecaf570a0a752586f324f81610c37340701d
tree9c6ed311502063ef1af8bdce02890fe9a5d0a431
parent71946389a765d68df48a343eb70da892c9075f16
ktest.pl: Give back console on Ctrt^C on monitor

commit 83d29d439cd3ef23041570d55841f814af2ecac0 upstream.

When monitoring the console output, the stdout is being redirected to do
so. If Ctrl^C is hit during this mode, the stdout is not back to the
console, the user does not see anything they type (no echo).

Add "end_monitor" to the SIGINT interrupt handler to give back the console
on Ctrl^C.

Cc: stable@vger.kernel.org
Fixes: 9f2cdcbbb90e7 ("ktest: Give console process a dedicated tty")
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
tools/testing/ktest/ktest.pl