Date: Tue, 24 Oct 2023 18:36:55 GMT From: John Baldwin <jhb@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: git: 83a00a92dab0 - stable/14 - Move kern_extattr_* prototypes to <sys/syscallsubr.h> Message-ID: <202310241836.39OIatX0087334@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch stable/14 has been updated by jhb: URL: https://cgit.FreeBSD.org/src/commit/?id=83a00a92dab019a4f4cd413c2a2b79f861ec0788 commit 83a00a92dab019a4f4cd413c2a2b79f861ec0788 Author: John Baldwin <jhb@FreeBSD.org> AuthorDate: 2023-09-08 23:36:28 +0000 Commit: John Baldwin <jhb@FreeBSD.org> CommitDate: 2023-10-24 17:00:57 +0000 Move kern_extattr_* prototypes to <sys/syscallsubr.h> All of the kern_* prototypes belong in this header. While here, sort the prototypes by function name. Reviewed by: dchagin Fixes: 6453d4240f6b vfs: Export exattr methods to reuse by Linuxulator Sponsored by: DARPA Differential Revision: https://reviews.freebsd.org/D41766 (cherry picked from commit 3555be0124a4f105c72d932f00071f332691e8cf) --- sys/kern/vfs_extattr.c | 1 + sys/sys/extattr.h | 22 ---------------------- sys/sys/syscallsubr.h | 20 ++++++++++++++++++++ 3 files changed, 21 insertions(+), 22 deletions(-) diff --git a/sys/kern/vfs_extattr.c b/sys/kern/vfs_extattr.c index e178589067c1..dc1bbb58644b 100644 --- a/sys/kern/vfs_extattr.c +++ b/sys/kern/vfs_extattr.c @@ -43,6 +43,7 @@ #include <sys/vnode.h> #include <sys/proc.h> #include <sys/extattr.h> +#include <sys/syscallsubr.h> #include <security/audit/audit.h> #include <security/mac/mac_framework.h> diff --git a/sys/sys/extattr.h b/sys/sys/extattr.h index a6689c869c0c..a16ef238656f 100644 --- a/sys/sys/extattr.h +++ b/sys/sys/extattr.h @@ -62,33 +62,11 @@ #ifdef _KERNEL #include <sys/types.h> -enum uio_seg; -struct uio; struct thread; struct ucred; struct vnode; int extattr_check_cred(struct vnode *vp, int attrnamespace, struct ucred *cred, struct thread *td, accmode_t accmode); -int kern_extattr_set_path(struct thread *td, const char *path, - int attrnamespace, const char *attrname, void *data, - size_t nbytes, int follow, enum uio_seg pathseg); -int kern_extattr_set_fd(struct thread *td, int fd, int attrnamespace, - const char *attrname, void *data, size_t nbytes); -int kern_extattr_get_path(struct thread *td, const char *path, - int attrnamespace, const char *attrname, void *data, - size_t nbytes, int follow, enum uio_seg pathseg); -int kern_extattr_get_fd(struct thread *td, int fd, int attrnamespace, - const char *attrname, void *data, size_t nbytes); -int kern_extattr_delete_path(struct thread *td, const char *path, - int attrnamespace, const char *attrname, int follow, - enum uio_seg pathseg); -int kern_extattr_delete_fd(struct thread *td, int fd, int attrnamespace, - const char *attrname); -int kern_extattr_list_path(struct thread *td, const char *path, - int attrnamespace, struct uio *auiop, int follow, - enum uio_seg pathseg); -int kern_extattr_list_fd(struct thread *td, int fd, int attrnamespace, - struct uio *auiop); #else #include <sys/cdefs.h> diff --git a/sys/sys/syscallsubr.h b/sys/sys/syscallsubr.h index 8be860dc0fd4..0480eda2fca4 100644 --- a/sys/sys/syscallsubr.h +++ b/sys/sys/syscallsubr.h @@ -139,6 +139,26 @@ int kern_cpuset_setid(struct thread *td, cpuwhich_t which, int kern_dup(struct thread *td, u_int mode, int flags, int old, int new); int kern_execve(struct thread *td, struct image_args *args, struct mac *mac_p, struct vmspace *oldvmspace); +int kern_extattr_delete_fd(struct thread *td, int fd, int attrnamespace, + const char *attrname); +int kern_extattr_delete_path(struct thread *td, const char *path, + int attrnamespace, const char *attrname, int follow, + enum uio_seg pathseg); +int kern_extattr_get_fd(struct thread *td, int fd, int attrnamespace, + const char *attrname, void *data, size_t nbytes); +int kern_extattr_get_path(struct thread *td, const char *path, + int attrnamespace, const char *attrname, void *data, + size_t nbytes, int follow, enum uio_seg pathseg); +int kern_extattr_list_fd(struct thread *td, int fd, int attrnamespace, + struct uio *auiop); +int kern_extattr_list_path(struct thread *td, const char *path, + int attrnamespace, struct uio *auiop, int follow, + enum uio_seg pathseg); +int kern_extattr_set_fd(struct thread *td, int fd, int attrnamespace, + const char *attrname, void *data, size_t nbytes); +int kern_extattr_set_path(struct thread *td, const char *path, + int attrnamespace, const char *attrname, void *data, + size_t nbytes, int follow, enum uio_seg pathseg); int kern_fchmodat(struct thread *td, int fd, const char *path, enum uio_seg pathseg, mode_t mode, int flag); int kern_fchownat(struct thread *td, int fd, const char *path,
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202310241836.39OIatX0087334>