aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWarner Losh <imp@bsdimp.com>2023-08-13 10:41:53 +0200
committerWarner Losh <imp@bsdimp.com>2023-08-28 12:16:18 -0600
commit97a3c571147c3b62a79a994ebd85769419e630c2 (patch)
tree74f898ad1f344aa8e45bc0d1d47d416621b62aa0
parentd7e9a545084ba1ded8fe864697db174cc3e6ebe2 (diff)
downloadqemu-97a3c571147c3b62a79a994ebd85769419e630c2.zip
qemu-97a3c571147c3b62a79a994ebd85769419e630c2.tar.gz
qemu-97a3c571147c3b62a79a994ebd85769419e630c2.tar.bz2
bsd-user: Add getdents and fcntl related system calls
Add glue to call the following syscalls to the freebsd_syscall: freebsd11_getdents getdirentries freebsd11_getdirentries fcntl Signed-off-by: Warner Losh <imp@bsdimp.com> Signed-off-by: Karim Taha <kariem.taha2.7@gmail.com> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Signed-off-by: Warner Losh <imp@bsdimp.com>
-rw-r--r--bsd-user/freebsd/os-syscall.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/bsd-user/freebsd/os-syscall.c b/bsd-user/freebsd/os-syscall.c
index 916a754..e9b1b66 100644
--- a/bsd-user/freebsd/os-syscall.c
+++ b/bsd-user/freebsd/os-syscall.c
@@ -576,6 +576,22 @@ static abi_long freebsd_syscall(void *cpu_env, int num, abi_long arg1,
ret = do_freebsd_getfsstat(arg1, arg2, arg3);
break;
+ case TARGET_FREEBSD_NR_freebsd11_getdents: /* getdents(2) */
+ ret = do_freebsd11_getdents(arg1, arg2, arg3);
+ break;
+
+ case TARGET_FREEBSD_NR_getdirentries: /* getdirentries(2) */
+ ret = do_freebsd_getdirentries(arg1, arg2, arg3, arg4);
+ break;
+
+ case TARGET_FREEBSD_NR_freebsd11_getdirentries: /* getdirentries(2) */
+ ret = do_freebsd11_getdirentries(arg1, arg2, arg3, arg4);
+ break;
+ case TARGET_FREEBSD_NR_fcntl: /* fcntl(2) */
+ ret = do_freebsd_fcntl(arg1, arg2, arg3);
+ break;
+
+
/*
* sys{ctl, arch, call}
*/