summaryrefslogtreecommitdiff
path: root/sys/compat/linux32/common
AgeCommit message (Collapse)Author
2014-02-25Ensure that the top level sysctl nodes (kern, vfs, net, ...) exist beforepooka
the sysctl link sets are processed, and remove redundancy. Shaves >13kB off of an amd64 GENERIC, not to mention >1k duplicate lines of code.
2014-02-23Use Aux32Info not AuxInfo. Noticed by Maxime Villard.njoly
2014-02-23Fix wrong KASSERTs. Do not compare size vs. entries count.njoly
2014-02-21Increase LINUX32_ELF_AUX_ENTRIES to avoid overrun in linux32/. Also,maxv
add comments and KASSERTs to make sure people don't forget to increase XX_AUX_ENTRIES's when adding vectors. Reported by martin@ (CV), with suggestions from chs@. ok martin@ chs@
2014-02-09account for the 16 bytes of AT_RANDOM data in the stack setup. fixes PR 48518.chs
use cprng_strong32() instead of random(). add AT_RANDOM support for linux32.
2013-11-18claim to be linux 3.11.6 (opensuse 13.1).chs
2013-11-18implement the *at() syscalls.chs
bring the unimplemented syscall list up to date.
2013-09-19exec modules need to be of the exec kindchristos
2013-01-11Use copyin/copyout and linux-specific ifreq structures (they are the samechristos
as the netbsd ones, but this disconnects them)
2012-10-02kernel portion of clock_nanosleep()christos
2012-09-22LINUX_RLIM_INFINITY doesn't fit into the value range for linux32, sojoerg
introduce a variant with correct value.
2012-05-10Fix rt_sigtimedwait():christos
It is wishful thinking that: 1. declaring a 32 bit syscall with 64 bit pointers 2. passing a struct with 32 bit pointers to a 64 bit function is going to work.
2012-05-10prefix message with linux32christos
2012-03-15Do not read past end of array. Found by gcc -03bouyer
2012-02-19Remove COMPAT_SA / KERN_SA. Welcome to 6.99.3!rmind
Approved by core@.
2012-02-03Add a hook for freeing an ep_emul_arg. Add a wrapper routinematt
(exec_free_emul_arg) to call the hook and then clear the ep_emul_arg and ep_emul_arg_free members in the exec_package. Change users/accessors to use these routines. Approved by releng.
2011-11-18remove incorrect assertions (the len passed is the size of the bsd structurechristos
not the linux one)
2011-11-18add sigtimedwait supportchristos
2011-10-14Change the vnode locking protocol of VOP_GETATTR() to request at leasthannken
a shared lock. Make all calls outside of file systems respect it. The calls from file systems need review. No objections from tech-kern.
2011-05-30Add fadvise64 and fadvise64_64 syscalls to compat_linux and compat_linux32.alnsn
2011-04-10implement pipe2 and dup3christos
2010-11-02personality() now interprets its parameter as havingchs
the base personality type in the low byte and various flags in the upper bytes. for now just mask off the flags to make sure the base type is one we accept. store the current personality in the emuldata so that we can return the expected value for PER_QUERY.
2010-11-02implement the following syscalls for linux32:chs
truncate64 ftruncate64 profil ioperm iopl setdomainname modify_ldt statfs64 fstatfs64 note that iopl(), ioperm() and modify_ldt() just call the respective 64-bit handlers, which don't do anything yet.
2010-09-11recent versions of linux (which we now claim to be) supply a BSD-stylechs
d_type value in getdents() results, after the d_name field. make our emulation do the same. fixes part of PR 43695.
2010-09-11always supply an auxiliary vector for linux ELF processes.chs
static executables (such as newer versions of /sbin/ldconfig) require this to work properly. since static executables also don't have a PT_PHDR entry, use the same heuristic as linux does to provide a value for AT_PHDR in this case.
2010-07-12Add CLOCK_MONOTONIC support for compat linux/linux32njoly
clock_nanosleep(2).
2010-07-07many changes for COMPAT_LINUX:chs
- update the linux syscall table for each platform. - support new-style (NPTL) linux pthreads on all platforms. clone() with CLONE_THREAD uses 1 process with many LWPs instead of separate processes. - move the contents of sys__lwp_setprivate() into a new lwp_setprivate() and use that everywhere. - update linux_release[] and linux32_release[] to "2.6.18". - adjust placement of emul fork/exec/exit hooks as needed and adjust other emul code to match. - convert all struct emul definitions to use named initializers. - change the pid allocator to allow multiple pids to refer to the same proc. - remove a few fields from struct proc that are no longer needed. - disable the non-functional "vdso" code in linux32/amd64, glibc works fine without it. - fix a race in the futex code where we could miss a wakeup after a requeue operation. - redo futex locking to be a little more efficient.
2010-06-24Clean up vnode lock operations pass 2:hannken
VOP_UNLOCK(vp, flags) -> VOP_UNLOCK(vp): Remove the unneeded flags argument. Welcome to 5.99.32. Discussed on tech-kern.
2010-05-29Fix build without sysvipc configured, from Wolfgang Stukenbrock in PR 43376,dholland
adjusted for current.
2010-04-18This patch fixes the NX regression issue observed on amd64 kernels, wherejym
per-page execution right was disabled (therefore leading to the inability of the kernel to detect fraudulent use of memory mappings marked as not being executable). - replace cpu_feature and ci_feature_flags variables by cpu_feature and ci_feat_val arrays. This makes it cleaner and brings kernel code closer to the design of cpuctl(8). A warning will be raised for each CPU that does not expose the same features as the Boot Processor (BP). - the blacklist of CPU features is now a macro defined in the specialreg.h header, instead of hardcoding it inside MD initialization code; fix comments. - replace checks against CPUID_TSC with the cpu_hascounter() function. - clean up the code in init_x86_64(), as cpu_feature variables are set inside cpu_probe(). - use cpu_init_msrs() for i386. It will be eventually used later for NX feature under i386 PAE kernels. - remove code that checks for CPUID_NOX in amd64 mptramp.S, this is already performed by cpu_hatch() through cpu_init_msrs(). - remove cpu_signature and feature_flags members from struct mpbios_proc (they were never used). This patch was tested with i386 MONOLITHIC, XEN3PAE_DOM0 and XEN3_DOM0 under a native i386 host, and amd64 GENERIC, XEN3_DOM0 via QEMU virtual machines. XXX Should kernel rev be bumped? XXX A similar patch should be pulled-up for NetBSD-5, hopefully tomorrow.
2010-04-08Do not use 0 for pointers, but NULL.njoly
2010-04-08Add a new clock_gettime1() function that holds most of thenjoly
clock_gettime syscall code (except for the copyout). Adjust all corresponding syscalls to make use of it.
2010-04-03Move most clock_getres syscall code, except for coypout call, to a newnjoly
clock_getres1() function which can be used by emulations. Adjust all clock_getres syscalls to now make of use it.
2010-03-29Convert linux/linux32/netbsd32 clock_settime syscalls, to use thenjoly
common clock_settime1() function.
2010-03-03When implementing "read directory", when there are too many empty entrieshe
in a row, and we need to try to read the next block, and have passed a non-NULL cookie pointer to VOP_READDIR, ensure that we free the cookie buffer before re-doing VOP_READDIR, so that we don't leak memory. This fix is similar to nfs_serv.c revisions 1.115 + 1.124. This should fix the long-standing problem observed by e.g. using Linux- emulated programs to take backup of servers, which is one of the problems which were reported in PR#42661. Thanks to pooka@ for the hints for traversing the VOP* layer.
2010-01-05Remove extra semicolon.mbalmer
2009-12-12Add missing semicolons after NETBSD32TOx_UAP macro calls.njoly
2009-12-10Add SIOCGIFMTU support.njoly
2009-12-10Do not give native requests to netbsd32_ioctl(), use the compatnjoly
netbsd32 equivalent instead.
2009-12-10Change u_long to vaddr_t/vsize_t in exec code where appropriate (mostlymatt
involves setregs and vmcmds). Should result in no code differences.
2009-11-24Update personality(2) to match Linux definition where the argument is annjoly
unsigned long.
2009-11-20Make linux32_msqid_ds l_msg_[src]time members use the right type,njoly
linux32_time_t.
2009-11-18Make compat linux/linux32 msgrcv_msgarg type member of typenjoly
long/netbsd32_long to match linux definition.
2009-11-18Make linux32 msgsnd/msgrcv use the netbsd32 syscalls instead of nativenjoly
ones, to ensure that msgbuf mtype member will be of the right type.
2009-11-18Kill noisy debug printf.njoly
2009-11-16Follow up commit to fix breakage that somehow passed by the compiler.joerg
2009-11-16Add SYSVMSG support for linux32.joerg
2009-11-13Return the result of copyout. Reminded by Niolas Joly.joerg
2009-11-13Provide SIOCGIFNAME.joerg
2009-11-11- selcommon/pollcommon: drop redundant l argument.rmind
- Use cached curlwp->l_fd, instead of p->p_fd. - Inline selscan/pollscan.