From b3fb473977c6bfb5294f229336a23d2071d565f8 Mon Sep 17 00:00:00 2001 From: Ian Moffett Date: Tue, 29 Jul 2025 01:41:19 -0400 Subject: kernel: uio: Add iovec copyin/copyout routines Introduce copyin() and copyout() type functions made for iovec/uio operation. Signed-off-by: Ian Moffett --- sys/include/sys/uio.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'sys/include') diff --git a/sys/include/sys/uio.h b/sys/include/sys/uio.h index d1d4c65..4318a53 100644 --- a/sys/include/sys/uio.h +++ b/sys/include/sys/uio.h @@ -48,4 +48,11 @@ struct iovec { ssize_t readv(int filedes, const struct iovec *iov, int iovcnt); ssize_t writev(int filedes, const struct iovec *iov, int iovcnt); +#if defined(_KERNEL) + +int uio_copyin(const struct iovec *u_iov, struct iovec *k_iov, int iovcnt); +int uio_copyout(const struct iovec *k_iov, struct iovec *u_iov, int iovcnt); +void uio_copyin_clean(struct iovec *copy, int iovcnt); + +#endif /* _KERNEL */ #endif /* !_SYS_UIO_H_ */ -- cgit v1.2.3