numam-dpdk/drivers/common/qat/qat_logs.c
Thomas Monjalon b164198729 drivers: align log names
The log levels are configured by using the name of the logs.
Some drivers are aligned to follow a common log name standard:
	pmd.class.driver[.sub]
Some "common" drivers skip the "class" part:
	pmd.driver.sub

Signed-off-by: Thomas Monjalon <thomas@monjalon.net>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
Acked-by: Rosen Xu <rosen.xu@intel.com>
Acked-by: Xiao Wang <xiao.w.wang@intel.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Acked-by: Min Hu (Connor) <humin29@huawei.com>
2021-04-08 18:32:31 +02:00

22 lines
488 B
C

/* SPDX-License-Identifier: BSD-3-Clause
* Copyright(c) 2018 Intel Corporation
*/
#include <rte_log.h>
#include <rte_hexdump.h>
#include "qat_logs.h"
int
qat_hexdump_log(uint32_t level, uint32_t logtype, const char *title,
const void *buf, unsigned int len)
{
if (rte_log_can_log(logtype, level))
rte_hexdump(rte_log_get_stream(), title, buf, len);
return 0;
}
RTE_LOG_REGISTER(qat_gen_logtype, pmd.qat.general, NOTICE);
RTE_LOG_REGISTER(qat_dp_logtype, pmd.qat.dp, NOTICE);