summaryrefslogtreecommitdiff
path: root/drivers/bus/dpaa/rte_dpaa_logs.h
diff options
context:
space:
mode:
authorSunil Kumar Kori <sunil.kori@nxp.com>2018-01-17 02:13:56 +0530
committerJerin Jacob <jerin.jacob@caviumnetworks.com>2018-01-19 16:09:56 +0100
commitad6628ac9b28e3a35abb4dd7935df0f4d4f45b09 (patch)
treec249698f606e209746c873a86db440cbcae9a293 /drivers/bus/dpaa/rte_dpaa_logs.h
parent43797e7b47741d58e5061255171f82a9d423bdf4 (diff)
downloaddpdk-ad6628ac9b28e3a35abb4dd7935df0f4d4f45b09.zip
dpdk-ad6628ac9b28e3a35abb4dd7935df0f4d4f45b09.tar.gz
dpdk-ad6628ac9b28e3a35abb4dd7935df0f4d4f45b09.tar.xz
bus/dpaa: support dynamic logging
Signed-off-by: Sunil Kumar Kori <sunil.kori@nxp.com> Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Diffstat (limited to 'drivers/bus/dpaa/rte_dpaa_logs.h')
-rw-r--r--drivers/bus/dpaa/rte_dpaa_logs.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/bus/dpaa/rte_dpaa_logs.h b/drivers/bus/dpaa/rte_dpaa_logs.h
index 5429864..0fd70bb 100644
--- a/drivers/bus/dpaa/rte_dpaa_logs.h
+++ b/drivers/bus/dpaa/rte_dpaa_logs.h
@@ -12,6 +12,7 @@
extern int dpaa_logtype_bus;
extern int dpaa_logtype_mempool;
extern int dpaa_logtype_pmd;
+extern int dpaa_logtype_eventdev;
#define DPAA_BUS_LOG(level, fmt, args...) \
rte_log(RTE_LOG_ ## level, dpaa_logtype_bus, "%s(): " fmt "\n", \
@@ -74,6 +75,21 @@ extern int dpaa_logtype_pmd;
#define DPAA_PMD_WARN(fmt, args...) \
DPAA_PMD_LOG(WARNING, fmt, ## args)
+#define DPAA_EVENTDEV_LOG(level, fmt, args...) \
+ rte_log(RTE_LOG_ ## level, dpaa_logtype_eventdev, "%s(): " fmt "\n", \
+ __func__, ##args)
+
+#define EVENTDEV_INIT_FUNC_TRACE() DPAA_EVENTDEV_LOG(DEBUG, " >>")
+
+#define DPAA_EVENTDEV_DEBUG(fmt, args...) \
+ DPAA_EVENTDEV_LOG(DEBUG, fmt, ## args)
+#define DPAA_EVENTDEV_ERR(fmt, args...) \
+ DPAA_EVENTDEV_LOG(ERR, fmt, ## args)
+#define DPAA_EVENTDEV_INFO(fmt, args...) \
+ DPAA_EVENTDEV_LOG(INFO, fmt, ## args)
+#define DPAA_EVENTDEV_WARN(fmt, args...) \
+ DPAA_EVENTDEV_LOG(WARNING, fmt, ## args)
+
/* DP Logs, toggled out at compile time if level lower than current level */
#define DPAA_DP_LOG(level, fmt, args...) \
RTE_LOG_DP(level, PMD, fmt, ## args)