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 234C74624E for ; Mon, 17 Feb 2025 18:05:02 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id EB813400D6; Mon, 17 Feb 2025 18:05:01 +0100 (CET) Received: from mail-wm1-f44.google.com (mail-wm1-f44.google.com [209.85.128.44]) by mails.dpdk.org (Postfix) with ESMTP id 56B95400D6 for ; Mon, 17 Feb 2025 18:05:00 +0100 (CET) Received: by mail-wm1-f44.google.com with SMTP id 5b1f17b1804b1-43948f77f1aso29959325e9.0 for ; Mon, 17 Feb 2025 09:05:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1739811900; x=1740416700; darn=dpdk.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=iSwnxwd7NFUodekp2/IwlYl03elLxyaNGgxqym2luJs=; b=WOwkjJNbWcqZysM6jiI454nQTAsoLtmkoMxPIfxJK7qv+AmgoGIK5BN/xjtHvrfyI9 T7jG3Z9mAW6gqD+2QDP5kX1PiNIOp/mPft7ta3iRJCVsHhGyehz/N3Q+G97lsX57K9fF uGg8rpb/xuE+uX2LyKgwOoQ18Avur5jdaGn5rb0uItB6xVwBUxVa7r23cazbWFczkuws KVbYfVK32JtfobqNLMeKig1NRms1oz/I1E3qpym8aFITCljqjUdkQVc6sjLq4+Xx3jD8 9RJls+grzGwAfUmZckhSKL9MI6J8n+ixy8Jku1tUvEFA5Ki0Tq8wQJK7zaV9/JmC+OkE JzCw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1739811900; x=1740416700; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=iSwnxwd7NFUodekp2/IwlYl03elLxyaNGgxqym2luJs=; b=nkPFJr2zYeODLiImBG9mVyldkhENdPHpD1c7/U9l6htFnCS5IivEaWW0My+xDH8L30 QchVkz9ZABTyuSVk3JxVHBH0LKZQeoL+0lIXOflBSL4+YhZWwICDzS9xtuUssCpvXN/5 Ey/B3PVHdoVqZQqJYloYb/jjMsvE5zd8dTO6O1YLmshaQC6Br0V9DVZU4zImT1Q+OxLD sLgNpWnlUVe1+Fkpniq86aVABU6uImwnwTPSY5Ms4ZB4uFZu6TqR5pWY4ofNV+E/k/f8 01m6ZRh+4Iy4iVY2Akf3FwmH/66R7T2IpgaSgvf5RR+yv/eR2sTjrhC0/eC3kCkErycG K3ug== X-Forwarded-Encrypted: i=1; AJvYcCVHYw9N9rxYM9xISOG+zxnso9d9AJ+zrYvuUNxXpw9qdeNBHcHW1QqFExuoriNJi9qldA0o3AY=@dpdk.org X-Gm-Message-State: AOJu0YxG6zW0vFHALDX7wYsbYuaBJ8UPgjyoEY63Yu7ZUbMjTx3P2g7P v+p89xs3eq4KzJexzbzVdQS2XItInp6knM/uThFRhOWd6r9BDq/VAr7btLcObCs= X-Gm-Gg: ASbGnct7JLqaQOP7SIjLxvaZsgK9SFsriIUYahiCrfcfNxQi9rigXlXfUleVgkdxz1t iyQ+6whuk5IhEIYilP6H0/gbc94XSFbCLOj22PWvpBWBNWp0Wz79Q6nTEkhHK5ENietZxdMmTXf KH6Knf9YBrdwhrKkYDa9TWVH3Nu7nCtkrsaQMv0xCx6t3Mmm9NnRyJ+NtJoACWvDmzrF8iObdew rX0G2H1uIz+ht79HWq8YOgzschW1zHFQ9HqntmwiDM/NozMiy63X3xWAL7QKadtxScPnhKTcj+N l/FteWy2L50UzUNY1/0gHQ== X-Google-Smtp-Source: AGHT+IHZ+2eDJOXILODAts8EmAEBEOaURJDVQnfrpNcq6Hl+kTkXtnlgOTNyCkfbD3Rf4/i/qmDpbw== X-Received: by 2002:a05:600c:458b:b0:439:34d3:63dd with SMTP id 5b1f17b1804b1-4396e6c5d58mr94709265e9.7.1739811899342; Mon, 17 Feb 2025 09:04:59 -0800 (PST) Received: from localhost ([2a01:4b00:d036:ae00:f83c:95e7:29fd:a997]) by smtp.gmail.com with UTF8SMTPSA id 5b1f17b1804b1-4395a04f8c1sm159683885e9.8.2025.02.17.09.04.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Feb 2025 09:04:58 -0800 (PST) From: luca.boccassi@gmail.com To: Konstantin Ananyev Cc: Phanendra Vukkisala , =?UTF-8?q?Morten=20Br=C3=B8rup?= , Stephen Hemminger , dpdk stable Subject: patch 'test/ring: fix init with custom number of lcores' has been queued to stable release 22.11.8 Date: Mon, 17 Feb 2025 17:03:34 +0000 Message-ID: <20250217170456.1068278-1-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.47.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Hi, FYI, your patch has been queued to stable release 22.11.8 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 02/19/25. So please shout if anyone has objections. Also note that after the patch there's a diff of the upstream commit vs the patch applied to the branch. This will indicate if there was any rebasing needed to apply to the stable branch. If there were code changes for rebasing (ie: not only metadata diffs), please double check that the rebase was correctly done. Queued patches are on a temporary branch at: https://github.com/bluca/dpdk-stable This queued commit can be viewed at: https://github.com/bluca/dpdk-stable/commit/e35791f7f0b901998b830b447d5ca4f8c9083a00 Thanks. Luca Boccassi --- >From e35791f7f0b901998b830b447d5ca4f8c9083a00 Mon Sep 17 00:00:00 2001 From: Konstantin Ananyev Date: Fri, 6 Dec 2024 13:35:54 -0500 Subject: [PATCH] test/ring: fix init with custom number of lcores MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [ upstream commit 2cf3a8d35d2db1cee1523e6e9ef5553432fbf56f ] ring_stress_autotest fails to initialize the ring when RTE_MAX_LCORE value is not a number of 2. There is a flaw in calculation required number of elements in the ring. Fix it by aligning number of elements to next power of 2. Fixes: bf28df24e915 ("test/ring: add contention stress test") Reported-by: Phanendra Vukkisala Signed-off-by: Konstantin Ananyev Acked-by: Morten Brørup Acked-by: Stephen Hemminger --- app/test/test_ring_stress_impl.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/test/test_ring_stress_impl.h b/app/test/test_ring_stress_impl.h index 62f046a91a..373091957b 100644 --- a/app/test/test_ring_stress_impl.h +++ b/app/test/test_ring_stress_impl.h @@ -295,7 +295,7 @@ mt1_init(struct rte_ring **rng, void **data, uint32_t num) *data = elm; /* alloc ring */ - nr = 2 * num; + nr = rte_align32pow2(2 * num); sz = rte_ring_get_memsize(nr); r = rte_zmalloc(NULL, sz, __alignof__(*r)); if (r == NULL) { -- 2.47.2 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2025-02-17 16:13:16.953641107 +0000 +++ 0001-test-ring-fix-init-with-custom-number-of-lcores.patch 2025-02-17 16:13:16.778441593 +0000 @@ -1 +1 @@ -From 2cf3a8d35d2db1cee1523e6e9ef5553432fbf56f Mon Sep 17 00:00:00 2001 +From e35791f7f0b901998b830b447d5ca4f8c9083a00 Mon Sep 17 00:00:00 2001 @@ -8,0 +9,2 @@ +[ upstream commit 2cf3a8d35d2db1cee1523e6e9ef5553432fbf56f ] + @@ -15 +16,0 @@ -Cc: stable@dpdk.org @@ -26 +27 @@ -index 8b0bfb11fe..ee5274aeef 100644 +index 62f046a91a..373091957b 100644 @@ -29 +30 @@ -@@ -297,7 +297,7 @@ mt1_init(struct rte_ring **rng, void **data, uint32_t num) +@@ -295,7 +295,7 @@ mt1_init(struct rte_ring **rng, void **data, uint32_t num) @@ -36 +37 @@ - r = rte_zmalloc(NULL, sz, alignof(typeof(*r))); + r = rte_zmalloc(NULL, sz, __alignof__(*r));