aboutsummaryrefslogtreecommitdiff
path: root/bsd-user/qemu-bsd.h
diff options
context:
space:
mode:
authorStacey Son <sson@FreeBSD.org>2023-09-25 21:24:02 +0300
committerWarner Losh <imp@bsdimp.com>2023-10-03 17:14:06 -0600
commit00bff01fc09c5e3aed4d35842ebc3dbc36a56ee9 (patch)
tree0b88cbfc36a8f2c2bbfd25912e293e3cc87bbce0 /bsd-user/qemu-bsd.h
parentcc47390ce7553b29bc8fb12f171836ce5dbf61f5 (diff)
downloadqemu-00bff01fc09c5e3aed4d35842ebc3dbc36a56ee9.zip
qemu-00bff01fc09c5e3aed4d35842ebc3dbc36a56ee9.tar.gz
qemu-00bff01fc09c5e3aed4d35842ebc3dbc36a56ee9.tar.bz2
bsd-user: add extern declarations for bsd-proc.c conversion functions
Signed-off-by: Stacey Son <sson@FreeBSD.org> Signed-off-by: Karim Taha <kariem.taha2.7@gmail.com> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Reviewed-by: Warner Losh <imp@bsdimp.com> Message-Id: <20230925182425.3163-6-kariem.taha2.7@gmail.com>
Diffstat (limited to 'bsd-user/qemu-bsd.h')
-rw-r--r--bsd-user/qemu-bsd.h38
1 files changed, 38 insertions, 0 deletions
diff --git a/bsd-user/qemu-bsd.h b/bsd-user/qemu-bsd.h
new file mode 100644
index 0000000..b93a0b7
--- /dev/null
+++ b/bsd-user/qemu-bsd.h
@@ -0,0 +1,38 @@
+/*
+ * BSD conversion extern declarations
+ *
+ * Copyright (c) 2013 Stacey D. Son
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, see <http://www.gnu.org/licenses/>.
+ */
+
+#ifndef QEMU_BSD_H
+#define QEMU_BSD_H
+
+#include <sys/types.h>
+#include <sys/resource.h>
+
+/* bsd-proc.c */
+int target_to_host_resource(int code);
+rlim_t target_to_host_rlim(abi_llong target_rlim);
+abi_llong host_to_target_rlim(rlim_t rlim);
+abi_long host_to_target_rusage(abi_ulong target_addr,
+ const struct rusage *rusage);
+abi_long host_to_target_wrusage(abi_ulong target_addr,
+ const struct __wrusage *wrusage);
+int host_to_target_waitstatus(int status);
+void h2g_rusage(const struct rusage *rusage,
+ struct target_freebsd_rusage *target_rusage);
+
+#endif /* QEMU_BSD_H */