From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by dpdk.org (Postfix) with ESMTP id 26D8B9400 for ; Fri, 13 Nov 2015 12:48:45 +0100 (CET) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga103.fm.intel.com with ESMTP; 13 Nov 2015 03:48:44 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,287,1444719600"; d="scan'208";a="849734155" Received: from irsmsx153.ger.corp.intel.com ([163.33.192.75]) by orsmga002.jf.intel.com with ESMTP; 13 Nov 2015 03:48:43 -0800 Received: from irsmsx105.ger.corp.intel.com ([169.254.7.203]) by IRSMSX153.ger.corp.intel.com ([169.254.9.208]) with mapi id 14.03.0248.002; Fri, 13 Nov 2015 11:48:41 +0000 From: "Ananyev, Konstantin" To: "Richardson, Bruce" , Matthew Hall Thread-Topic: [dpdk-dev] [PATCH 2/6] rte_log.h: add detailed log levels RTE_LOG{FINE, FINER, FINEST} Thread-Index: AQHRHgjDmkEGXZdB0kqF2PrEx44RSp6Z1bcA Date: Fri, 13 Nov 2015 11:48:41 +0000 Message-ID: <2601191342CEEE43887BDE71AB97725836AC8840@irsmsx105.ger.corp.intel.com> References: <1447397258-27233-1-git-send-email-mhall@mhcomputing.net> <1447397258-27233-3-git-send-email-mhall@mhcomputing.net> <20151113114402.GB15612@bricha3-MOBL3> In-Reply-To: <20151113114402.GB15612@bricha3-MOBL3> Accept-Language: en-IE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [163.33.239.182] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Cc: "dev@dpdk.org" Subject: Re: [dpdk-dev] [PATCH 2/6] rte_log.h: add detailed log levels RTE_LOG{FINE, FINER, FINEST} X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 13 Nov 2015 11:48:45 -0000 > -----Original Message----- > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Bruce Richardson > Sent: Friday, November 13, 2015 11:44 AM > To: Matthew Hall > Cc: dev@dpdk.org > Subject: Re: [dpdk-dev] [PATCH 2/6] rte_log.h: add detailed log levels RT= E_LOG{FINE, FINER, FINEST} >=20 > On Fri, Nov 13, 2015 at 06:47:34AM +0000, Matthew Hall wrote: > > Signed-off-by: Matthew Hall > > --- > > lib/librte_eal/common/include/rte_log.h | 19 +++++++++++-------- > > 1 file changed, 11 insertions(+), 8 deletions(-) > > > > diff --git a/lib/librte_eal/common/include/rte_log.h b/lib/librte_eal/c= ommon/include/rte_log.h > > index 9dad24e..7dc19e1 100644 > > --- a/lib/librte_eal/common/include/rte_log.h > > +++ b/lib/librte_eal/common/include/rte_log.h > > @@ -90,14 +90,17 @@ extern struct rte_logs rte_logs; > > #define RTE_LOGTYPE_USER8 0x80000000 /**< User-defined log type 8. *= / > > > > /* Can't use 0, as it gives compiler warnings */ > > -#define RTE_LOG_EMERG 1U /**< System is unusable. */ > > -#define RTE_LOG_ALERT 2U /**< Action must be taken immediately. */ > > -#define RTE_LOG_CRIT 3U /**< Critical conditions. */ > > -#define RTE_LOG_ERR 4U /**< Error conditions. */ > > -#define RTE_LOG_WARNING 5U /**< Warning conditions. */ > > -#define RTE_LOG_NOTICE 6U /**< Normal but significant condition. */ > > -#define RTE_LOG_INFO 7U /**< Informational. */ > > -#define RTE_LOG_DEBUG 8U /**< Debug-level messages. */ > > +#define RTE_LOG_EMERG 1U /**< System is unusable. *= / > > +#define RTE_LOG_ALERT 2U /**< Action must be taken immediately. *= / > > +#define RTE_LOG_CRIT 3U /**< Critical conditions. *= / > > +#define RTE_LOG_ERR 4U /**< Error conditions. *= / > > +#define RTE_LOG_WARNING 5U /**< Warning conditions. *= / > > +#define RTE_LOG_NOTICE 6U /**< Normal but significant condition. *= / > > +#define RTE_LOG_INFO 7U /**< Informational. *= / > > +#define RTE_LOG_DEBUG 8U /**< Debug-level messages. *= / > > +#define RTE_LOG_FINE 9U /**< Fine-level messages. *= / > > +#define RTE_LOG_FINER 10U /**< Finer-level messages. *= / > > +#define RTE_LOG_FINEST 11U /**< Finest-level messages. *= / > > > > /** The default log stream. */ > > extern FILE *eal_default_log_stream; > > -- > > 1.9.1 > > > Why 11 log levels - it seems an odd number? > Also, not sure about the {fine, finer, finest} names. My thinking would b= e to > just start numbering them after DEBUG, so RTE_LOG_L9, RTE_LOG_L10 etc., w= hich > would allow us to add on an arbitrary number of extra log levels as neede= d. Actually another question: are existing 8 levels not enough? Konstantin =20 >=20 > /Bruce