This is an automated email from the ASF dual-hosted git repository.

xiaoxiang781216 pushed a commit to branch releases/13.0
in repository https://gitbox.apache.org/repos/asf/nuttx.git


The following commit(s) were added to refs/heads/releases/13.0 by this push:
     new 8f45ffb1c79 syscall: add missing memory locking and clock_getres 
entries
8f45ffb1c79 is described below

commit 8f45ffb1c797f7a74c7c62a977bfa324eabdce35
Author: raiden00pl <[email protected]>
AuthorDate: Fri Aug 7 10:27:52 2026 +0200

    syscall: add missing memory locking and clock_getres entries
    
    add missing syscall entries for mlock, mlockall, munlock, munlockall,
    mprotect and clock_getres
    
    Signed-off-by: raiden00pl <[email protected]>
    Assisted-by: Claude Code
---
 include/sys/syscall_lookup.h | 6 ++++++
 syscall/syscall.csv          | 6 ++++++
 2 files changed, 12 insertions(+)

diff --git a/include/sys/syscall_lookup.h b/include/sys/syscall_lookup.h
index 7a1f37284c8..2fc194cc472 100644
--- a/include/sys/syscall_lookup.h
+++ b/include/sys/syscall_lookup.h
@@ -172,6 +172,7 @@ SYSCALL_LOOKUP(clock_nanosleep,            4)
  */
 
 SYSCALL_LOOKUP(clock,                      0)
+SYSCALL_LOOKUP(clock_getres,               2)
 SYSCALL_LOOKUP(clock_gettime,              2)
 SYSCALL_LOOKUP(clock_settime,              2)
 #ifdef CONFIG_CLOCK_ADJTIME
@@ -246,6 +247,9 @@ SYSCALL_LOOKUP(dup2,                       2)
 SYSCALL_LOOKUP(fcntl,                      3)
 SYSCALL_LOOKUP(ftruncate,                  2)
 SYSCALL_LOOKUP(lseek,                      3)
+SYSCALL_LOOKUP(mlock,                      2)
+SYSCALL_LOOKUP(mlockall,                   1)
+SYSCALL_LOOKUP(mprotect,                   3)
 SYSCALL_LOOKUP(mmap,                       6)
 SYSCALL_LOOKUP(open,                       3)
 SYSCALL_LOOKUP(rename,                     2)
@@ -268,6 +272,8 @@ SYSCALL_LOOKUP(lutimens,                   2)
 SYSCALL_LOOKUP(futimens,                   2)
 SYSCALL_LOOKUP(msync,                      3)
 SYSCALL_LOOKUP(munmap,                     2)
+SYSCALL_LOOKUP(munlock,                    2)
+SYSCALL_LOOKUP(munlockall,                 0)
 
 #if defined(CONFIG_PSEUDOFS_SOFTLINKS)
   SYSCALL_LOOKUP(link,                     2)
diff --git a/syscall/syscall.csv b/syscall/syscall.csv
index 4622a0910b8..c91e51725f2 100644
--- a/syscall/syscall.csv
+++ b/syscall/syscall.csv
@@ -13,6 +13,7 @@
 "clearenv","stdlib.h","!defined(CONFIG_DISABLE_ENVIRON)","int"
 "clock","time.h","","clock_t"
 
"clock_adjtime","sys/timex.h","defined(CONFIG_CLOCK_ADJTIME)","int","clockid_t","struct
 timex *"
+"clock_getres","time.h","","int","clockid_t","FAR struct timespec *"
 "clock_gettime","time.h","","int","clockid_t","FAR struct timespec *"
 "clock_nanosleep","time.h","","int","clockid_t","int","FAR const struct 
timespec *", "FAR struct timespec *"
 "clock_settime","time.h","","int","clockid_t","const struct timespec*"
@@ -65,7 +66,10 @@
 "lstat","sys/stat.h","","int","FAR const char *","FAR struct stat *"
 "lutimens","sys/stat.h","","int","FAR const char *","const struct timespec 
[2]|FAR const struct timespec *"
 "mkdir","sys/stat.h","!defined(CONFIG_DISABLE_MOUNTPOINT)","int","FAR const 
char *","mode_t"
+"mlock","sys/mman.h","","int","FAR const void *","size_t"
+"mlockall","sys/mman.h","","int","int"
 "mmap","sys/mman.h","","FAR void *","FAR void 
*","size_t","int","int","int","off_t"
+"mprotect","sys/mman.h","","int","FAR void *","size_t","int"
 "modhandle","nuttx/module.h","defined(CONFIG_MODULE)","FAR void *","FAR const 
char *"
 "mount","sys/mount.h","!defined(CONFIG_DISABLE_MOUNTPOINT)","int","FAR const 
char *","FAR const char *","FAR const char *","unsigned long","FAR const void *"
 "mq_close","mqueue.h","!defined(CONFIG_DISABLE_MQUEUE)","int","mqd_t"
@@ -79,6 +83,8 @@
 "mq_timedsend","mqueue.h","!defined(CONFIG_DISABLE_MQUEUE)","int","mqd_t","FAR 
const char *","size_t","unsigned int","FAR const struct timespec *"
 "mq_unlink","mqueue.h","!defined(CONFIG_DISABLE_MQUEUE)","int","FAR const char 
*"
 "msync","sys/mman.h","","int","FAR void *","size_t","int"
+"munlock","sys/mman.h","","int","FAR const void *","size_t"
+"munlockall","sys/mman.h","","int"
 "munmap","sys/mman.h","","int","FAR void *","size_t"
 "nanosleep","time.h","","int","FAR const struct timespec *","FAR struct 
timespec *"
 "nx_mkfifo","nuttx/fs/fs.h","defined(CONFIG_PIPES) && CONFIG_DEV_FIFO_SIZE > 
0","int","FAR const char *","mode_t","size_t"

Reply via email to