Message ID | 1472123147-22997-1-git-send-email-ferruh.yigit@intel.com (mailing list archive) |
---|---|
State | Superseded, archived |
Headers |
Return-Path: <dev-bounces@dpdk.org> X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [IPv6:::1]) by dpdk.org (Postfix) with ESMTP id 9134C559A; Thu, 25 Aug 2016 13:05:53 +0200 (CEST) Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by dpdk.org (Postfix) with ESMTP id 266765599 for <dev@dpdk.org>; Thu, 25 Aug 2016 13:05:51 +0200 (CEST) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga103.fm.intel.com with ESMTP; 25 Aug 2016 04:05:50 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.28,575,1464678000"; d="scan'208";a="753330850" Received: from irvmail001.ir.intel.com ([163.33.26.43]) by FMSMGA003.fm.intel.com with ESMTP; 25 Aug 2016 04:05:49 -0700 Received: from sivswdev02.ir.intel.com (sivswdev02.ir.intel.com [10.237.217.46]) by irvmail001.ir.intel.com (8.14.3/8.13.6/MailSET/Hub) with ESMTP id u7PB5mMc004746; Thu, 25 Aug 2016 12:05:48 +0100 Received: from sivswdev02.ir.intel.com (localhost [127.0.0.1]) by sivswdev02.ir.intel.com with ESMTP id u7PB5m7Q023031; Thu, 25 Aug 2016 12:05:48 +0100 Received: (from fyigit@localhost) by sivswdev02.ir.intel.com with id u7PB5m1T023027; Thu, 25 Aug 2016 12:05:48 +0100 X-Authentication-Warning: sivswdev02.ir.intel.com: fyigit set sender to ferruh.yigit@intel.com using -f From: Ferruh Yigit <ferruh.yigit@intel.com> To: dev@dpdk.org Cc: Stephen Hurd <stephen.hurd@broadcom.com> Date: Thu, 25 Aug 2016 12:05:47 +0100 Message-Id: <1472123147-22997-1-git-send-email-ferruh.yigit@intel.com> X-Mailer: git-send-email 1.7.4.1 Subject: [dpdk-dev] [PATCH] net/bnxt: make driver less verbose X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK <dev.dpdk.org> List-Unsubscribe: <http://dpdk.org/ml/options/dev>, <mailto:dev-request@dpdk.org?subject=unsubscribe> List-Archive: <http://dpdk.org/ml/archives/dev/> List-Post: <mailto:dev@dpdk.org> List-Help: <mailto:dev-request@dpdk.org?subject=help> List-Subscribe: <http://dpdk.org/ml/listinfo/dev>, <mailto:dev-request@dpdk.org?subject=subscribe> Errors-To: dev-bounces@dpdk.org Sender: "dev" <dev-bounces@dpdk.org> |
Commit Message
Ferruh Yigit
Aug. 25, 2016, 11:05 a.m. UTC
This line printed for every application even if driver is not used at
all. Removing the line to reduce the noise.
Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com>
---
drivers/net/bnxt/bnxt_ethdev.c | 1 -
1 file changed, 1 deletion(-)
Comments
On Thu, Aug 25, 2016 at 6:05 AM, Ferruh Yigit <ferruh.yigit@intel.com> wrote: > This line printed for every application even if driver is not used at > all. Removing the line to reduce the noise. > > Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com> > --- > drivers/net/bnxt/bnxt_ethdev.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/drivers/net/bnxt/bnxt_ethdev.c b/drivers/net/bnxt/bnxt_ > ethdev.c > index 3795fac..37d0322 100644 > --- a/drivers/net/bnxt/bnxt_ethdev.c > +++ b/drivers/net/bnxt/bnxt_ethdev.c > @@ -1056,7 +1056,6 @@ static struct eth_driver bnxt_rte_pmd = { > > static int bnxt_rte_pmd_init(const char *name, const char *params > __rte_unused) > { > - RTE_LOG(INFO, PMD, "bnxt_rte_pmd_init() called for %s\n", name); > How about changing the log level to DEBUG? - RTE_LOG(INFO, PMD, "bnxt_rte_pmd_init() called for %s\n", name); + RTE_LOG(DEBUG, PMD, "bnxt_rte_pmd_init() called for %s\n", name); That should reduce the noise till the user explicitly changes the log level. Thanks > rte_eth_driver_register(&bnxt_rte_pmd); > return 0; > } > -- > 2.7.4 > >
On 8/25/2016 8:03 PM, Ajit Khaparde wrote: > > > On Thu, Aug 25, 2016 at 6:05 AM, Ferruh Yigit <ferruh.yigit@intel.com > <mailto:ferruh.yigit@intel.com>> wrote: > > This line printed for every application even if driver is not used at > all. Removing the line to reduce the noise. > > Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com > <mailto:ferruh.yigit@intel.com>> > --- > drivers/net/bnxt/bnxt_ethdev.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/drivers/net/bnxt/bnxt_ethdev.c > b/drivers/net/bnxt/bnxt_ethdev.c > index 3795fac..37d0322 100644 > --- a/drivers/net/bnxt/bnxt_ethdev.c > +++ b/drivers/net/bnxt/bnxt_ethdev.c > @@ -1056,7 +1056,6 @@ static struct eth_driver bnxt_rte_pmd = { > > static int bnxt_rte_pmd_init(const char *name, const char *params > __rte_unused) > { > - RTE_LOG(INFO, PMD, "bnxt_rte_pmd_init() called for %s\n", name); > > How about changing the log level to DEBUG? > > - RTE_LOG(INFO, PMD, "bnxt_rte_pmd_init() called for %s\n", name); > + RTE_LOG(DEBUG, PMD, "bnxt_rte_pmd_init() called for %s\n", name); > > That should reduce the noise till the user explicitly changes the log level. This will give similar result, this log is useless if you are not debugging this driver, but debug log level can be enabled for many reasons. Other drivers use PMD_INIT_FUNC_TRACE() macros, which requires specifically enabled in config for that driver. > > Thanks > > > > rte_eth_driver_register(&bnxt_rte_pmd); > return 0; > } > -- > 2.7.4 > >
On Fri, Aug 26, 2016 at 3:39 AM, Ferruh Yigit <ferruh.yigit@intel.com> wrote: > On 8/25/2016 8:03 PM, Ajit Khaparde wrote: > > > > > > On Thu, Aug 25, 2016 at 6:05 AM, Ferruh Yigit <ferruh.yigit@intel.com > > <mailto:ferruh.yigit@intel.com>> wrote: > > > > This line printed for every application even if driver is not used at > > all. Removing the line to reduce the noise. > > > > Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com > > <mailto:ferruh.yigit@intel.com>> > > --- > > drivers/net/bnxt/bnxt_ethdev.c | 1 - > > 1 file changed, 1 deletion(-) > > > > diff --git a/drivers/net/bnxt/bnxt_ethdev.c > > b/drivers/net/bnxt/bnxt_ethdev.c > > index 3795fac..37d0322 100644 > > --- a/drivers/net/bnxt/bnxt_ethdev.c > > +++ b/drivers/net/bnxt/bnxt_ethdev.c > > @@ -1056,7 +1056,6 @@ static struct eth_driver bnxt_rte_pmd = { > > > > static int bnxt_rte_pmd_init(const char *name, const char *params > > __rte_unused) > > { > > - RTE_LOG(INFO, PMD, "bnxt_rte_pmd_init() called for %s\n", > name); > > > > How about changing the log level to DEBUG? > > > > - RTE_LOG(INFO, PMD, "bnxt_rte_pmd_init() called for %s\n", name); > > + RTE_LOG(DEBUG, PMD, "bnxt_rte_pmd_init() called for %s\n", name); > > > > That should reduce the noise till the user explicitly changes the log > level. > > This will give similar result, this log is useless if you are not > debugging this driver, but debug log level can be enabled for many reasons. > > Other drivers use PMD_INIT_FUNC_TRACE() macros, which requires > specifically enabled in config for that driver. > There are other messages to aid tracing and debugging elsewhere in the code. So here goes.. Acked-by: Ajit Khaparde <ajit.khaparde@broadcom.com> > > > > > Thanks > > > > > > > > rte_eth_driver_register(&bnxt_rte_pmd); > > return 0; > > } > > -- > > 2.7.4 > > > > > >
On Thu, Aug 25, 2016 at 12:05:47PM +0100, Ferruh Yigit wrote: > This line printed for every application even if driver is not used at > all. Removing the line to reduce the noise. > > Signed-off-by: Ferruh Yigit <ferruh.yigit@intel.com> > --- > drivers/net/bnxt/bnxt_ethdev.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/drivers/net/bnxt/bnxt_ethdev.c b/drivers/net/bnxt/bnxt_ethdev.c > index 3795fac..37d0322 100644 > --- a/drivers/net/bnxt/bnxt_ethdev.c > +++ b/drivers/net/bnxt/bnxt_ethdev.c > @@ -1056,7 +1056,6 @@ static struct eth_driver bnxt_rte_pmd = { > > static int bnxt_rte_pmd_init(const char *name, const char *params __rte_unused) > { > - RTE_LOG(INFO, PMD, "bnxt_rte_pmd_init() called for %s\n", name); Hi, FYI, my testrobot caught some errors when this patch is applied. --yliu --- /root/dpdk/drivers/net/bnxt/bnxt_ethdev.c:1057:42: error: unused parameter 'name' [-Werror,-Wunused-parameter] static int bnxt_rte_pmd_init(const char *name, const char *params __rte_unused) ^ 1 error generated. make[6]: *** [bnxt_ethdev.o] Error 1 make[5]: *** [bnxt] Error 2 make[5]: *** Waiting for unfinished jobs.... make[4]: *** [net] Error 2 make[3]: *** [drivers] Error 2 make[2]: *** [all] Error 2 make[1]: *** [pre_install] Error 2 make: *** [install] Error 2 error: build failed
diff --git a/drivers/net/bnxt/bnxt_ethdev.c b/drivers/net/bnxt/bnxt_ethdev.c index 3795fac..37d0322 100644 --- a/drivers/net/bnxt/bnxt_ethdev.c +++ b/drivers/net/bnxt/bnxt_ethdev.c @@ -1056,7 +1056,6 @@ static struct eth_driver bnxt_rte_pmd = { static int bnxt_rte_pmd_init(const char *name, const char *params __rte_unused) { - RTE_LOG(INFO, PMD, "bnxt_rte_pmd_init() called for %s\n", name); rte_eth_driver_register(&bnxt_rte_pmd); return 0; }