From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 5E47FA0567; Wed, 10 Mar 2021 14:35:54 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id DDB344068C; Wed, 10 Mar 2021 14:35:53 +0100 (CET) Received: from wout5-smtp.messagingengine.com (wout5-smtp.messagingengine.com [64.147.123.21]) by mails.dpdk.org (Postfix) with ESMTP id 8307740687 for ; Wed, 10 Mar 2021 14:35:52 +0100 (CET) Received: from compute2.internal (compute2.nyi.internal [10.202.2.42]) by mailout.west.internal (Postfix) with ESMTP id 78DB719E0; Wed, 10 Mar 2021 08:35:51 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute2.internal (MEProxy); Wed, 10 Mar 2021 08:35:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=fm3; bh= Caovp2NfjuY4Bpo0vC6v7IsVnIFkXU8+L7910PMXNNQ=; b=tqzsy/jCACSgpl80 gqqpSq2IdYDxttq57Yxoc4sOvVzLwXP6o5I56j4ilOOIwooP/isJDaGwXrgvrgk3 MGds8nxRnBYwZ5SryQf5xRKpySl5ij14j09/e5zwF1ykERTDLgmJOlXO9eYCJ7Q4 twqD/i071rGzID6s/cxBXd7195h2RaG/5yEp+0uKLddORzNnWESZcDB3V8H+Yj0x CD/K0YV9prXJua0NxM55Fe+BwXykZONadKezO5YY0CuJivIJ55c3slVuBNABupcg hv/Q/CJ3EykiiblW78LPB8bxNCljL1dLUThCisBF72zUAkV9SlYyXmqZTQ3FDZgA TZUWkA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=Caovp2NfjuY4Bpo0vC6v7IsVnIFkXU8+L7910PMXN NQ=; b=MYWEzbN1oWTuD+e1Ba19cw1Uf5YxqSl7IXUV/AeiYzWmfIyqY93gyvs9E 5ihPldS5Y3bKIALWsG5r9guuyJFoJ5Hh6LOUPyQOkK9kKDwcCa+ow0D7TtIRdf8k QYE8sT4RylrfHZBwP/+9Ke7IXsnQ7pk/zqtWpHfNNMvmVnq0RJiP33RtbHZrXLuO Cvv/iaQooY30ZupnqlE4kYbx1RxHTy34D7vA4dh2cykYZxIdwIyyCTQPEToP/Qqo EUFXAfPFlmCMZ1wjZdHlYQZTnAmrZFKdr77co62ebGt/cTb0kaeQpb1j9LOag3Gk dVnhyPNA3Fj2kOfw0Bdn8WogH8yhA== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledruddukedgheehucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvufffkfgjfhgggfgtsehtufertddttddvnecuhfhrohhmpefvhhhomhgr shcuofhonhhjrghlohhnuceothhhohhmrghssehmohhnjhgrlhhonhdrnhgvtheqnecugg ftrfgrthhtvghrnhepudeggfdvfeduffdtfeeglefghfeukefgfffhueejtdetuedtjeeu ieeivdffgeehnecukfhppeejjedrudefgedrvddtfedrudekgeenucevlhhushhtvghruf hiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehthhhomhgrshesmhhonhhjrghl ohhnrdhnvght X-ME-Proxy: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 9DB021080054; Wed, 10 Mar 2021 08:35:48 -0500 (EST) From: Thomas Monjalon To: Bruce Richardson Cc: dev@dpdk.org, david.marchand@redhat.com Date: Wed, 10 Mar 2021 14:35:47 +0100 Message-ID: <3162311.zfhkGMNLAV@thomas> In-Reply-To: <20210310132652.GB1267@bricha3-MOBL.ger.corp.intel.com> References: <20210309233116.1934666-1-thomas@monjalon.net> <9127530.BAheoJpsKH@thomas> <20210310132652.GB1267@bricha3-MOBL.ger.corp.intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH 06/11] eal: catch invalid log level number X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 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" 10/03/2021 14:26, Bruce Richardson: > On Wed, Mar 10, 2021 at 01:33:20PM +0100, Thomas Monjalon wrote: > > 10/03/2021 13:19, Bruce Richardson: > > > On Wed, Mar 10, 2021 at 12:31:10AM +0100, Thomas Monjalon wrote: > > > > The parsing check for invalid log level was not trying to catch > > > > irrelevant numeric values. > > > > A log level 0 or too high is now a failure in options parsing > > > > so it can be caught early. > > > > > > > > Signed-off-by: Thomas Monjalon > > > > > > One thing I'd note here is that our log range of 1 to 8 is a little > > > strange, and that it would be nice if we could accept 9 as a valid log > > > level too on the cmdline. Ideally 0 would also be acceptable, for all > > > logging off, but it's more likely that people want to up the log level than > > > reduce it, and 9 is a more expected max value than 8. > > > > Why 9 is more expected? > > > > Because a scale of 0-9 is more logical in the decimal system. > We could also generalize that any number >8 is just reduced to 8 and > we issue a warning and continue. In this case, we should accept any high value, not limiting arbitrary to 9, and emit a warning.