diff options
| author | Atul Akella <atul.akella@gmail.com> | 2026-10-13 21:30:55 +0530 |
|---|---|---|
| committer | Mathieu Poirier <mathieu.poirier@linaro.org> | 2026-10-14 09:45:47 -0600 |
| commit | 7dd4cffdf4c2a496ccf783303a03d687a2127baf (patch) | |
| tree | c104a051971a3267264a1d5252a3deb9c5ccd729 /include/uapi/linux | |
| parent | 00e100cfbf7bc159e462df16832cddeaf2cab770 (diff) | |
| download | linux-7dd4cffdf4c2a496ccf783303a03d687a2127baf.tar.gz linux-7dd4cffdf4c2a496ccf783303a03d687a2127baf.zip | |
rpmsg: virtio: fix error handling in TX buffer wait
The TX buffer wait loop in rpmsg_send_offchannel_raw() ignores the
possibility of wait_event_interruptible_timeout() returning a
negative value, which happens when the wait is interrupted by a
signal. In that case the loop spins back around and re-arms the
wait instead of propagating the signal, which can stall a task
that is trying to be killed.
Separately, on a genuine timeout (return value 0) the function
returns -ERESTARTSYS, which is reserved for signal-interrupted
syscalls that the kernel may restart. A timeout is not a signal
and should not be treated as restartable; return -ETIMEDOUT
instead.
Handle both cases explicitly: return err directly when negative,
and return -ETIMEDOUT on timeout.
Fixes: bcabbccabffe ("rpmsg: add virtio-based remote processor messaging bus")
Signed-off-by: Atul Akella <atul.akella@gmail.com>
Link: https://lore.kernel.org/r/20261013160055.1362-1-atul.akella@gmail.com
Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Diffstat (limited to 'include/uapi/linux')
0 files changed, 0 insertions, 0 deletions
