1 /* SPDX-License-Identifier: BSD-3-Clause
2 * Copyright(c) 2010-2015 Intel Corporation
8 extern int i40e_logtype_init;
9 #define PMD_INIT_LOG(level, fmt, args...) \
10 rte_log(RTE_LOG_ ## level, i40e_logtype_init, "%s(): " fmt "\n", \
12 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
14 #ifdef RTE_LIBRTE_I40E_DEBUG_RX
15 extern int i40e_logtype_rx;
16 #define PMD_RX_LOG(level, fmt, args...) \
17 rte_log(RTE_LOG_ ## level, i40e_logtype_rx, \
18 "%s(): " fmt "\n", __func__, ## args)
20 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
23 #ifdef RTE_LIBRTE_I40E_DEBUG_TX
24 extern int i40e_logtype_tx;
25 #define PMD_TX_LOG(level, fmt, args...) \
26 rte_log(RTE_LOG_ ## level, i40e_logtype_tx, \
27 "%s(): " fmt "\n", __func__, ## args)
29 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
32 #ifdef RTE_LIBRTE_I40E_DEBUG_TX_FREE
33 extern int i40e_logtype_tx_free;
34 #define PMD_TX_FREE_LOG(level, fmt, args...) \
35 rte_log(RTE_LOG_ ## level, i40e_logtype_tx_free, \
36 "%s(): " fmt "\n", __func__, ## args)
38 #define PMD_TX_FREE_LOG(level, fmt, args...) do { } while (0)
41 extern int i40e_logtype_driver;
42 #define PMD_DRV_LOG_RAW(level, fmt, args...) \
43 rte_log(RTE_LOG_ ## level, i40e_logtype_driver, "%s(): " fmt, \
46 #define PMD_DRV_LOG(level, fmt, args...) \
47 PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
49 #endif /* _I40E_LOGS_H_ */