diff options
author | 2025-03-19 21:55:21 +0800 | |
---|---|---|
committer | 2025-03-20 09:26:38 +0100 | |
commit | d7f89a9da4328eee450d2e72631d1ec7e52976f0 (patch) | |
tree | 1740868208e3142829437a72dc91225a29b5b074 /arch/um/drivers/ubd.h | |
parent | um: Add pthread-based helper support (diff) | |
download | wireguard-linux-d7f89a9da4328eee450d2e72631d1ec7e52976f0.tar.xz wireguard-linux-d7f89a9da4328eee450d2e72631d1ec7e52976f0.zip |
um: ubd: Switch to the pthread-based helper
The ubd io thread and UML kernel thread share the same errno, which
can lead to conflicts when both call syscalls concurrently. Switch to
the pthread-based helper to address this issue.
Signed-off-by: Tiwei Bie <tiwei.btw@antgroup.com>
Link: https://patch.msgid.link/20250319135523.97050-3-tiwei.btw@antgroup.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'arch/um/drivers/ubd.h')
-rw-r--r-- | arch/um/drivers/ubd.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/um/drivers/ubd.h b/arch/um/drivers/ubd.h index f016fe15499f..2985c14661f4 100644 --- a/arch/um/drivers/ubd.h +++ b/arch/um/drivers/ubd.h @@ -7,8 +7,10 @@ #ifndef __UM_UBD_USER_H #define __UM_UBD_USER_H -extern int start_io_thread(unsigned long sp, int *fds_out); -extern int io_thread(void *arg); +#include <os.h> + +int start_io_thread(struct os_helper_thread **td_out, int *fd_out); +void *io_thread(void *arg); extern int kernel_fd; extern int ubd_read_poll(int timeout); |