diff options
author | jhb <jhb@FreeBSD.org> | 2015-10-22 21:28:20 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2015-10-22 21:28:20 +0000 |
commit | 9740ac3060b33574f581db8a7ee96240749c81ed (patch) | |
tree | 24a943ba920de041a337bc369f1a55629ba2a11d /sys/amd64 | |
parent | 2705fe5cc132ba44ee6bdb210ae3bff5be670722 (diff) | |
download | FreeBSD-src-9740ac3060b33574f581db8a7ee96240749c81ed.zip FreeBSD-src-9740ac3060b33574f581db8a7ee96240749c81ed.tar.gz |
Rename remaining linux32 symbols such as linux_sysent[] and
linux_syscallnames[] from linux_* to linux32_* to avoid conflicts with
linux64.ko. While here, add support for linux64 binaries to systrace.
- Update NOPROTO entries in amd64/linux/syscalls.master to match the
main table to fix systrace build.
- Add a special case for union l_semun arguments to the systrace
generation.
- The systrace_linux32 module now only builds the systrace_linux32.ko.
module on amd64.
- Add a new systrace_linux module that builds on both i386 and amd64.
For i386 it builds the existing systrace_linux.ko. For amd64 it
builds a systrace_linux.ko for 64-bit binaries.
Reviewed by: markj
Differential Revision: https://reviews.freebsd.org/D3954
Diffstat (limited to 'sys/amd64')
-rw-r--r-- | sys/amd64/linux/syscalls.master | 6 | ||||
-rw-r--r-- | sys/amd64/linux32/linux32_sysvec.c | 6 | ||||
-rw-r--r-- | sys/amd64/linux32/syscalls.conf | 8 | ||||
-rw-r--r-- | sys/amd64/linux32/syscalls.master | 2 |
4 files changed, 11 insertions, 11 deletions
diff --git a/sys/amd64/linux/syscalls.master b/sys/amd64/linux/syscalls.master index d840f88..87c8000 100644 --- a/sys/amd64/linux/syscalls.master +++ b/sys/amd64/linux/syscalls.master @@ -49,8 +49,8 @@ struct l_newstat *buf); } 6 AUE_LSTAT STD { int linux_newlstat(char *path, \ struct l_newstat *buf); } -7 AUE_POLL NOPROTO { int poll(struct pollfd*, \ - unsigned int nfds, int timeout); } +7 AUE_POLL NOPROTO { int poll(struct pollfd *fds, u_int nfds, \ + int timeout); } 8 AUE_LSEEK STD { int linux_lseek(l_uint fdes, l_off_t off, \ l_int whence); } 9 AUE_MMAP STD { int linux_mmap2(l_ulong addr, l_ulong len, \ @@ -316,7 +316,7 @@ 161 AUE_CHROOT NOPROTO { int chroot(char *path); } 162 AUE_SYNC NOPROTO { int sync(void); } 163 AUE_ACCT NOPROTO { int acct(char *path); } -164 AUE_SETTIMEOFDAY NOPROTO { int settimeofday(struct l_timeval *tp, struct timezone *tzp); } +164 AUE_SETTIMEOFDAY NOPROTO { int settimeofday(struct l_timeval *tv, struct timezone *tzp); } 165 AUE_MOUNT STD { int linux_mount(char *specialfile, \ char *dir, char *filesystemtype, \ l_ulong rwflag, void *data); } diff --git a/sys/amd64/linux32/linux32_sysvec.c b/sys/amd64/linux32/linux32_sysvec.c index 250e16b..99e2117 100644 --- a/sys/amd64/linux32/linux32_sysvec.c +++ b/sys/amd64/linux32/linux32_sysvec.c @@ -115,7 +115,7 @@ static char *linux_shared_page_mapping; extern char _binary_linux32_locore_o_start; extern char _binary_linux32_locore_o_end; -extern struct sysent linux_sysent[LINUX_SYS_MAXSYSCALL]; +extern struct sysent linux32_sysent[LINUX32_SYS_MAXSYSCALL]; SET_DECLARE(linux_ioctl_handler_set, struct linux_ioctl_handler); @@ -1008,8 +1008,8 @@ linux32_fixlimit(struct rlimit *rl, int which) } struct sysentvec elf_linux_sysvec = { - .sv_size = LINUX_SYS_MAXSYSCALL, - .sv_table = linux_sysent, + .sv_size = LINUX32_SYS_MAXSYSCALL, + .sv_table = linux32_sysent, .sv_mask = 0, .sv_sigsize = 0, .sv_sigtbl = NULL, diff --git a/sys/amd64/linux32/syscalls.conf b/sys/amd64/linux32/syscalls.conf index dc0ad82..7d096b5 100644 --- a/sys/amd64/linux32/syscalls.conf +++ b/sys/amd64/linux32/syscalls.conf @@ -1,11 +1,11 @@ # $FreeBSD$ sysnames="linux32_syscalls.c" sysproto="linux32_proto.h" -sysproto_h=_LINUX_SYSPROTO_H_ +sysproto_h=_LINUX32_SYSPROTO_H_ syshdr="linux32_syscall.h" syssw="linux32_sysent.c" sysmk="/dev/null" -syscallprefix="LINUX_SYS_" -switchname="linux_sysent" -namesname="linux_syscallnames" +syscallprefix="LINUX32_SYS_" +switchname="linux32_sysent" +namesname="linux32_syscallnames" systrace="linux32_systrace_args.c" diff --git a/sys/amd64/linux32/syscalls.master b/sys/amd64/linux32/syscalls.master index 5f688f3..8d9f90c 100644 --- a/sys/amd64/linux32/syscalls.master +++ b/sys/amd64/linux32/syscalls.master @@ -2,7 +2,7 @@ ; @(#)syscalls.master 8.1 (Berkeley) 7/19/93 ; System call name/number master file (or rather, slave, from LINUX). -; Processed to create linux_sysent.c, linux_proto.h and linux_syscall.h. +; Processed to create linux32_sysent.c, linux32_proto.h and linux32_syscall.h. ; Columns: number audit type nargs name alt{name,tag,rtyp}/comments ; number system call number, must be in order |