mirror of
https://github.com/apache/nuttx.git
synced 2026-06-06 16:50:55 +08:00
Backing out some logic: Remove syslog functions from syscalls
This commit is contained in:
+10
-16
@@ -82,29 +82,23 @@
|
||||
#define SYS_sched_yield (CONFIG_SYS_RESERVED+12)
|
||||
#define SYS_set_errno (CONFIG_SYS_RESERVED+13)
|
||||
|
||||
/* SYSLOG */
|
||||
|
||||
#define SYS_syslog (CONFIG_SYS_RESERVED+14)
|
||||
#define SYS_lowsyslog (CONFIG_SYS_RESERVED+15)
|
||||
#define SYS_setlogmask (CONFIG_SYS_RESERVED+16)
|
||||
|
||||
/* Semaphores */
|
||||
|
||||
#define SYS_sem_destroy (CONFIG_SYS_RESERVED+17)
|
||||
#define SYS_sem_post (CONFIG_SYS_RESERVED+18)
|
||||
#define SYS_sem_timedwait (CONFIG_SYS_RESERVED+19)
|
||||
#define SYS_sem_trywait (CONFIG_SYS_RESERVED+20)
|
||||
#define SYS_sem_wait (CONFIG_SYS_RESERVED+21)
|
||||
#define SYS_sem_destroy (CONFIG_SYS_RESERVED+14)
|
||||
#define SYS_sem_post (CONFIG_SYS_RESERVED+15)
|
||||
#define SYS_sem_timedwait (CONFIG_SYS_RESERVED+16)
|
||||
#define SYS_sem_trywait (CONFIG_SYS_RESERVED+17)
|
||||
#define SYS_sem_wait (CONFIG_SYS_RESERVED+18)
|
||||
|
||||
/* Named semaphores */
|
||||
|
||||
#ifdef CONFIG_FS_NAMED_SEMAPHORES
|
||||
# define SYS_sem_open (CONFIG_SYS_RESERVED+22)
|
||||
# define SYS_sem_close (CONFIG_SYS_RESERVED+23)
|
||||
# define SYS_sem_unlink (CONFIG_SYS_RESERVED+24)
|
||||
# define __SYS_task_create (CONFIG_SYS_RESERVED+25)
|
||||
#else
|
||||
# define SYS_sem_open (CONFIG_SYS_RESERVED+19)
|
||||
# define SYS_sem_close (CONFIG_SYS_RESERVED+20)
|
||||
# define SYS_sem_unlink (CONFIG_SYS_RESERVED+21)
|
||||
# define __SYS_task_create (CONFIG_SYS_RESERVED+22)
|
||||
#else
|
||||
# define __SYS_task_create (CONFIG_SYS_RESERVED+19)
|
||||
#endif
|
||||
|
||||
/* Task creation APIs based on global entry points cannot be use with
|
||||
|
||||
+1
-26
@@ -49,25 +49,6 @@
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
****************************************************************************/
|
||||
/* Configuration ************************************************************/
|
||||
/* Some interfaces in this file are currently only available within the
|
||||
* kernel. They could are available to applications in the flat build and
|
||||
* could be made available in the protected and kernel builds IF system
|
||||
* calls were added.
|
||||
*
|
||||
* REVISIT: For example, I don't yet know how to pass a va_list in a system
|
||||
* call so none of those interfaces.
|
||||
*
|
||||
* NOTE: In protected and kernel builds, there may also be a limit to the
|
||||
* number of parameters that are supported in the variable parameter list.
|
||||
*/
|
||||
|
||||
#if !defined(CONFIG_BUILD_PROTECTED) && !defined(CONFIG_BUILD_KERNEL)
|
||||
# undef __KERNEL__
|
||||
# define __KERNEL__ 1
|
||||
#endif
|
||||
|
||||
/* syslog interface *********************************************************/
|
||||
/* The option argument to openlog() is an OR of any of these:
|
||||
*
|
||||
* LOG_CONS - Write directly to system console if there is an error
|
||||
@@ -156,9 +137,7 @@ void closelog(void);
|
||||
*/
|
||||
|
||||
int syslog(int priority, FAR const char *format, ...);
|
||||
#ifdef __KERNEL__
|
||||
int vsyslog(int priority, FAR const char *src, va_list ap);
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ARCH_LOWPUTC
|
||||
/* These are non-standard, low-level system logging interface. The
|
||||
@@ -172,9 +151,7 @@ int vsyslog(int priority, FAR const char *src, va_list ap);
|
||||
*/
|
||||
|
||||
int lowsyslog(int priority, FAR const char *format, ...);
|
||||
# ifdef __KERNEL__
|
||||
int lowvsyslog(int priority, FAR const char *format, va_list ap);
|
||||
# endif
|
||||
|
||||
#else
|
||||
/* If the platform cannot support lowsyslog, then we will substitute the
|
||||
@@ -188,9 +165,7 @@ int lowvsyslog(int priority, FAR const char *format, va_list ap);
|
||||
# else
|
||||
# define lowsyslog (void)
|
||||
# endif
|
||||
# ifdef __KERNEL__
|
||||
# define lowvsyslog(p,f,a) vsyslog(p,f,a)
|
||||
# endif
|
||||
# define lowvsyslog(p,f,a) vsyslog(p,f,a)
|
||||
#endif
|
||||
|
||||
/* The setlogmask() function sets the logmask and returns the previous
|
||||
|
||||
Reference in New Issue
Block a user