/* SPDX-License-Identifier: BSD-3-Clause
- * Copyright(c) 2015-2020
+ * Copyright(c) 2015-2020 Beijing WangXun Technology Co., Ltd.
+ * Copyright(c) 2010-2017 Intel Corporation
*/
#ifndef _TXGBE_LOGS_H_
#define _TXGBE_LOGS_H_
+#include <inttypes.h>
+
/*
* PMD_USER_LOG: for user
*/
#define PMD_TX_FREE_LOG(level, fmt, args...) do { } while (0)
#endif
-#define TLOG_DEBUG(fmt, args...) PMD_DRV_LOG(DEBUG, fmt, ##args)
+#define DEBUGOUT(fmt, args...) PMD_DRV_LOG(DEBUG, fmt, ##args)
+#define PMD_INIT_FUNC_TRACE() PMD_DRV_LOG(DEBUG, ">>")
-#define DEBUGOUT(fmt, args...) TLOG_DEBUG(fmt, ##args)
-#define PMD_INIT_FUNC_TRACE() TLOG_DEBUG(" >>")
-#define DEBUGFUNC(fmt) TLOG_DEBUG(fmt)
+extern int txgbe_logtype_bp;
+#define BP_LOG(fmt, args...) \
+ rte_log(RTE_LOG_DEBUG, txgbe_logtype_bp, \
+ "[%"PRIu64".%"PRIu64"]%s(%d): " fmt, \
+ usec_stamp() / 1000000, usec_stamp() % 1000000, \
+ __func__, __LINE__, ##args)
#endif /* _TXGBE_LOGS_H_ */