1 /* SPDX-License-Identifier: BSD-3-Clause 2 * Copyright 2021 Mellanox Technologies, Ltd 3 */ 4 5 #ifndef LOG_INTERNAL_H 6 #define LOG_INTERNAL_H 7 8 #include <stdio.h> 9 #include <stdint.h> 10 11 #include <rte_compat.h> 12 13 /* 14 * Initialize the default log stream. 15 */ 16 __rte_internal 17 void eal_log_init(const char *id); 18 19 /* 20 * Save a log option for later. 21 */ 22 __rte_internal 23 int eal_log_save_regexp(const char *regexp, uint32_t level); 24 __rte_internal 25 int eal_log_save_pattern(const char *pattern, uint32_t level); 26 27 __rte_internal 28 int eal_log_syslog(const char *name); 29 30 /* 31 * Convert log level to string. 32 */ 33 __rte_internal 34 const char *eal_log_level2str(uint32_t level); 35 36 /* 37 * Close the default log stream 38 */ 39 __rte_internal 40 void rte_eal_log_cleanup(void); 41 42 #endif /* LOG_INTERNAL_H */ 43