From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 5AF0DA046B for ; Mon, 19 Aug 2019 13:42:37 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id A29931BEC2; Mon, 19 Aug 2019 13:42:21 +0200 (CEST) Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id 58E401BEB9 for ; Mon, 19 Aug 2019 13:42:19 +0200 (CEST) Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id B44A57BDAC; Mon, 19 Aug 2019 11:42:18 +0000 (UTC) Received: from dmarchan.remote.csb (ovpn-204-32.brq.redhat.com [10.40.204.32]) by smtp.corp.redhat.com (Postfix) with ESMTP id A4E661001B17; Mon, 19 Aug 2019 11:42:17 +0000 (UTC) From: David Marchand To: dev@dpdk.org Cc: Nicolas Chautru Date: Mon, 19 Aug 2019 13:41:51 +0200 Message-Id: <1566214919-32250-4-git-send-email-david.marchand@redhat.com> In-Reply-To: <1566214919-32250-1-git-send-email-david.marchand@redhat.com> References: <1566214919-32250-1-git-send-email-david.marchand@redhat.com> X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.26]); Mon, 19 Aug 2019 11:42:18 +0000 (UTC) Subject: [dpdk-dev] [PATCH 03/11] drivers/baseband: use new logtype wrapper X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Make use of the newly introduced wrapper. Signed-off-by: David Marchand --- drivers/baseband/fpga_lte_fec/fpga_lte_fec.c | 11 ++++------- drivers/baseband/null/bbdev_null.c | 8 ++------ drivers/baseband/turbo_sw/bbdev_turbo_software.c | 8 ++------ 3 files changed, 8 insertions(+), 19 deletions(-) diff --git a/drivers/baseband/fpga_lte_fec/fpga_lte_fec.c b/drivers/baseband/fpga_lte_fec/fpga_lte_fec.c index 7e05b94..397ca8f 100644 --- a/drivers/baseband/fpga_lte_fec/fpga_lte_fec.c +++ b/drivers/baseband/fpga_lte_fec/fpga_lte_fec.c @@ -2663,13 +2663,10 @@ RTE_PMD_REGISTER_PCI(FPGA_LTE_FEC_VF_DRIVER_NAME, fpga_lte_fec_pci_vf_driver); RTE_PMD_REGISTER_PCI_TABLE(FPGA_LTE_FEC_VF_DRIVER_NAME, pci_id_fpga_lte_fec_vf_map); -RTE_INIT(fpga_lte_fec_init_log) -{ - fpga_lte_fec_logtype = rte_log_register("pmd.bb.fpga_lte_fec"); - if (fpga_lte_fec_logtype >= 0) +RTE_LOG_REGISTER(fpga_lte_fec_logtype, "pmd.bb.fpga_lte_fec", #ifdef RTE_LIBRTE_BBDEV_DEBUG - rte_log_set_level(fpga_lte_fec_logtype, RTE_LOG_DEBUG); + RTE_LOG_DEBUG #else - rte_log_set_level(fpga_lte_fec_logtype, RTE_LOG_NOTICE); + RTE_LOG_NOTICE #endif -} + , RTE_LOGTYPE_PMD); diff --git a/drivers/baseband/null/bbdev_null.c b/drivers/baseband/null/bbdev_null.c index 2f25151..029c308 100644 --- a/drivers/baseband/null/bbdev_null.c +++ b/drivers/baseband/null/bbdev_null.c @@ -348,9 +348,5 @@ RTE_PMD_REGISTER_PARAM_STRING(DRIVER_NAME, BBDEV_NULL_SOCKET_ID_ARG"="); RTE_PMD_REGISTER_ALIAS(DRIVER_NAME, bbdev_null); -RTE_INIT(null_bbdev_init_log) -{ - bbdev_null_logtype = rte_log_register("pmd.bb.null"); - if (bbdev_null_logtype >= 0) - rte_log_set_level(bbdev_null_logtype, RTE_LOG_NOTICE); -} +RTE_LOG_REGISTER(bbdev_null_logtype, "pmd.bb.null", + RTE_LOG_NOTICE, RTE_LOGTYPE_PMD); diff --git a/drivers/baseband/turbo_sw/bbdev_turbo_software.c b/drivers/baseband/turbo_sw/bbdev_turbo_software.c index f2fe7a2..fb0bbbe 100644 --- a/drivers/baseband/turbo_sw/bbdev_turbo_software.c +++ b/drivers/baseband/turbo_sw/bbdev_turbo_software.c @@ -1988,9 +1988,5 @@ RTE_PMD_REGISTER_PARAM_STRING(DRIVER_NAME, TURBO_SW_SOCKET_ID_ARG"="); RTE_PMD_REGISTER_ALIAS(DRIVER_NAME, turbo_sw); -RTE_INIT(turbo_sw_bbdev_init_log) -{ - bbdev_turbo_sw_logtype = rte_log_register("pmd.bb.turbo_sw"); - if (bbdev_turbo_sw_logtype >= 0) - rte_log_set_level(bbdev_turbo_sw_logtype, RTE_LOG_NOTICE); -} +RTE_LOG_REGISTER(bbdev_turbo_sw_logtype, "pmd.bb.turbo_sw", + RTE_LOG_NOTICE, RTE_LOGTYPE_PMD); -- 1.8.3.1