From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dispatch1-us1.ppe-hosted.com (dispatch1-us1.ppe-hosted.com [67.231.154.164]) by dpdk.org (Postfix) with ESMTP id 12A971B4EF for ; Thu, 2 Aug 2018 20:02:08 +0200 (CEST) X-Virus-Scanned: Proofpoint Essentials engine Received: from webmail.solarflare.com (uk.solarflare.com [193.34.186.16]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1-us3.ppe-hosted.com (Proofpoint Essentials ESMTP Server) with ESMTPS id 0F9326C0092; Thu, 2 Aug 2018 18:02:06 +0000 (UTC) Received: from [192.168.1.16] (85.187.13.33) by ukex01.SolarFlarecom.com (10.17.10.4) with Microsoft SMTP Server (TLS) id 15.0.1044.25; Thu, 2 Aug 2018 19:01:59 +0100 To: Thomas Monjalon , Kevin Traynor CC: , Ferruh Yigit , Stephen Hemminger References: <1533213223-24028-1-git-send-email-ktraynor@redhat.com> <00c35ad3-e063-b14e-ef56-e4308ec83f52@solarflare.com> <581602cf-36ba-2d6f-03ab-b00e9817f2a8@redhat.com> <7727240.AGfPpAcRVp@xps> From: Andrew Rybchenko Message-ID: Date: Thu, 2 Aug 2018 21:01:54 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <7727240.AGfPpAcRVp@xps> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-Originating-IP: [85.187.13.33] X-ClientProxiedBy: ocex03.SolarFlarecom.com (10.20.40.36) To ukex01.SolarFlarecom.com (10.17.10.4) X-TM-AS-Product-Ver: SMEX-12.5.0.1300-8.5.1010-24006.003 X-TM-AS-Result: No-20.661200-8.000000-10 X-TMASE-MatchedRID: +f/wAVSGjugOwH4pD14DsPHkpkyUphL9WjRJreaOWv42/UwdvFG5Ih8+ XHETeZCzgsUtzIjIFbmEBaSLhxtkgQ/thUNmOVzLHPYwOJi6PLlu95mt47DzNiG8WMGwsRk0ZyI JeulfX4y+T2YjENM30rMoUKcwij07OrPgsAyL7VFHpZCc205uwoEcpMn6x9cZMS6w7X01lW1p7t +5+RfYoUZdCOezrJrUKjAaBfogMSyPLG+A0qvEpgIKV2KH2USqo4jW7zSDg9nceXQ6q2ggSjiWb 5Ag5WeYxdMDEDSgbA91/HefkbbFqezfDnrf58Pw4RtSDjG+z7C8n1e+HkKZPrJwSrL3STXLo8WM kQWv6iWhMIDkR/KfwI2j49Ftap9EkGUtrowrXLg= X-TM-AS-User-Approved-Sender: Yes X-TM-AS-User-Blocked-Sender: No X-TMASE-Result: 10--20.661200-8.000000 X-TMASE-Version: SMEX-12.5.0.1300-8.5.1010-24006.003 X-MDID: 1533232926-DANiM9ErR1Ph Subject: Re: [dpdk-dev] [PATCH] ethdev: decrease log level for successful API 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: , X-List-Received-Date: Thu, 02 Aug 2018 18:02:08 -0000 On 02.08.2018 19:14, Thomas Monjalon wrote: > 02/08/2018 16:52, Kevin Traynor: >> On 08/02/2018 03:41 PM, Andrew Rybchenko wrote: >>> On 02.08.2018 17:09, Kevin Traynor wrote: >>>> On 08/02/2018 02:52 PM, Andrew Rybchenko wrote: >>>>> On 02.08.2018 16:35, Kevin Traynor wrote: >>>>>> On 08/02/2018 01:59 PM, Andrew Rybchenko wrote: >>>>>>> On 02.08.2018 15:33, Kevin Traynor wrote: >>>>>>>> @@ -1319,5 +1319,5 @@ struct rte_eth_dev * >>>>>>>> if (dev->data->dev_started == 0) { >>>>>>>> - RTE_ETHDEV_LOG(ERR, >>>>>>>> + RTE_ETHDEV_LOG(DEBUG, >>>>>>>> "Device with port_id=%"PRIu16" already stopped\n", >>>>>>>> port_id); >>>>>>> I would suggest to use WARNING here. Yes, it is not an error since >>>>>>> nothing bad has >>>>>>> happened and we handle duplicate stop and duplicate start, >>>>>>> but I think it is bad that (buggy?) application does it. Making it >>>>>>> debug >>>>>>> we simply >>>>>>> hide it too much. >>>>>>> >>>>>> I think an application following the documented API is not bad or >>>>>> buggy. >>>>> I've failed to find the place were it is documented that device/queue >>>>> may be stopped/started twice. Could you point out? >>>>> Yes, return value 0 means success, but it is a separate thing. >>>>> >>>> I was commenting directly on the API and it's documentation e.g. below >>>> for dev start. I'm not aware of other documentation specifying how it >>>> can/cannot be called. >>> I would not say so. "0: Success. Ethernet device started" means that >>> function managed to do the job and finally the device is started. >>> >>> Never-mind it is not that important and already paid to much attention. >>> I've included in CC other ethdev maintainers (who should be there from >>> the very beginning). I don't mind if it is acked by other ethdev maintainer >>> and applied. It is definitely not an error as it is now. Thanks. >>> >> Sure, sounds good - I'm glad we agree on something :-) I'll leave it for >> a day and can re-spin tomorrow. > I would like to give an opinion, but unfortunately it's hard to decide. > For sure, it should not be a WARNING level (used for non-fatal errors). > What else do we have? NOTICE, INFO and DEBUG. > I think it can be INFO. So, we have ERR (now), WARNING (my initial suggestion), NOTICE (by Stephen), INFO (by Thomas) and DEBUG (by Kevin)  :) If it is not treated as an error in application behaviour, I agree that my suggestion of WARNING is not suitable. Typically NOTICE is the default log level and if we consider such behaviour of apps correct, it should be INFO to be silent by default. I really don't like DEBUG since these messages are still important and could be simply lost in DEBUG which could to be very-very verbose.