include/sys/syscall.h and syscall/: Added support for munmap() syscall.

This commit is contained in:
Joao Matos 2019-04-04 10:54:46 -06:00 committed by Gregory Nutt
parent a095dcd6bf
commit 7df60a2c16
4 changed files with 18 additions and 14 deletions

View file

@ -339,23 +339,24 @@
#define SYS_fcntl (__SYS_filedesc + 3)
#define SYS_lseek (__SYS_filedesc + 4)
#define SYS_mmap (__SYS_filedesc + 5)
#define SYS_open (__SYS_filedesc + 6)
#define SYS_opendir (__SYS_filedesc + 7)
#define SYS_readdir (__SYS_filedesc + 8)
#define SYS_rewinddir (__SYS_filedesc + 9)
#define SYS_seekdir (__SYS_filedesc + 10)
#define SYS_stat (__SYS_filedesc + 11)
#define SYS_fstat (__SYS_filedesc + 12)
#define SYS_statfs (__SYS_filedesc + 13)
#define SYS_fstatfs (__SYS_filedesc + 14)
#define SYS_telldir (__SYS_filedesc + 15)
#define SYS_munmap (__SYS_filedesc + 6)
#define SYS_open (__SYS_filedesc + 7)
#define SYS_opendir (__SYS_filedesc + 8)
#define SYS_readdir (__SYS_filedesc + 9)
#define SYS_rewinddir (__SYS_filedesc + 10)
#define SYS_seekdir (__SYS_filedesc + 11)
#define SYS_stat (__SYS_filedesc + 12)
#define SYS_fstat (__SYS_filedesc + 13)
#define SYS_statfs (__SYS_filedesc + 14)
#define SYS_fstatfs (__SYS_filedesc + 15)
#define SYS_telldir (__SYS_filedesc + 16)
#if defined(CONFIG_PSEUDOFS_SOFTLINKS)
# define SYS_link (__SYS_filedesc + 16)
# define SYS_readlink (__SYS_filedesc + 17)
# define __SYS_pipes (__SYS_filedesc + 18)
# define SYS_link (__SYS_filedesc + 17)
# define SYS_readlink (__SYS_filedesc + 18)
# define __SYS_pipes (__SYS_filedesc + 19)
#else
# define __SYS_pipes (__SYS_filedesc + 16)
# define __SYS_pipes (__SYS_filedesc + 17)
#endif
#if defined(CONFIG_PIPES) && CONFIG_DEV_PIPE_SIZE > 0

View file

@ -48,6 +48,7 @@
"mkdir","sys/stat.h","!defined(CONFIG_DISABLE_MOUNTPOINT)","int","FAR const char*","mode_t"
"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","","FAR void*","FAR void*","size_t","int","int","int","off_t"
"munmap","sys/mman.h","","int","FAR void*","size_t"
"modhandle","nuttx/module.h","defined(CONFIG_MODULE)","FAR void *","FAR const char *"
"mount","sys/mount.h","!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"

Can't render this file because it has a wrong number of fields in line 2.

View file

@ -234,6 +234,7 @@ SYSCALL_LOOKUP(up_assert, 2, STUB_up_assert)
SYSCALL_LOOKUP(fcntl, 6, STUB_fcntl)
SYSCALL_LOOKUP(lseek, 3, STUB_lseek)
SYSCALL_LOOKUP(mmap, 6, STUB_mmap)
SYSCALL_LOOKUP(munmap, 2, STUB_munmap)
SYSCALL_LOOKUP(open, 6, STUB_open)
SYSCALL_LOOKUP(opendir, 1, STUB_opendir)
SYSCALL_LOOKUP(readdir, 1, STUB_readdir)

View file

@ -244,6 +244,7 @@ uintptr_t STUB_lseek(int nbr, uintptr_t parm1, uintptr_t parm2,
uintptr_t STUB_mmap(int nbr, uintptr_t parm1, uintptr_t parm2,
uintptr_t parm3, uintptr_t parm4, uintptr_t parm5,
uintptr_t parm6);
uintptr_t STUB_munmap(int nbr, uintptr_t parm1, uintptr_t parm2);
uintptr_t STUB_open(int nbr, uintptr_t parm1, uintptr_t parm2,
uintptr_t parm3, uintptr_t parm4, uintptr_t parm5,
uintptr_t parm6);