git.droids-corp.org
/
dpdk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
bus/pci: fix Windows kernel driver categories
[dpdk.git]
/
drivers
/
net
/
virtio
/
virtio_logs.h
diff --git
a/drivers/net/virtio/virtio_logs.h
b/drivers/net/virtio/virtio_logs.h
index
b52de73
..
9b1b1de
100644
(file)
--- a/
drivers/net/virtio/virtio_logs.h
+++ b/
drivers/net/virtio/virtio_logs.h
@@
-7,14
+7,12
@@
#include <rte_log.h>
#include <rte_log.h>
-#ifdef RTE_LIBRTE_VIRTIO_DEBUG_INIT
+extern int virtio_logtype_init;
#define PMD_INIT_LOG(level, fmt, args...) \
#define PMD_INIT_LOG(level, fmt, args...) \
- RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ## args)
+ rte_log(RTE_LOG_ ## level, virtio_logtype_init, \
+ "%s(): " fmt "\n", __func__, ##args)
+
#define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
#define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
-#else
-#define PMD_INIT_LOG(level, fmt, args...) do { } while(0)
-#define PMD_INIT_FUNC_TRACE() do { } while(0)
-#endif
#ifdef RTE_LIBRTE_VIRTIO_DEBUG_RX
#define PMD_RX_LOG(level, fmt, args...) \
#ifdef RTE_LIBRTE_VIRTIO_DEBUG_RX
#define PMD_RX_LOG(level, fmt, args...) \
@@
-30,12
+28,9
@@
#define PMD_TX_LOG(level, fmt, args...) do { } while(0)
#endif
#define PMD_TX_LOG(level, fmt, args...) do { } while(0)
#endif
-
-#ifdef RTE_LIBRTE_VIRTIO_DEBUG_DRIVER
+extern int virtio_logtype_driver;
#define PMD_DRV_LOG(level, fmt, args...) \
#define PMD_DRV_LOG(level, fmt, args...) \
- RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ## args)
-#else
-#define PMD_DRV_LOG(level, fmt, args...) do { } while(0)
-#endif
+ rte_log(RTE_LOG_ ## level, virtio_logtype_driver, \
+ "%s(): " fmt "\n", __func__, ## args)
#endif /* _VIRTIO_LOGS_H_ */
#endif /* _VIRTIO_LOGS_H_ */