fe716d3802
Build log: error: unused variable ‘cid’ error: ‘RTE_LOG_WARN’ undeclared error: expected ‘)’ before ‘sc’ There were unused variables defined for debug but not used in debug log because it was ifdef'ed a the wrong condition (RTE_LIBRTE_BNX2X_DEBUG_DRIVER). The warning were using WARN instead of WARNING. Some debug messages had some extra parameters. Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
51 lines
1.3 KiB
C
51 lines
1.3 KiB
C
/*
|
|
* Copyright (c) 2013-2015 Brocade Communications Systems, Inc.
|
|
*
|
|
* All rights reserved.
|
|
*/
|
|
|
|
#ifndef _PMD_LOGS_H_
|
|
#define _PMD_LOGS_H_
|
|
|
|
#define PMD_INIT_LOG(level, fmt, args...) \
|
|
RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ##args)
|
|
|
|
#ifdef RTE_LIBRTE_BNX2X_DEBUG_INIT
|
|
#define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>")
|
|
#else
|
|
#define PMD_INIT_FUNC_TRACE() do { } while(0)
|
|
#endif
|
|
|
|
#ifdef RTE_LIBRTE_BNX2X_DEBUG_RX
|
|
#define PMD_RX_LOG(level, fmt, args...) \
|
|
RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ## args)
|
|
#else
|
|
#define PMD_RX_LOG(level, fmt, args...) do { } while(0)
|
|
#endif
|
|
|
|
#ifdef RTE_LIBRTE_BNX2X_DEBUG_TX
|
|
#define PMD_TX_LOG(level, fmt, args...) \
|
|
RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ## args)
|
|
#else
|
|
#define PMD_TX_LOG(level, fmt, args...) do { } while(0)
|
|
#endif
|
|
|
|
#ifdef RTE_LIBRTE_BNX2X_DEBUG_TX_FREE
|
|
#define PMD_TX_FREE_LOG(level, fmt, args...) \
|
|
RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ## args)
|
|
#else
|
|
#define PMD_TX_FREE_LOG(level, fmt, args...) do { } while(0)
|
|
#endif
|
|
|
|
#ifdef RTE_LIBRTE_BNX2X_DEBUG
|
|
#define PMD_DRV_LOG_RAW(level, fmt, args...) \
|
|
RTE_LOG(level, PMD, "%s(): " fmt, __func__, ## args)
|
|
#else
|
|
#define PMD_DRV_LOG_RAW(level, fmt, args...) do { } while (0)
|
|
#endif
|
|
|
|
#define PMD_DRV_LOG(level, fmt, args...) \
|
|
PMD_DRV_LOG_RAW(level, fmt "\n", ## args)
|
|
|
|
#endif /* _PMD_LOGS_H_ */
|