From 63fd8bc39b21fffb6990f74e879eefecafad6c88 Mon Sep 17 00:00:00 2001 From: Caoruihong Date: Mon, 27 Sep 2021 21:01:46 +0800 Subject: [PATCH] fix: fix some function declarations Signed-off-by: Caoruihong Change-Id: I3dfcc308de6fc24035d27bc4ed4a65a2d2b6650d --- kernel/common/los_config.c | 8 +++----- syscall/los_syscall.h | 10 +++++----- 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/kernel/common/los_config.c b/kernel/common/los_config.c index 708e7047..203ebcb2 100644 --- a/kernel/common/los_config.c +++ b/kernel/common/los_config.c @@ -67,9 +67,6 @@ SystemRebootFunc OsGetRebootHook(VOID) return g_rebootHook; } -extern UINT32 OsSystemInit(VOID); -extern VOID SystemInit(VOID); - LITE_OS_SEC_TEXT_INIT STATIC UINT32 EarliestInit(VOID) { /* Must be placed at the beginning of the boot process */ @@ -286,6 +283,8 @@ STATIC VOID SystemInit(VOID) { PRINTK("dummy: *** %s ***\n", __FUNCTION__); } +#else +extern VOID SystemInit(VOID); #endif STATIC UINT32 OsSystemInitTaskCreate(VOID) @@ -309,8 +308,7 @@ STATIC UINT32 OsSystemInitTaskCreate(VOID) return LOS_TaskCreate(&taskID, &sysTask); } - -UINT32 OsSystemInit(VOID) +STATIC UINT32 OsSystemInit(VOID) { UINT32 ret; diff --git a/syscall/los_syscall.h b/syscall/los_syscall.h index 1926d733..106472cb 100644 --- a/syscall/los_syscall.h +++ b/syscall/los_syscall.h @@ -130,11 +130,11 @@ extern int SysMqNotify(mqd_t personal, const struct sigevent *sigev); #endif extern int SysSigAction(int sig, const sigaction_t *restrict sa, sigaction_t *restrict old, size_t sigsetsize); -extern int SysSigprocMask(int how, const sigset_t_l *restrict set, sigset_t *restrict old, size_t sigsetsize); +extern int SysSigprocMask(int how, const sigset_t_l *restrict setl, sigset_t_l *restrict oldl, size_t sigsetsize); extern int SysKill(pid_t pid, int sig); extern int SysPthreadKill(pid_t pid, int sig); -extern int SysSigTimedWait(const sigset_t *set, siginfo_t *info, - const struct timespec *timeoutsize_t, size_t sigsetsize); +extern int SysSigTimedWait(const sigset_t_l *setl, siginfo_t *info, + const struct timespec *timeout, size_t sigsetsize); extern int SysPause(void); extern int SysSigPending(sigset_t_l *setl); extern int SysSigSuspend(sigset_t_l *setl); @@ -167,8 +167,8 @@ extern ssize_t SysRecvMsg(int s, struct msghdr *message, int flags); /* vmm */ extern void *SysMmap(void *addr, size_t size, int prot, int flags, int fd, size_t offset); extern int SysMunmap(void *addr, size_t size); -extern int SysMprotect(vaddr_t vaddr, size_t len, int prot); -extern vaddr_t SysMremap(vaddr_t old_address, size_t old_size, size_t new_size, int flags, vaddr_t new_addr); +extern int SysMprotect(void *vaddr, size_t len, int prot); +extern void *SysMremap(void *oldAddr, size_t oldLen, size_t newLen, int flags, void *newAddr); extern void *SysBrk(void *addr); extern int SysShmGet(key_t key, size_t size, int shmflg); extern void *SysShmAt(int shmid, const void *shmaddr, int shmflg);