kernel_optimize_test/arch/um/drivers
Johannes Berg 7f8fd5dd43 um: chan_user: Fix winch_tramp() return value
commit 57ae0b67b747031bc41fb44643aa5344ab58607e upstream.

The previous fix here was only partially correct, it did
result in returning a proper error value in case of error,
but it also clobbered the pid that we need to return from
this function (not just zero for success).

As a result, it returned 0 here, but later this is treated
as a pid and used to kill the process, but since it's now
0 we kill(0, SIGKILL), which makes UML kill itself rather
than just the helper thread.

Fix that and make it more obvious by using a separate
variable for the pid.

Fixes: ccf1236ecac4 ("um: fix error return code in winch_tramp()")
Reported-and-tested-by: Nathan Chancellor <nathan@kernel.org>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Cc: stable@vger.kernel.org
Signed-off-by: Richard Weinberger <richard@nod.at>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-06-09 10:21:26 +02:00
..
chan_kern.c
chan_user.c um: chan_user: Fix winch_tramp() return value 2022-06-09 10:21:26 +02:00
chan_user.h
chan.h
cow_sys.h
cow_user.c
cow.h
daemon_kern.c
daemon_user.c um: Some fixes to build UML with musl 2020-10-11 23:13:06 +02:00
daemon.h
fd.c
harddog_kern.c
harddog_user.c
hostaudio_kern.c
Kconfig um: Allow static linking for non-glibc implementations 2020-10-11 23:13:15 +02:00
line.c
line.h
Makefile
mconsole_kern.c um: Fix uml_mconsole stop/go 2022-04-08 14:40:44 +02:00
mconsole_kern.h
mconsole_user.c
mconsole.h
mmapper_kern.c
net_kern.c
net_user.c
null.c
pcap_kern.c
pcap_user.c um: Some fixes to build UML with musl 2020-10-11 23:13:06 +02:00
pcap_user.h
port_kern.c
port_user.c
port.h
pty.c
random.c um: random: Register random as hwrng-core device 2021-01-06 14:56:55 +01:00
slip_common.c
slip_common.h
slip_kern.c
slip_user.c um: fix error return code in slip_open() 2021-07-20 16:05:51 +02:00
slip.h
slirp_kern.c
slirp_user.c
slirp.h
ssl.c
stderr_console.c
stdio_console.c
stdio_console.h
tty.c
ubd_kern.c um: ubd: Submit all data segments atomically 2021-01-06 14:56:55 +01:00
ubd_user.c
ubd.h
umcast_kern.c
umcast_user.c
umcast.h
vde_kern.c
vde_user.c
vde.h
vector_kern.c um: vector: Use GFP_ATOMIC under spin lock 2020-10-11 23:13:00 +02:00
vector_kern.h
vector_transports.c
vector_user.c um: vector: Add dynamic tap interfaces and scripting 2020-10-11 23:26:37 +02:00
vector_user.h
vhost_user.h
virtio_uml.c um: virtio_uml: Fix time-travel external time propagation 2022-01-27 10:53:59 +01:00
xterm_kern.c
xterm.c um: chan_xterm: Fix fd leak 2020-12-30 11:53:53 +01:00
xterm.h