Commit Graph

30 Commits

Author SHA1 Message Date
yinshengkai 211a56910a syslog: support syslog redirection to sched_note
Signed-off-by: yinshengkai <yinshengkai@xiaomi.com>
2024-10-11 01:30:11 +08:00
Alin Jerpelea cd2fcf5252 include: migrate to SPDX identifier
Most tools used for compliance and SBOM generation use SPDX identifiers
This change brings us a step closer to an easy SBOM generation.

Signed-off-by: Alin Jerpelea <alin.jerpelea@sony.com>
2024-10-04 08:18:42 +08:00
zhanghongyu 31b2f9c40c syslog: add syslog option definition
adapts to third-party code compilation. in the process of porting ConnMan,
we encounter some situations where the structure is not defined, or the
returned data types do not match the expectations. Refer to the common
implementation of other systems and add relevant definitions.

Signed-off-by: zhanghongyu <zhanghongyu@xiaomi.com>
2023-05-05 18:36:36 +08:00
Xiang Xiao fd0d6a9bf5 compiler.h: Add _ between format|printf|syslog|scanf|strftime and like
align with other macro naming style

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
2022-12-21 01:05:19 +02:00
Abdelatif Guettouche 0f44e9539e include/debug.h/syslog.h: Fix small typos and repeated words
Signed-off-by: Abdelatif Guettouche <abdelatif.guettouche@espressif.com>
2021-03-22 06:06:44 -07:00
YAMAMOTO Takashi ed1a2584f0 include/syslog.h: Sprinkle sysloglike 2020-12-06 09:03:09 -06:00
Gregory Nutt 2b5ff17a85 setlogmask(): Add comments
In include/syslog.h and libs/libc/syslog/lib_setlogmask.c, add comments indicating tht setlogmask() is not thread-safe.
2020-05-11 11:32:55 -04:00
Xiang Xiao bd4e8e19d3 Run codespell -w against all files
and fix the wrong correction
2020-02-22 14:45:07 -06:00
Gregory Nutt de6b13b3ab Per OpenGroup.org, syslog -- and, hence, nonstandard vsyslog, and debug wrappers -- does not return a value. Rename _vsyslog to nx_vsyslog. Use internal nx_vsyslog in the few cases where a return value is required. 2018-03-04 08:07:07 -06:00
Anthony Merlino 058a938268 Merged in antmerlino/nuttx/logupto-fix (pull request #559)
syslog: Fixes LOG_UPTO macro to include specified log level

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-12-20 13:34:29 +00:00
Gregory Nutt ce42b0e030 include/syslog.h: Trivial change in name of formal parameter for consistency. 2017-11-18 19:26:38 -06:00
Gregory Nutt 28e9fe32b6 include/: Remove dangling space at the end of lines. 2017-06-28 13:30:08 -06:00
Gregory Nutt 0e1e3bc404 Add a file that I forgot in the last commit; Also update some comments. 2016-06-21 13:33:17 -06:00
Gregory Nutt 2b445ddccc Remove lowsyslog(). The new syslog() includes all of the functionality of lowsyslog(). No longer any need for two interfaces. 2016-06-20 08:57:08 -06:00
Gregory Nutt 5073bf1de6 Update some comments 2016-06-13 07:02:45 -06:00
Dimitry Kloper 06d83c6261 Introduce support for Atmel toolchain in-flash strings
Atmel toolchain AVR compiler provides a transparent in-flash object support using __flash and __memx symbols. The former indicates to compiler that this is a flash-based object.  The later used with pointer indicates that the referenced object may reside either in flash or in RAM. The compiler automatically makes 32-bit pointer with flag indicating whether referenced object is in flash or RAM and generates code to access either in run-time. Thus, any function that accepts __memx object can transparently work with RAM and flash objects.

For platforms with a Harvard architecture and a very small RAM like AVR this allows to move all constant strings used in trace messages to flash in the instruction address space, releasing resources for other things.

This change introduces IOBJ and IPTR type qualifiers.  The 'I' indicates that the object may like in instruction space on a Harvard architecture machine.

For platforms that do not have __flash and __memx or similar symbols IOBJ and IPTR are empty, making the types equivalent to, for example, 'const char' and 'const char*'.  For Atmel compiler these will become 'const __flash char' and 'const __memx char*'.  All printf() functions and syslog() functions are changed so that the qualifier is used with the format parameter.

From: Dimitry Kloper <dikloper@cisco.com>
2016-01-05 10:29:29 -06:00
Gregory Nutt cb9e27c3b0 Standardize naming used for public data and function groupings 2015-10-02 16:30:35 -06:00
Gregory Nutt 02444cfb2c Update comments and function headers 2014-10-09 07:38:38 -06:00
Gregory Nutt d2c8e13ed5 Backing out some logic: Remove syslog functions from syscalls 2014-10-09 06:58:23 -06:00
Gregory Nutt 4efb064169 Remove non-standard, conditional syslog_enable(), instead only the required, standard setlogmask() 2014-10-09 06:09:03 -06:00
Gregory Nutt bbc658930a Passing va_list in syscall does not work. Temporarily moved syslog and lowsyslog into kernel code and access via a system call. Need to revisit. Will probably need to move all of syslog back from fs/syslog to libc/syslog 2014-10-08 20:12:52 -06:00
Gregory Nutt 323084f32f Add syslog system calls 2014-10-08 19:37:10 -06:00
Gregory Nutt a8399d5c6b Move syslog logic from libc/misc and libc/stdio to libc/syslog 2014-10-08 17:16:41 -06:00
Gregory Nutt f40857c04f All NSH-related files under nuttx/configs changed to use the corrected syslog interfaces 2014-10-08 14:28:55 -06:00
Gregory Nutt 7b310711a1 Update everything under nuttx/arch to use the corrected syslog interfaces 2014-10-08 12:48:47 -06:00
Gregory Nutt 8db42f5b54 Update ChangeLog 2014-10-08 10:48:47 -06:00
Gregory Nutt f8ed7323c0 make standard syslog and vsyslog POSIX compliant (also modify non-standard syslog functions for compatibility). This will break a lot of things until ALL usage of syslog is updated to use the modified interfaces 2014-10-08 09:44:15 -06:00
Gregory Nutt 047deada84 Remove non-portable references to syslog from apps/examples 2014-10-08 08:33:00 -06:00
patacongo 95af0bc8bf Updated Open1788 calibration; More compilation fixes from Mike Smith
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5707 42af7a65-404d-4744-a932-0658087f49c3
2013-03-05 13:20:26 +00:00
patacongo ad430fc198 Add syslog.h; rename lib_rawprintf() to syslog()
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5578 42af7a65-404d-4744-a932-0658087f49c3
2013-01-28 21:55:16 +00:00