From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Zhang, Helin" Subject: Re: [PATCH] net/i40e: disable init and driver logs by default Date: Fri, 7 Apr 2017 02:03:19 +0000 Message-ID: References: <20170406141655.15097-1-olivier.matz@6wind.com> <20170406143642.GA9928@bricha3-MOBL3.ger.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Cc: Olivier Matz , "dev@dpdk.org" , "Wu, Jingjing" , "Yigit, Ferruh" To: "Richardson, Bruce" Return-path: Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id 5496F326C for ; Fri, 7 Apr 2017 04:03:24 +0200 (CEST) In-Reply-To: <20170406143642.GA9928@bricha3-MOBL3.ger.corp.intel.com> Content-Language: en-US List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" > -----Original Message----- > From: Richardson, Bruce > Sent: Thursday, April 6, 2017 10:37 PM > To: Zhang, Helin > Cc: Olivier Matz; dev@dpdk.org; Wu, Jingjing; Yigit, Ferruh > Subject: Re: [PATCH] net/i40e: disable init and driver logs by default >=20 > On Thu, Apr 06, 2017 at 03:31:23PM +0100, Zhang, Helin wrote: > > > > > > -----Original Message----- > > From: Olivier Matz [mailto:olivier.matz@6wind.com] > > Sent: Thursday, April 6, 2017 10:17 PM > > To: dev@dpdk.org > > Cc: Zhang, Helin ; Wu, Jingjing > > ; Richardson, Bruce > > ; Yigit, Ferruh > > Subject: [PATCH] net/i40e: disable init and driver logs by default > > > > Since "net/i40e: use dynamic log type for control logs", the i40e drive= r is > more verbose by default, which could result in testpmd being flooded by l= og > messages in some conditions: > > > > Checking link statuses... > > i40e_dev_handle_aq_msg(): Request 2561 is not supported yet > > i40e_dev_handle_aq_msg(): Request 2561 is not supported yet > > i40e_dev_handle_aq_msg(): Request 2561 is not supported yet > > i40e_dev_handle_aq_msg(): Request 2561 is not supported yet > > Port 0 Link Up - speed 40000 Mbps - full-duplex > > Port 1 Link Up - speed 40000 Mbps - full-duplex > > Done > > testpmd> i40e_dev_handle_aq_msg(): Request 4097 is not supported yet > > i40e_dev_handle_aq_msg(): Request 4097 is not supported yet > > i40e_dev_handle_aq_msg(): Request 4097 is not supported yet > > > > Fix this by disabling the dynamic logs by default. It is still possible= to enable > them at runtime. > > > > Fixes: c143e5a3d9e1 ("net/i40e: use dynamic log type for control > > logs") > > > > Signed-off-by: Olivier Matz > > Acked-by: Helin Zhang > > --- > > drivers/net/i40e/i40e_ethdev.c | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/drivers/net/i40e/i40e_ethdev.c > > b/drivers/net/i40e/i40e_ethdev.c index cb8bf2b49..86f5669f0 100644 > > --- a/drivers/net/i40e/i40e_ethdev.c > > +++ b/drivers/net/i40e/i40e_ethdev.c > > @@ -12456,8 +12456,8 @@ i40e_init_log(void) { > > i40e_logtype_init =3D rte_log_register("pmd.i40e.init"); > > if (i40e_logtype_init >=3D 0) > > - rte_log_set_level(i40e_logtype_init, RTE_LOG_NOTICE); > > + rte_log_set_level(i40e_logtype_init, RTE_LOG_EMERG); > > i40e_logtype_driver =3D rte_log_register("pmd.i40e.driver"); > > if (i40e_logtype_driver >=3D 0) > > - rte_log_set_level(i40e_logtype_driver, RTE_LOG_NOTICE); > > + rte_log_set_level(i40e_logtype_driver, RTE_LOG_EMERG); > > } > > -- >=20 > Hi Helin, >=20 > Is this the correct fix? IMHO, if this is a problem, then we should surel= y not be > hiding and ignoring the error. If it's not a problem, then the log level = should be > reduced to a lower level, e.g. INFO or NOTICE. >=20 > Alternatively, this code could be modified to only print an error once fo= r each > unsupported request type. >=20 > Ideally both solutions should be used, I think. I'm not sure I like setti= ng the > default log level to just show EMERG messages. >=20 > Regards, > /Bruce Bruce, this is not a fix for the issue, which is under investigation by dev= elopers now. For the by default log level, any guideline for that? I was OK with that changes, but not sure if there is any better choices. Regards, Helin