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 05A4948B69 for ; Fri, 21 Nov 2025 12:22:08 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id EF6674026F; Fri, 21 Nov 2025 12:22:07 +0100 (CET) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mails.dpdk.org (Postfix) with ESMTP id A8DCE4026F for ; Fri, 21 Nov 2025 12:22:06 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1763724126; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Xnhli2g4kEY2Fx/rFUMREAHiwt4LsmNz6lP/QuwVS6s=; b=hA9ps9P1U7OgkNNb3q+fzoT1CJ1uUIYKy+f/t3ZplcArpgg0KNPs4lt7T1mLqcgW7jX/5C nv40nkhUNAmnSAcjeEg+I38S6q6BBQqgxX+8w3Be6Rb62ssmx4Hol855bCTnmAe9Chm63s rgj348XQfN+bG2YWwRiiTvTaIwTMXRw= Received: from mx-prod-mc-05.mail-002.prod.us-west-2.aws.redhat.com (ec2-54-186-198-63.us-west-2.compute.amazonaws.com [54.186.198.63]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-390-LnRO36fkOk-5uvEVg3sq9g-1; Fri, 21 Nov 2025 06:22:04 -0500 X-MC-Unique: LnRO36fkOk-5uvEVg3sq9g-1 X-Mimecast-MFC-AGG-ID: LnRO36fkOk-5uvEVg3sq9g_1763724124 Received: from mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com [10.30.177.4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mx-prod-mc-05.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTPS id DF01A19560AD; Fri, 21 Nov 2025 11:22:03 +0000 (UTC) Received: from rh.redhat.com (unknown [10.42.28.165]) by mx-prod-int-01.mail-002.prod.us-west-2.aws.redhat.com (Postfix) with ESMTP id 86B5530044DB; Fri, 21 Nov 2025 11:22:02 +0000 (UTC) From: Kevin Traynor To: Robin Jarry Cc: Dmitry Kozlyuk , dpdk stable Subject: patch 'buildtools/pmdinfogen: fix warning with python 3.14' has been queued to stable release 24.11.4 Date: Fri, 21 Nov 2025 11:19:49 +0000 Message-ID: <20251121112128.485623-5-ktraynor@redhat.com> In-Reply-To: <20251121112128.485623-1-ktraynor@redhat.com> References: <20251121112128.485623-1-ktraynor@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.30.177.4 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: _Hod5pAXHiS6IeZj7xrDQjJ6W2NQU1U9-xGV3RY9XGE_1763724124 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit content-type: text/plain; charset="US-ASCII"; x-default=true 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 24.11.4 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 11/26/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/kevintraynor/dpdk-stable This queued commit can be viewed at: https://github.com/kevintraynor/dpdk-stable/commit/d36af38df7a7e8dd7dfa381097e2bc8cfbf68d16 Thanks. Kevin --- >From d36af38df7a7e8dd7dfa381097e2bc8cfbf68d16 Mon Sep 17 00:00:00 2001 From: Robin Jarry Date: Wed, 29 Oct 2025 17:46:17 +0100 Subject: [PATCH] buildtools/pmdinfogen: fix warning with python 3.14 [ upstream commit 74019b85e70e6152594768d6d07b8360e39ee70a ] Fix the following warning seen on Fedora 43 with Python 3.14: buildtools/pmdinfogen.py:118: DeprecationWarning: Due to '_pack_', the 'rte_pci_id' Structure will use memory layout compatible with MSVC (Windows). If this is intended, set _layout_ to 'ms'. The implicit default is dep recated and slated to become an error in Python 3.19. Use the struct module which is simpler and assumes everything is packed by default. There is no change in the output of dpdk-pmdinfo.py before and after this patch. Bugzilla ID: 1818 Link: https://docs.python.org/3/library/struct.html Signed-off-by: Robin Jarry Acked-by: Dmitry Kozlyuk --- buildtools/pmdinfogen.py | 42 +++++++++++----------------------------- 1 file changed, 11 insertions(+), 31 deletions(-) diff --git a/buildtools/pmdinfogen.py b/buildtools/pmdinfogen.py index dfb89500c0..09e34f1524 100755 --- a/buildtools/pmdinfogen.py +++ b/buildtools/pmdinfogen.py @@ -5,7 +5,7 @@ import argparse -import ctypes import json import re +import struct import sys import tempfile @@ -111,22 +111,4 @@ class COFFImage: -def define_rte_pci_id(is_big_endian): - base_type = ctypes.LittleEndianStructure - if is_big_endian: - base_type = ctypes.BigEndianStructure - - class rte_pci_id(base_type): - _pack_ = True - _fields_ = [ - ("class_id", ctypes.c_uint32), - ("vendor_id", ctypes.c_uint16), - ("device_id", ctypes.c_uint16), - ("subsystem_vendor_id", ctypes.c_uint16), - ("subsystem_device_id", ctypes.c_uint16), - ] - - return rte_pci_id - - class Driver: OPTIONS = [ @@ -167,24 +149,22 @@ class Driver: raise Exception("PCI table declared but not defined: %d" % table_name) - rte_pci_id = define_rte_pci_id(image.is_big_endian) + if image.is_big_endian: + fmt = ">" + else: + fmt = "<" + fmt += "LHHHH" result = [] while True: - size = ctypes.sizeof(rte_pci_id) + size = struct.calcsize(fmt) offset = size * len(result) data = table_symbol.get_value(offset, size) if not data: break - pci_id = rte_pci_id.from_buffer_copy(data) - if not pci_id.device_id: + _, vendor, device, ss_vendor, ss_device = struct.unpack_from(fmt, data) + if not device: break - result.append( - [ - pci_id.vendor_id, - pci_id.device_id, - pci_id.subsystem_vendor_id, - pci_id.subsystem_device_id, - ] - ) + result.append((vendor, device, ss_vendor, ss_device)) + return result -- 2.51.0 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2025-11-21 11:05:09.815673739 +0000 +++ 0005-buildtools-pmdinfogen-fix-warning-with-python-3.14.patch 2025-11-21 11:05:09.360200730 +0000 @@ -1 +1 @@ -From 74019b85e70e6152594768d6d07b8360e39ee70a Mon Sep 17 00:00:00 2001 +From d36af38df7a7e8dd7dfa381097e2bc8cfbf68d16 Mon Sep 17 00:00:00 2001 @@ -5,0 +6,2 @@ +[ upstream commit 74019b85e70e6152594768d6d07b8360e39ee70a ] + @@ -20 +21,0 @@ -Cc: stable@dpdk.org @@ -30 +31 @@ -index 63e0a8b364..4401106f0b 100755 +index dfb89500c0..09e34f1524 100755