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 48CD84332B; Tue, 14 Nov 2023 15:37:56 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 378DF4027B; Tue, 14 Nov 2023 15:37:56 +0100 (CET) Received: from wout3-smtp.messagingengine.com (wout3-smtp.messagingengine.com [64.147.123.19]) by mails.dpdk.org (Postfix) with ESMTP id 620A340279 for ; Tue, 14 Nov 2023 15:37:54 +0100 (CET) Received: from compute2.internal (compute2.nyi.internal [10.202.2.46]) by mailout.west.internal (Postfix) with ESMTP id 140AA3202335; Tue, 14 Nov 2023 09:37:52 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute2.internal (MEProxy); Tue, 14 Nov 2023 09:37:53 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= cc:cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to; s=fm1; t= 1699972672; x=1700059072; bh=3c8rh6yNMbtVHpeh0hSgvV1A5cMDvNj+WWE MhfFDf6w=; b=V/ZD4Yo7rYR4gI+UQ5+w+8q1G6tJAsTbv+aJeVLt3hjHDIUF4dO txH8IOLRa8ynKzp5FwGH+nhCiNRNlHprfp4fKAfI9SKuRcBbmq30hKpC3fsidNJ0 vtYJe0tNBoYoCyiytiylgMthKojFPgDXbix64ebcOVjUiiZqsOPfo9SwMMyJBDGi r8yWTM50In+HjDqQnGH3DFGfZxJKHod1HCihlYCERxe+5pzOGvwbBVmxuliKmX5M 9lD7q9FXFhvlh63dPSVivZl/BEQOOxIUD3t+cQzd+Im85QgDlC3Gyp/s+Dlt19F3 ZYM9LIkGXX7zEg0lDo9lxBUsRTZxhL6ApcQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:sender:subject:subject:to:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t= 1699972672; x=1700059072; bh=3c8rh6yNMbtVHpeh0hSgvV1A5cMDvNj+WWE MhfFDf6w=; b=2XAUGvd4ptz1qsVO1h64VLLuMwtX7jo83aZMj9NIYC2ZpTYjmxa uMd3cV7WmscggTUQdK2uwun1eUjBc5J5qfXxQKayGTorjSe8EqPcKzi9WsdgMzTI oMac9MVE+X2FeiipY+D+sbEmQ1MZVrYihWe6S0TjD5XozunjT02VOISiHjVy1kPx XKGR/HNQyzRz2JMFvzoKHJ0b1ybC7ejThJFMKim4Bbxt1ZfAJEDRYKBjS2ZjRR4d LpiElLOx8IwBGVt4CMNihCRN26UqCh49hm60D7RRCO2bKfQZccSbZOAiokZU6DCN RSUeomqjS/aG8mrTwKnFzjwbnuFXDtJsraQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvkedrudefvddgieehucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvvefufffkjghfggfgtgesthfuredttddtvdenucfhrhhomhepvfhhohhm rghsucfoohhnjhgrlhhonhcuoehthhhomhgrshesmhhonhhjrghlohhnrdhnvghtqeenuc ggtffrrghtthgvrhhnpedtjeeiieefhedtfffgvdelteeufeefheeujefgueetfedttdei kefgkeduhedtgfenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfh hrohhmpehthhhomhgrshesmhhonhhjrghlohhnrdhnvght X-ME-Proxy: Feedback-ID: i47234305:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 14 Nov 2023 09:37:51 -0500 (EST) From: Thomas Monjalon To: Mingjin Ye Cc: dev@dpdk.org, qiming.yang@intel.com, yidingx.zhou@intel.com, Cheng Jiang Subject: Re: [PATCH v2] app/dma-perf: fix lcores array out of bounds access Date: Tue, 14 Nov 2023 15:37:49 +0100 Message-ID: <6270681.mvXUDI8C0e@thomas> In-Reply-To: <20231026095313.3053665-1-mingjinx.ye@intel.com> References: <20230720100937.440849-1-mingjinx.ye@intel.com> <20231026095313.3053665-1-mingjinx.ye@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" 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 26/10/2023 11:53, Mingjin Ye: > The default size of the lcores array in the lcore dma map > is MAX_WORKER_NB. However, when parsing configuration > parameters, MAX_LCORE_NB is used as a constraint. > Since MAX_LCORE_NB is greater than MAX_WORKER_NB, this > causes array access to go out of bounds when the value > of the `lcore_dma/lcore` configuration item in the > parameter file is greater than MAX_WORKER_NB. > > This patch fixes the issue by removing the MAX_LCORE_NB > macro and using MAX_WORKER_NB consistently. > > Fixes: 623dc9364dc6 ("app/dma-perf: introduce DMA performance test") > > Signed-off-by: Mingjin Ye Applied, thanks.