1 /* SPDX-License-Identifier: BSD-3-Clause
10 extern int dpaax_logger;
12 #ifdef RTE_LIBRTE_DPAAX_DEBUG
13 #define DPAAX_HWWARN(cond, fmt, args...) \
16 DPAAX_LOG(DEBUG, "WARN: " fmt, ##args); \
19 #define DPAAX_HWWARN(cond, fmt, args...) do { } while (0)
22 #define DPAAX_LOG(level, fmt, args...) \
23 rte_log(RTE_LOG_ ## level, dpaax_logger, "dpaax: " fmt "\n", \
26 /* Debug logs are with Function names */
27 #define DPAAX_DEBUG(fmt, args...) \
28 rte_log(RTE_LOG_DEBUG, dpaax_logger, "dpaax: %s(): " fmt "\n", \
31 #define DPAAX_INFO(fmt, args...) \
32 DPAAX_LOG(INFO, fmt, ## args)
33 #define DPAAX_ERR(fmt, args...) \
34 DPAAX_LOG(ERR, fmt, ## args)
35 #define DPAAX_WARN(fmt, args...) \
36 DPAAX_LOG(WARNING, fmt, ## args)
38 /* DP Logs, toggled out at compile time if level lower than current level */
39 #define DPAAX_DP_LOG(level, fmt, args...) \
40 RTE_LOG_DP(level, PMD, fmt, ## args)
42 #define DPAAX_DP_DEBUG(fmt, args...) \
43 DPAAX_DP_LOG(DEBUG, fmt, ## args)
44 #define DPAAX_DP_INFO(fmt, args...) \
45 DPAAX_DP_LOG(INFO, fmt, ## args)
46 #define DPAAX_DP_WARN(fmt, args...) \
47 DPAAX_DP_LOG(WARNING, fmt, ## args)
49 #endif /* _DPAAX_LOGS_H_ */