1 /* SPDX-License-Identifier: BSD-3-Clause
2 * Copyright(c) 2010-2014 Intel Corporation
10 extern int e1000_logtype_init;
12 #define PMD_INIT_LOG(level, fmt, args...) \
13 rte_log(RTE_LOG_ ## level, e1000_logtype_init, \
14 "%s(): " fmt "\n", __func__, ##args)
16 #define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
18 #ifdef RTE_ETHDEV_DEBUG_RX
19 extern int e1000_logtype_rx;
20 #define PMD_RX_LOG(level, fmt, args...) \
21 rte_log(RTE_LOG_ ## level, e1000_logtype_rx, \
22 "%s(): " fmt "\n", __func__, ## args)
24 #define PMD_RX_LOG(level, fmt, args...) do { } while (0)
27 #ifdef RTE_ETHDEV_DEBUG_TX
28 extern int e1000_logtype_tx;
29 #define PMD_TX_LOG(level, fmt, args...) \
30 rte_log(RTE_LOG_ ## level, e1000_logtype_tx, \
31 "%s(): " fmt "\n", __func__, ## args)
33 #define PMD_TX_LOG(level, fmt, args...) do { } while (0)
36 extern int e1000_logtype_driver;
37 #define PMD_DRV_LOG_RAW(level, fmt, args...) \
38 rte_log(RTE_LOG_ ## level, e1000_logtype_driver, "%s(): " fmt, \
41 #define PMD_DRV_LOG(level, fmt, args...) \
42 PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
45 /* log init function shared by e1000 and igb drivers */
46 void e1000_igb_init_log(void);
48 #endif /* _E1000_LOGS_H_ */