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 59C11432D8; Wed, 8 Nov 2023 17:35:19 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 27E3E402BB; Wed, 8 Nov 2023 17:35:19 +0100 (CET) Received: from NAM12-DM6-obe.outbound.protection.outlook.com (mail-dm6nam12on2081.outbound.protection.outlook.com [40.107.243.81]) by mails.dpdk.org (Postfix) with ESMTP id 16F93402A7 for ; Wed, 8 Nov 2023 17:35:18 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=SJlNJCxJDxP4yW2WSLh5v779zZs++KRkB2817iD3+PLkSPpiUlWSVFrGOhgwPOmy3yiNQpd4fa0kK/AbzxcCa4ZrZAmxQRequoLGS6lgbYzqjUtSSJzmqPJKdDXRR9AEfkPk/Fd+q4bFOHmgo0o+xXdHOLoe+iwi8qgWtaZlZegzWvgmnNeDKbqRC3C8HRIh2HTpKDh9Zc7xwFeijvsYf/S5pDBbOtW72fECYtgOMuVBPMVFy9z11KYuQFQVHmhR2xKSENargWfSUg8mUm3F0PlYdaEJS+41CXa37I/RqEokLtetIm/ua4kx4ArPkeJsNUAYsZOAmF/RUuT3vmiXZg== 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=3+wid+9zWlXfgRqFIoMcQK4i/TM5hBMeNWDa0308YvE=; b=h/0NSbszRZ/fZGlzDQKOvRWQKTxLRCmsHlq+6eVxUwvSzADizCl2QsiNnGgitCsN8p3Q1vVE7jsx4WIRnhN+i9g+mT6XZcwgwSHXv2kesd42Kv71lPJY6jfdUD5PH38rbu/atM3pbLx3kiYa510sg3k7myn2slcDaKaVLt0H1H23b18aYNmHIPoSe/HzmNuvUPo2pT+xSDSP16bMpBK3xbIx9rOkrDQZadjmOvKLVLcT75BLjNGH4N6VEcvmlx6q8BCWv4j02Ed4vHomleMwuuqTQTj17VhDx4ksD6Em5ZH+ZsEALixUTyWnBT1wRIDG/7aAbYESBljlYgbQag6ZIA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.161) smtp.rcpttodomain=dpdk.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 (0) 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=3+wid+9zWlXfgRqFIoMcQK4i/TM5hBMeNWDa0308YvE=; b=dE45beyoqvUST+pzWZkuNjzrlKEr22seBfQXUize0nNu2KfTI1ZG3oY7gGVGkTNxViXDHR+S5TbV9QF0QW4mOdfAd+A3Sj6Vd1naD/vCnsI71Sp98irmOcFHc8oD95gWUskqvElQIduQwU5mpCVtBa9CIZJvq437rLw7gQwqqXlHkyvmqyokS25ag1KsVHdW6YnjiBLKBQKuSr80BMpJ7/h7rrTNBPq2gO53YzmGCIZTyvVMnTbsMIFGyrBlqTvlfPK9Dowcuym4ObrwLKxz5nL5Yq/9wjvSWmK7s7S4k971h+nKKRLb32R0XXjcgvHgOCVwPJ21EKBKteDglI3z5Q== Received: from SJ0PR03CA0190.namprd03.prod.outlook.com (2603:10b6:a03:2ef::15) by MN0PR12MB6152.namprd12.prod.outlook.com (2603:10b6:208:3c4::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6954.28; Wed, 8 Nov 2023 16:35:14 +0000 Received: from MWH0EPF000971E4.namprd02.prod.outlook.com (2603:10b6:a03:2ef:cafe::23) by SJ0PR03CA0190.outlook.office365.com (2603:10b6:a03:2ef::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6977.18 via Frontend Transport; Wed, 8 Nov 2023 16:35:14 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.117.161) 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 216.228.117.161 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.117.161; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (216.228.117.161) by MWH0EPF000971E4.mail.protection.outlook.com (10.167.243.72) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6977.18 via Frontend Transport; Wed, 8 Nov 2023 16:35:13 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by mail.nvidia.com (10.129.200.67) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.41; Wed, 8 Nov 2023 08:35:04 -0800 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.41; Wed, 8 Nov 2023 08:35:01 -0800 From: Gregory Etelson To: CC: , , , "Ori Kam" , Aman Singh , Yuying Zhang Subject: [PATCH] app/testpmd: fix indirect action list parameters parsing Date: Wed, 8 Nov 2023 18:34:45 +0200 Message-ID: <20231108163445.422772-1-getelson@nvidia.com> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.231.35] X-ClientProxiedBy: rnnvmail201.nvidia.com (10.129.68.8) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: MWH0EPF000971E4:EE_|MN0PR12MB6152:EE_ X-MS-Office365-Filtering-Correlation-Id: 2502659a-48a6-4a8b-c790-08dbe078aeff X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Hjd86AX8FGjlIDAjDebeZFx9J6VmuhXYfy+BWfOAxNhwj5bqrI2U6ns45/WyC340ecTFURIXuBrV2bbfnLvRHCVoNAElj8UqDWnODeNidE+pYGUZj2KCSLbH3nQ609ULZ4LQW/mVgN5NvHEuqTY9UrrknFJQRM7aLVw8l/s2v4nOqSUciZZd23lJB1x1lxXJDmIcO7eLT2rfc43+rVo5DUNTwV9tIOmAlCIjA7J4gyV23zxl5s9ucvuqW7sUF5UO2tKbh7oAj9jL2ulw9PONt5MQraqucQpWMoycfmKkdkiAzsrY6908AGqrZ+WC1k1oOYgETVmnitmlbA+kAaOEZmANVZE5iUB5ZB4Zu3s3fmO+d2MdWl+mok3v5J+RYIHZ/VYkYLzT6vP8XHarvYwXRRepE4t1PVE0VlydVJ6fBTmwXqN8neCuJrujXZX27U/LW60zmjTzlQPkNJPdQkSbFAmhttlrDwAv5NEHOTYaJ15zy69wwb9m9LW7zeHcmyYj/KZDhOflLFry5KetXmyLOdMyasFKyxprVwGk3eEVrLY1i8e9eJ99vpo16O5r8rEtvg2T0DQIvlFLo/VGUrd4DoNc2gioM0xyBl/mqsEcumLrYTfP8wzhijVqwDD1cisHr6/OG5PD4zVo/TF+QbHaHcN5CYAz9ptkQaVeLIDZkebIarjZG05AohD7HlUPakh+780OWHUNl8xgYUsKaRKcifnh8/RkI+qAz6wtdk/cWwQ= X-Forefront-Antispam-Report: CIP:216.228.117.161; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:dc6edge2.nvidia.com; CAT:NONE; SFS:(13230031)(4636009)(376002)(39860400002)(136003)(346002)(396003)(230922051799003)(82310400011)(451199024)(64100799003)(1800799009)(186009)(36840700001)(46966006)(40470700004)(40480700001)(55016003)(40460700003)(6666004)(7696005)(478600001)(2616005)(36860700001)(36756003)(82740400003)(356005)(7636003)(86362001)(316002)(1076003)(70586007)(5660300002)(41300700001)(6916009)(83380400001)(2906002)(426003)(336012)(47076005)(16526019)(26005)(6286002)(70206006)(54906003)(4326008)(8676002)(8936002); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 Nov 2023 16:35:13.8815 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2502659a-48a6-4a8b-c790-08dbe078aeff X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.117.161]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: MWH0EPF000971E4.namprd02.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN0PR12MB6152 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 Indirect actions list arguments parser was configured to place target number into 64bit value, while the code provided 32bits memory. The patch updated variable size for translation results. Fixes: 72a3dec7126f ("ethdev: add indirect flow list action") Signed-off-by: Gregory Etelson --- app/test-pmd/cmdline_flow.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/test-pmd/cmdline_flow.c b/app/test-pmd/cmdline_flow.c index 0d521159e9..cf1ca33208 100644 --- a/app/test-pmd/cmdline_flow.c +++ b/app/test-pmd/cmdline_flow.c @@ -11331,7 +11331,7 @@ parse_indlst_id2ptr(struct context *ctx, const struct token *token, struct rte_flow_action *action = ctx->object; struct rte_flow_action_indirect_list *action_conf; const struct indlst_conf *indlst_conf; - uint32_t id; + uint64_t id; int ret; if (!action) @@ -11350,7 +11350,8 @@ parse_indlst_id2ptr(struct context *ctx, const struct token *token, action_conf->handle = (typeof(action_conf->handle)) port_action_handle_get_by_id(ctx->port, id); if (!action_conf->handle) { - printf("no indirect list handle for id %u\n", id); + printf("no indirect list handle for id %"PRIu64"\n", + id); return -1; } break; -- 2.39.2