1. 30 12月, 2016 1 次提交
  2. 10 6月, 2016 1 次提交
    • S
      add preadv2 and pwritev2 syscall numbers for linux v4.6 · 78b1f3cb
      Szabolcs Nagy 提交于
      the syscalls take an additional flag argument, they were added in commit
      f17d8b35452cab31a70d224964cd583fb2845449 and a RWF_HIPRI priority hint
      flag was added to linux/fs.h in 97be7ebe53915af504fb491fb99f064c7cf3cb09.
      
      the syscall is not allocated for microblaze and sh yet.
      78b1f3cb
  3. 12 5月, 2016 1 次提交
  4. 19 3月, 2016 1 次提交
  5. 27 1月, 2016 3 次提交
    • S
      add mlock2 syscall number from linux v4.4 · 51d5f139
      Szabolcs Nagy 提交于
      this is mlock with a flags argument, new in linux commit
      a8ca5d0ecbdde5cc3d7accacbd69968b0c98764e
      
      as usual microblaze and sh don't have allocated syscall number yet.
      51d5f139
    • S
      add new membarrier, userfaultfd and switch_endian syscalls · 09001a8f
      Szabolcs Nagy 提交于
      new in linux v4.3 added for aarch64, arm, i386, mips, or1k, powerpc,
      x32 and x86_64.
      
      membarrier is a system wide memory barrier, moves most of the
      synchronization cost to one side, new in kernel commit
      5b25b13ab08f616efd566347d809b4ece54570d1
      
      userfaultfd is useful for qemu and is new in kernel commit
      8d2afd96c20316d112e04d935d9e09150e988397
      
      switch_endian is powerpc only for switching endianness, new in commit
      529d235a0e190ded1d21ccc80a73e625ebcad09b
      09001a8f
    • S
      add new i386 socket syscall numbers · 37bfb68f
      Szabolcs Nagy 提交于
      new in linux v4.3 commit 9dea5dc921b5f4045a18c63eb92e84dc274d17eb
      direct calls instead of socketcall allow better seccomp filtering.
      
      musl continues to use socketcalls internally on i386. (older kernels
      would need a fallback mechanism if the direct calls were used.)
      37bfb68f
  6. 10 2月, 2015 1 次提交
    • S
      add syscall numbers for the new execveat syscall · f54c28cb
      Szabolcs Nagy 提交于
      this syscall allows fexecve to be implemented without /proc, it is new
      in linux v3.19, added in commit 51f39a1f0cea1cacf8c787f652f26dfee9611874
      (sh and microblaze do not have allocated syscall numbers yet)
      
      added a x32 fix as well: the io_setup and io_submit syscalls are no
      longer common with x86_64, so use the x32 specific numbers.
      f54c28cb
  7. 23 12月, 2014 1 次提交
    • S
      add new syscall numbers for bpf and kexec_file_load · f90fafea
      Szabolcs Nagy 提交于
      these syscalls are new in linux v3.18, bpf is present on all
      supported archs except sh, kexec_file_load is only allocted for
      x86_64 and x32 yet.
      
      bpf was added in linux commit 99c55f7d47c0dc6fc64729f37bf435abf43f4c60
      
      kexec_file_load syscall number was allocated in commit
      f0895685c7fd8c938c91a9d8a6f7c11f22df58d2
      f90fafea
  8. 08 10月, 2014 1 次提交
    • S
      add new syscall numbers for seccomp, getrandom, memfd_create · 4ffc39c6
      Szabolcs Nagy 提交于
      these syscalls are new in linux v3.17 and present on all supported
      archs except sh.
      
      seccomp was added in commit 48dc92b9fc3926844257316e75ba11eb5c742b2c
      it has operation, flags and pointer arguments (if flags==0 then it is
      the same as prctl(PR_SET_SECCOMP,...)), the uapi header for flag
      definitions is linux/seccomp.h
      
      getrandom was added in commit c6e9d6f38894798696f23c8084ca7edbf16ee895
      it provides an entropy source when open("/dev/urandom",..) would fail,
      the uapi header for flags is linux/random.h
      
      memfd_create was added in commit 9183df25fe7b194563db3fec6dc3202a5855839c
      it allows anon mmap to have an fd, that can be shared, sealed and needs no
      mount point, the uapi header for flags is linux/memfd.h
      4ffc39c6
  9. 21 7月, 2014 1 次提交
  10. 31 5月, 2014 1 次提交
    • S
      add sched_{get,set}attr syscall numbers and SCHED_DEADLINE macro · fd9571e2
      Szabolcs Nagy 提交于
      linux 3.14 introduced sched_getattr and sched_setattr syscalls in
      commit d50dde5a10f305253cbc3855307f608f8a3c5f73
      
      and the related SCHED_DEADLINE scheduling policy in
      commit aab03e05e8f7e26f51dee792beddcb5cca9215a5
      
      but struct sched_attr "extended scheduling parameters data structure"
      is not yet exported to userspace (necessary for using the syscalls)
      so related uapi definitions are not added yet.
      fd9571e2
  11. 27 9月, 2013 1 次提交
  12. 02 4月, 2013 1 次提交
  13. 09 9月, 2012 2 次提交
    • R
      syscall organization overhaul · 208eb584
      Rich Felker 提交于
      now public syscall.h only exposes __NR_* and SYS_* constants and the
      variadic syscall function. no macros or inline functions, no
      __syscall_ret or other internal details, no 16-/32-bit legacy syscall
      renaming, etc. this logic has all been moved to src/internal/syscall.h
      with the arch-specific parts in arch/$(ARCH)/syscall_arch.h, and the
      amount of arch-specific stuff has been reduced to a minimum.
      
      changes still need to be reviewed/double-checked. minimal testing on
      i386 and mips has already been performed.
      208eb584
    • R
      add acct, accept4, setns, and dup3 syscalls (linux extensions) · 6cf8bfdb
      Rich Felker 提交于
      based on patch by Justin Cormack
      6cf8bfdb
  14. 03 9月, 2012 1 次提交
    • R
      avoid "inline" in public headers for strict c89 compatibility · fb247faf
      Rich Felker 提交于
      while musl itself requires a c99 compiler, some applications insist on
      being compiled with c89 compilers, and use of "inline" in the headers
      was breaking them. much of this had been avoided already by just
      skipping the inline keyword in pre-c99 compilers or modes, but this
      new unified solution is cleaner and may/should result in better code
      generation in the default gcc configuration.
      fb247faf
  15. 10 8月, 2012 1 次提交
  16. 24 6月, 2012 1 次提交
  17. 04 4月, 2012 1 次提交
    • R
      work around nasty gcc bug in the i386 syscall asm · 5bd0ab8a
      Rich Felker 提交于
      when the "r" (register) constraint is used to let gcc choose a
      register, gcc will sometimes assign the same register that was used
      for one of the other fixed-register operands, if it knows the values
      are the same. one common case is multiple zero arguments to a syscall.
      this horribly breaks the intended usage, which is swapping the GOT
      pointer from ebx into the temp register and back to perform the
      syscall.
      
      presumably there is a way to fix this with advanced usage of register
      constaints on the inline asm, but having bad memories about hellish
      compatibility issues with different gcc versions, for the time being
      i'm just going to hard-code specific registers to be used. this may
      hurt the compiler's ability to optimize, but it will fix serious
      miscompilation issues.
      
      so far the only function i know what compiled incorrectly is
      getrlimit.c, and naturally the bug only applies to shared (PIC)
      builds, but it may be more extensive and may have gone undetected..
      5bd0ab8a
  18. 21 1月, 2012 1 次提交
  19. 22 9月, 2011 1 次提交
  20. 15 6月, 2011 1 次提交
  21. 21 4月, 2011 1 次提交
  22. 17 4月, 2011 1 次提交
    • R
      overhaul pthread cancellation · feee9890
      Rich Felker 提交于
      this patch improves the correctness, simplicity, and size of
      cancellation-related code. modulo any small errors, it should now be
      completely conformant, safe, and resource-leak free.
      
      the notion of entering and exiting cancellation-point context has been
      completely eliminated and replaced with alternative syscall assembly
      code for cancellable syscalls. the assembly is responsible for setting
      up execution context information (stack pointer and address of the
      syscall instruction) which the cancellation signal handler can use to
      determine whether the interrupted code was in a cancellable state.
      
      these changes eliminate race conditions in the previous generation of
      cancellation handling code (whereby a cancellation request received
      just prior to the syscall would not be processed, leaving the syscall
      to block, potentially indefinitely), and remedy an issue where
      non-cancellable syscalls made from signal handlers became cancellable
      if the signal handler interrupted a cancellation point.
      
      x86_64 asm is untested and may need a second try to get it right.
      feee9890
  23. 29 3月, 2011 1 次提交
  24. 20 3月, 2011 3 次提交
    • R
    • R
      syscall overhaul part two - unify public and internal syscall interface · 685e40bb
      Rich Felker 提交于
      with this patch, the syscallN() functions are no longer needed; a
      variadic syscall() macro allows syscalls with anywhere from 0 to 6
      arguments to be made with a single macro name. also, manually casting
      each non-integer argument with (long) is no longer necessary; the
      casts are hidden in the macros.
      
      some source files which depended on being able to define the old macro
      SYSCALL_RETURNS_ERRNO have been modified to directly use __syscall()
      instead of syscall(). references to SYSCALL_SIGSET_SIZE and SYSCALL_LL
      have also been changed.
      
      x86_64 has not been tested, and may need a follow-up commit to fix any
      minor bugs/oversights.
      685e40bb
    • R
      overhaul syscall interface · d00ff295
      Rich Felker 提交于
      this commit shuffles around the location of syscall definitions so
      that we can make a syscall() library function with both SYS_* and
      __NR_* style syscall names available to user applications, provides
      the syscall() library function, and optimizes the code that performs
      the actual inline syscalls in the library itself.
      
      previously on i386 when built as PIC (shared library), syscalls were
      incurring bus lock (lock prefix) overhead at entry and exit, due to
      the way the ebx register was being loaded (xchg instruction with a
      memory operand). now the xchg takes place between two registers.
      
      further cleanup to arch/$(ARCH)/syscall.h is planned.
      d00ff295
  25. 16 2月, 2011 1 次提交
    • R
      remove standalone syscall cruft · 9b235e83
      Rich Felker 提交于
      this was originally written for an early draft of the library where
      non-standard functions would reside in a static library separate from
      the shared libc.so, which would implement a pure standard. the idea
      was not to depend on an implementation-dependent __syscall_ret
      function in the main libc. but it turned out to be better to put
      everything in a single library for both static and dynamic linking
      uses, and thus the (incomplete) remnants of this feature were just
      enlarging the source and binary.
      9b235e83
  26. 15 2月, 2011 5 次提交
  27. 14 2月, 2011 1 次提交
    • R
      cleaning up syscalls in preparation for x86_64 port · 2cdfb7ca
      Rich Felker 提交于
      - hide all the legacy xxxxxx32 name cruft in syscall.h so the actual
      source files can be clean and uniform across all archs.
      
      - cleanup llseek/lseek and mmap2/mmap handling for 32/64 bit systems
      
      - alternate implementation for nice if the target lacks nice syscall
      2cdfb7ca
  28. 12 2月, 2011 1 次提交