summaryrefslogtreecommitdiff
path: root/sys/compat/linux/arch
AgeCommit message (Collapse)Author
2023-02-12fix typo in the include guard definition.andvar
2022-09-05G/C ISSET() macro copies. It has been defined in <sys/types.h> since 2006.tsutsui
2022-08-07Remove extra whitespaces added by an ancient stupid script.tsutsui
2021-12-03fix various typos in comments, log messages and documentation.andvar
2021-12-02regenryo
2021-12-02add prlimit64(2) syscall to COMPAT_LINUX and COMPAT_LINUX32ryo
2021-11-30- uname should return "aarch64" or "aarch64_be" instead of "evbarm".ryo
- define LINUX_LARGEFILE64 to use rlimit instead of orlimit.
2021-11-26The internal architecture name of golang is "arm" or "arm64", which hasryo
different naming conventions from netbsd's machine[] or machine_arch[] ("earmv7", "aarch64", etc.) and cannot be used as is. Instead, use define LINUX_GO_RT0_SIGNATURE_ARCH{32,64}.
2021-11-26- LINUX_GO_RT0_SIGNATURE for compat_linux is no longer enabled by default.ryo
it is now defined in each arch same as the other *_SIGNATURE definitions. - add new LINUX32_GO_RT0_SIGNATURE for compat_linux32, and is defined in amd64 and aarch64.
2021-11-25add support COMPAT_LINUX32 for aarch64ryo
2021-11-25regenryo
2021-11-25add statx(2) syscall entryryo
2021-11-24regenryo
2021-11-24add getrandom(2) syscall entryryo
2021-11-24add missing SUBDIR aarch64ryo
2021-11-01Use "stack_t" instead of "struct sigaltstack", as the former is thethorpej
newer standardized name. NFC.
2021-10-27Use __SIGTRAMP_SIGCODE_VERSION rather than hard-coding 0.thorpej
2021-10-12fix various typos, mainly in comments.andvar
2021-10-09Modularize compat_linux(8) for aarch64.ryo
2021-09-23add support COMPAT_LINUX for aarch64ryo
2021-09-20Regen for preadv(2) / pwritev(2).thorpej
2021-09-20Add preadv(2) and pwritev(2) system calls to COMPAT_LINUX and COMPAT_LINUX32.thorpej
2021-09-20Regen for eventfd.thorpej
2021-09-20Add the eventfd system calls to COMPAT_LINUX and COMPAT_LINUX32.thorpej
2021-09-19Regen for timerfd.thorpej
2021-09-19Add the timerfd syscalls to COMPAT_LINUX and COMPAT_LINUX32.thorpej
2021-09-19Regen for POSIX timer syscalls.thorpej
2021-09-19Add the POSIX timer syscalls (timer_create(), timer_settime(), timer_gettime(),thorpej
timer_getoverrun(), and timer_delete()) to COMPAT_LINUX and COMPAT_LINUX32.
2021-09-07sys/compat: Memset zero before copyout.riastradh
Just in case of uninitialized padding which would lead to kernel stack disclosure. If the compiler can prove the memset redundant then it can optimize it away; otherwise better safe than sorry.
2021-08-09fix typos in asymmetry, asymmetric(al), symmetrical.andvar
2021-02-01G/C some old code that was for acorn26skrll
2020-10-06make MAXTSIZ optionalchristos
2020-09-05Round of uvm.h cleanup.riastradh
The poorly named uvm.h is generally supposed to be for uvm-internal users only. - Narrow it to files that actually need it -- mostly files that need to query whether curlwp is the pagedaemon, which should maybe be exposed by an external header. - Use uvm_extern.h where feasible and uvm_*.h for things not exposed by it. We should split up uvm_extern.h but this will serve for now to reduce the uvm.h dependencies. - Use uvm_stat.h and #ifdef UVMHIST uvm.h for files that use UVMHIST(ubchist), since ubchist is declared in uvm.h but the reference evaporates if UVMHIST is not defined, so we reduce header file dependencies. - Make uvm_device.h and uvm_swap.h independently includable while here. ok chs@
2020-09-03The conversion of FPU tracking to PCU rendered the fpcurlwp variablethorpej
unmaintained, which broke FP status info in the COMPAT_LINUX sigcontext. Use the new API, which will at least be closer to correct.
2020-07-19don't include opt_user_ldt.h when it is not neededmaxv
2020-05-23Move proc_lock into the data segment. It was dynamically allocated becausead
at the time we had mutex_obj_alloc() but not __cacheline_aligned.
2020-05-03Always clear FUTEX_PRIVATE_FLAG for Linux processes. NetBSD-native futexesthorpej
exist in different namespace depending on FUTEX_PRIVATE_FLAG. This appears not to be the case in Linux, and some futex users will mix private and non- private ops on the same futex object. Provide a convenience wrapper that puts this logic in one place witn a comment explaining why. While here, move the Linux futex wrapper out of its own file and plop it in linux_misc.c, which is where it lives in the linux32 module.
2020-04-26Regen for native futex calls.thorpej
2020-04-26Add a NetBSD native futex implementation, mostly written by riastradh@.thorpej
Map the COMPAT_LINUX futex calls to the native ones.
2020-01-12Tidy up the vnode locking around execve() on ELF images to acquire andad
release the locks fewer times. Proposed on tech-kern a very long time go.
2019-11-09regenjdolecek
2019-11-09add dummy implementation of linux fallocate() which just returns EOPNOTSUPP;jdolecek
this is needed so that glibc falls back to emulation and apps behaving properly, since EOPNOTSUPP is a documented and expected return code, but ENOSYS is not right now there are no filesystems in NetBSD tree supporting the fallocate VOP, so no point trying to map this to a native call supposed to help with problem reported in https://mail-index.netbsd.org/tech-kern/2019/11/03/msg025641.html
2019-11-09don't descend to sparc and sparc64, they don't have syscalls.masterjdolecek
so it just errors out
2019-08-23Remove printf.maxv
2019-05-19Renamemaxv
fpu_save_area_clear -> fpu_clear fpu_save_area_reset -> fpu_sigreset Clearer, and reduces a future diff. No real functional change.
2019-04-06Overhaul the API used to fetch and store individual memory cells inthorpej
userspace. The old fetch(9) and store(9) APIs (fubyte(), fuword(), subyte(), suword(), etc.) are retired and replaced with new ufetch(9) and ustore(9) APIs that can return proper error codes, etc. and are implemented consistently across all platforms. The interrupt-safe variants are no longer supported (and several of the existing attempts at fuswintr(), etc. were buggy and not actually interrupt-safe). Also augmement the ucas(9) API, making it consistently available on all plaforms, supporting uniprocessor and multiprocessor systems, even those that do not have CAS or LL/SC primitives. Welcome to NetBSD 8.99.37.
2019-03-26make this compile again.christos
2019-03-24regenmaxv
2019-03-24Remove Alpha's compat_linux dependency on compat_osf1. Each function ismaxv
copied as-is from compat_osf1 with no functional change. Discussed on tech-kern@, ok @thorpej.
2019-03-24Fix a tiny race in setregs and linux_setregs. Between the moment we setmaxv
pcb_flags to zero, and the moment cpu_segregs64_zero resets pcb_gs, we may be preempted. If this happens, and if the calling LWP was a 32bit thread, when switching back to that LWP, the context switcher sees that PCB_COMPAT32 is not set in pcb_flags and tries to perform a 64bit context switch; but pcb_gs contains a 32bit GDT descriptor, and not a 64bit GS.base value. The wrmsr therefore faults because the value is non-canonical, and this fault is fatal. Rearrange the code so that the update of pcb_flags and pcb_gs/pcb_fs is non interruptible. This fixes the problem, tested with a reproducer (which therefore doesn't work anymore). Likely fixes PR/53993.