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 2F0AEA00C5 for ; Wed, 20 Jul 2022 10:22:13 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2939F40697; Wed, 20 Jul 2022 10:22:13 +0200 (CEST) Received: from NAM12-MW2-obe.outbound.protection.outlook.com (mail-mw2nam12on2068.outbound.protection.outlook.com [40.107.244.68]) by mails.dpdk.org (Postfix) with ESMTP id 929AF4003C for ; Wed, 20 Jul 2022 10:22:11 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=eVIpub1fXRjlL/Jx20glnFbPHFuJSJkFiLpk5tAM7BVMyONcHeVyFoRgoYTBX11GC/cyDRdA1b5PGZY5BAomWzPYBn/7U7MhcywdehWEo5Cjw22L4ryqxpwGnbreDmObKGn750oYC2EbVDawt0zw06NItq1yUj+iHt+2l3RnSe/I92FJm1+0CjMCfS1sk1U2RnERrI1JnBeibp21Z0Mgo+lW9K3ZymVeRQ3V9HJCuVYaXOFidyAVIbQ+hKFYlOOehBdvo7ZrHQyspDFFkKWZP+251XkvARHEsRI90xoDQJVrMtPm8Dbrp/bEp5wyr7teqmsywGJ4Sr3LPkX9TpvxhA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=F+tfgrv21zPTjEul8m4U1DAYbVxz0ZrhdP1FIkShlug=; b=M9rTlky5kS/Gs7jYj95cJrqD1+5MMQkLzRAcTT+nlNsfvZgS+V5S2tndo76dInK8Wgtk1480pcVI/AklWDCHhypy0Z+LgkHowQwq2+IexYVKzZO+rBXdumGpKnmX2VqM5wIBXEn65mPcdwU1Zw/aoHI546yjka2w+m2JQ1eYZm+Fglhusbr0KyvxBVWGgBTHAy4+HmktCp4Q+0UlW8cSHgAyqpLmKAjzQTB3dxuCNZJE6PPTmWwafvyxHrRbc49H+AKdg28dEgyM2nCTLQ8kxoAdCiwy0wQQPVFxYyXQzfwQHUQzjOiu5KHjcQn9l+BQFy4358qHAbX6MKTRqqxROg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 12.22.5.235) smtp.rcpttodomain=networkplumber.org smtp.mailfrom=nvidia.com; dmarc=pass (p=reject sp=reject pct=100) action=none header.from=nvidia.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=F+tfgrv21zPTjEul8m4U1DAYbVxz0ZrhdP1FIkShlug=; b=ApjEXTUO+CHxc1+SEpk/ixKzTRp7X9dZNG2ScXctD6KR7fMrTieXpZYegBbW1lhORB/MQ1u8n9dczA+xadJH6s7LCLBUQ/ej3TTJ/TlHwyQnZhZxrzNH+cFB5x155x/la4f85tnVe1AvhaZiE5Xk0xg5lpkxVPj39kpgQeNidtZZYZu9T0XjIBdFvhKj7ZaVMKw4jVMu91/zbAyqB0Ap7rwiyDwW8HEPLVbwCaHViWlgkNrhJWwJQfrXGikmd2qvq3rCnbBTQDr02XNe1e2XRINhYSLhwBwZVOLEAy/YEDJLJ0uuZUKgsS9dxvH9OTVQmSZMTvUL5qJh/YuY4P4DkA== Received: from BN9PR03CA0880.namprd03.prod.outlook.com (2603:10b6:408:13c::15) by DM5PR12MB1834.namprd12.prod.outlook.com (2603:10b6:3:10a::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5438.12; Wed, 20 Jul 2022 08:22:08 +0000 Received: from BN8NAM11FT038.eop-nam11.prod.protection.outlook.com (2603:10b6:408:13c:cafe::19) by BN9PR03CA0880.outlook.office365.com (2603:10b6:408:13c::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5458.18 via Frontend Transport; Wed, 20 Jul 2022 08:22:08 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 12.22.5.235) smtp.mailfrom=nvidia.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 12.22.5.235 as permitted sender) receiver=protection.outlook.com; client-ip=12.22.5.235; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (12.22.5.235) by BN8NAM11FT038.mail.protection.outlook.com (10.13.176.246) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.5458.17 via Frontend Transport; Wed, 20 Jul 2022 08:22:08 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by DRHQMAIL107.nvidia.com (10.27.9.16) with Microsoft SMTP Server (TLS) id 15.0.1497.32; Wed, 20 Jul 2022 08:22:07 +0000 Received: from nvidia.com (10.126.231.35) by rnnvmail201.nvidia.com (10.129.68.8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.26; Wed, 20 Jul 2022 01:22:05 -0700 From: Xueming Li To: David Marchand CC: , Xiao Wang , "Stephen Hemminger" , dpdk stable Subject: patch 'vdpa/ifc: fix build with GCC 12' has been queued to stable release 20.11.6 Date: Wed, 20 Jul 2022 11:20:30 +0300 Message-ID: <20220720082132.3954126-1-xuemingl@nvidia.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20220621080301.2315720-1-xuemingl@nvidia.com> References: <20220621080301.2315720-1-xuemingl@nvidia.com> MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit X-Originating-IP: [10.126.231.35] X-ClientProxiedBy: rnnvmail202.nvidia.com (10.129.68.7) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 04496bd7-b432-4fdd-b2a8-08da6a28f010 X-MS-TrafficTypeDiagnostic: DM5PR12MB1834:EE_ X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: =?utf-8?B?WnhERnlFaFpDRVliampZdzlGNWZRQzBRUTVkV1lKVzAwK1oyRU1XZDlKNzgy?= =?utf-8?B?VzN1RTNQaWgwMXZET0pxaVRXOWV6OHRHT1F5ejB1OTdOUmhhMXZzTnJlY2NN?= =?utf-8?B?QW9JRjRGMFNkbDZJZmdRcjU4aUtRN0hObUIyeU1FS3dNWUE1RG1Od2w0QlhS?= =?utf-8?B?NUJJNnk4TnQxajRnWVJRUVZZMVBtQWdkT3pjWVQ3ZXJUWFh0a2duTVJpQmRY?= =?utf-8?B?U0hLaVdxVWo0dDRkeE4zQWplRTlEMEZuZll1WS82N1RZYlYvT0tZNnkvc0do?= =?utf-8?B?NGpjYXdLdEJrWU84dkhoQnZwaWlYZ201N09DcFB5M2piYlkvSUpuNTU4QWU4?= =?utf-8?B?em5CTjdxTVdBSE9aWE1lVFl1R0hFVEFLWGd3ei9UNnIzaGE4VFVTRkVMVTVF?= =?utf-8?B?NkRTM1lVdzJaelluYTV1SURNckpUdjQvQjBWVVpvaXdpQ3NucU9yZXNrVTdI?= =?utf-8?B?YXZLOU5acTJJZnZrcDEvVVl1c2t2UjZvdVNxZ2M5Q2dNbXNSRFQzdjR6RlVx?= =?utf-8?B?TUY4QWVlb2gzVnZRRDVvOHVRWktGY1lpemt3OUpkYVlZZnoxZmtpL1FNZ2Zm?= =?utf-8?B?MEhUNDd4OFEzcGk5UU5wU2VsOEVDOHdDbE5RNmZ3QmQ1Zzl1ampOS3NmVFRq?= =?utf-8?B?K2I4amY0cW9ydUMwd2lSQUNiWm92WVFzUmdvTUlpRFlrWFNNay8vV1hmR1NI?= =?utf-8?B?d3RtWVpxU0ZaV0kzaFpvMGszMjNPT3ByWVlWeFpYN0pVNWtqaFNSZm1CY0xH?= =?utf-8?B?bWVjZzdoTFQxbXZTeThpVzhUTmRscUIydUdPTFJOY1o5VXQzMEFRWmQyejAw?= =?utf-8?B?UGpLRy94RVpWSGdBeDNBN2thalN5S2NDdDlzOS9iRENrdlRQd2UrZ050MnlZ?= =?utf-8?B?aGt4TnJma2N3S2VDdGN3R2hRZ1pnandaZzhJclFGYTJCTXhadzErZXMrSk5j?= =?utf-8?B?SVRITm93WnNNb0I2a0NuRHRDbG8yRHI0L0M4eUNBVjhqTG4xU25yb1dST1BQ?= =?utf-8?B?WFdwRE11TnQ2S2lUbURwYXNveXIvQ2J1UjRzOSt4QWRyU2JtNWpqLzA5aWVl?= =?utf-8?B?emZEdFZXc2k3YkhnV3hJY2s5ajdtLyszcThTZ3BTU1pnK21yMkZOdHVSNXFs?= =?utf-8?B?WnE5ZXRDLy9lRzhvRUJPVDNjVkd6RkRmajAzNUZhVWtreThLOVdWemNKZEt5?= =?utf-8?B?dG1rcVE1YWpFZ0VSMm1yTzlwTVBHc1F6Ylc0RHRGUS9TSElCTGFCRG1xbTUx?= =?utf-8?B?SnBrS0VDVFVUQ0pCZjlhRkZNRi9URFcyMEtqcENrMmU0czNDQT09?= X-Forefront-Antispam-Report: CIP:12.22.5.235; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:InfoNoRecords; CAT:NONE; SFS:(13230016)(4636009)(376002)(396003)(136003)(39860400002)(346002)(46966006)(40470700004)(36840700001)(82310400005)(47076005)(426003)(336012)(16526019)(186003)(6286002)(54906003)(6916009)(81166007)(82740400003)(8676002)(316002)(40460700003)(356005)(86362001)(2616005)(70206006)(70586007)(1076003)(4326008)(478600001)(55016003)(40480700001)(966005)(36860700001)(83380400001)(53546011)(26005)(6666004)(7696005)(41300700001)(5660300002)(8936002)(36756003)(2906002)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Jul 2022 08:22:08.3333 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 04496bd7-b432-4fdd-b2a8-08da6a28f010 X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[12.22.5.235]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT038.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR12MB1834 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 20.11.6 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 07/22/22. 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/steevenlee/dpdk This queued commit can be viewed at: https://github.com/steevenlee/dpdk/commit/b089558de0e5b14c38ee700bd3b0885574fb8c11 Thanks. Xueming Li --- >From b089558de0e5b14c38ee700bd3b0885574fb8c11 Mon Sep 17 00:00:00 2001 From: David Marchand Date: Wed, 18 May 2022 12:16:54 +0200 Subject: [PATCH] vdpa/ifc: fix build with GCC 12 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Xueming Li [ upstream commit 2a213b794fdd255fde7581a7c9bd034ab39e9b6a ] GCC 12 raises the following warning: ../drivers/vdpa/ifc/ifcvf_vdpa.c: In function ‘vdpa_enable_vfio_intr’: ../drivers/vdpa/ifc/ifcvf_vdpa.c:383:62: error: writing 4 bytes into a region of size 0 [-Werror=stringop-overflow=] 383 | fd_ptr[RTE_INTR_VEC_RXTX_OFFSET + i] = fd; | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~ ../drivers/vdpa/ifc/ifcvf_vdpa.c:348:14: note: at offset 32 into destination object ‘irq_set_buf’ of size 32 348 | char irq_set_buf[MSIX_IRQ_SET_BUF_LEN]; | ^~~~~~~~~~~ Validate number of vrings to avoid out of bound access. Bugzilla ID: 855 Signed-off-by: David Marchand Acked-by: Xiao Wang Acked-by: Stephen Hemminger --- drivers/vdpa/ifc/ifcvf_vdpa.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/vdpa/ifc/ifcvf_vdpa.c b/drivers/vdpa/ifc/ifcvf_vdpa.c index 6a1b44bc77..85bca09377 100644 --- a/drivers/vdpa/ifc/ifcvf_vdpa.c +++ b/drivers/vdpa/ifc/ifcvf_vdpa.c @@ -357,6 +357,8 @@ vdpa_enable_vfio_intr(struct ifcvf_internal *internal, bool m_rx) vring.callfd = -1; nr_vring = rte_vhost_get_vring_num(internal->vid); + if (nr_vring > IFCVF_MAX_QUEUES * 2) + return -1; irq_set = (struct vfio_irq_set *)irq_set_buf; irq_set->argsz = sizeof(irq_set_buf); -- 2.35.1 --- Diff of the applied patch vs upstream commit (please double-check if non-empty: --- --- - 2022-07-20 15:00:58.883526527 +0800 +++ 0001-vdpa-ifc-fix-build-with-GCC-12.patch 2022-07-20 15:00:58.637667282 +0800 @@ -1 +1 @@ -From 2a213b794fdd255fde7581a7c9bd034ab39e9b6a Mon Sep 17 00:00:00 2001 +From b089558de0e5b14c38ee700bd3b0885574fb8c11 Mon Sep 17 00:00:00 2001 @@ -7,0 +8,3 @@ +Cc: Xueming Li + +[ upstream commit 2a213b794fdd255fde7581a7c9bd034ab39e9b6a ] @@ -24 +26,0 @@ -Cc: stable@dpdk.org @@ -34 +36 @@ -index 40a18b2507..8bc971cb12 100644 +index 6a1b44bc77..85bca09377 100644 @@ -37 +39 @@ -@@ -388,6 +388,8 @@ vdpa_enable_vfio_intr(struct ifcvf_internal *internal, bool m_rx) +@@ -357,6 +357,8 @@ vdpa_enable_vfio_intr(struct ifcvf_internal *internal, bool m_rx)