From 34e539926a8fba1fc4e48bee9e11534dcece5af9 Mon Sep 17 00:00:00 2001 From: Gregory Nutt <gnutt@nuttx.org> Date: Sat, 28 Jan 2017 11:03:06 -0600 Subject: [PATCH] Syscalls: Remove modsym() syscall. There is no reason why appication code could ever use symbolic information from a symbol within a kernel module. The modsym() interface is only meaningful within the kernel. --- include/sys/syscall.h | 5 ++--- syscall/syscall.csv | 1 - syscall/syscall_lookup.h | 1 - syscall/syscall_stublookup.c | 1 - 4 files changed, 2 insertions(+), 6 deletions(-) diff --git a/include/sys/syscall.h b/include/sys/syscall.h index 1286bcbec9..eb53fdf978 100644 --- a/include/sys/syscall.h +++ b/include/sys/syscall.h @@ -182,9 +182,8 @@ #ifdef CONFIG_MODULE # define SYS_insmod __SYS_insmod # define SYS_rmmod (__SYS_insmod+1) -# define SYS_modsym (__SYS_insmod+2) -# define SYS_modhandle (__SYS_insmod+3) -# define __SYS_posix_spawn (__SYS_insmod+4) +# define SYS_modhandle (__SYS_insmod+2) +# define __SYS_posix_spawn (__SYS_insmod+3) #else # define __SYS_posix_spawn __SYS_insmod #endif diff --git a/syscall/syscall.csv b/syscall/syscall.csv index 501f99c3c3..1b6917d5f3 100644 --- a/syscall/syscall.csv +++ b/syscall/syscall.csv @@ -38,7 +38,6 @@ "mkfifo2","nuttx/drivers/drivers.h","defined(CONFIG_PIPES) && CONFIG_DEV_FIFO_SIZE > 0","int","FAR const char*","mode_t","size_t" "mmap","sys/mman.h","CONFIG_NFILE_DESCRIPTORS > 0","FAR void*","FAR void*","size_t","int","int","int","off_t" "modhandle","nuttx/module.h","defined(CONFIG_MODULE)","FAR void *","FAR const char *" -"modsym","nuttx/module.h","defined(CONFIG_MODULE)","FAR const void *","FAR void *","FAR const char *" "mount","sys/mount.h","CONFIG_NFILE_DESCRIPTORS > 0 && !defined(CONFIG_DISABLE_MOUNTPOINT) && defined(CONFIG_FS_READABLE)","int","const char*","const char*","const char*","unsigned long","const void*" "mq_close","mqueue.h","!defined(CONFIG_DISABLE_MQUEUE)","int","mqd_t" "mq_getattr","mqueue.h","!defined(CONFIG_DISABLE_MQUEUE)","int","mqd_t","struct mq_attr *" diff --git a/syscall/syscall_lookup.h b/syscall/syscall_lookup.h index d064bdd93f..f8286ca6b1 100644 --- a/syscall/syscall_lookup.h +++ b/syscall/syscall_lookup.h @@ -123,7 +123,6 @@ SYSCALL_LOOKUP(up_assert, 2, STUB_up_assert) #ifdef CONFIG_MODULE SYSCALL_LOOKUP(insmod, 2, STUB_insmod) SYSCALL_LOOKUP(rmmod, 1, STUB_rmmod) - SYSCALL_LOOKUP(modsym, 2, STUB_modsym) SYSCALL_LOOKUP(modhandle, 1, STUB_modhandle) #endif diff --git a/syscall/syscall_stublookup.c b/syscall/syscall_stublookup.c index fcb7d2dbfb..59c4515ac4 100644 --- a/syscall/syscall_stublookup.c +++ b/syscall/syscall_stublookup.c @@ -122,7 +122,6 @@ uintptr_t STUB_waitid(int nbr, uintptr_t parm1, uintptr_t parm2, #ifdef CONFIG_MODULE uintptr_t STUB_insmod(int nbr, uintptr_t parm1, uintptr_t parm2); uintptr_t STUB_rmmod(int nbr, uintptr_t parm1); -uintptr_t STUB_modsym(int nbr, uintptr_t parm1); uintptr_t STUB_modhandle(int nbr, uintptr_t parm1, uintptr_t parm2); #endif -- GitLab