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 3440E43804; Wed, 3 Jan 2024 05:01:10 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id AEED440689; Wed, 3 Jan 2024 05:01:06 +0100 (CET) Received: from NAM04-MW2-obe.outbound.protection.outlook.com (mail-mw2nam04on2078.outbound.protection.outlook.com [40.107.101.78]) by mails.dpdk.org (Postfix) with ESMTP id 502744068A for ; Wed, 3 Jan 2024 05:01:05 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=nun/tK5vr0KWS/Cag7huylrkiEnPqI94x51OVekjrr8StdenXZLiu3NBRke9+bH93VxFalv1bTxjwjKYX7/bAmLaxkSAmLZefV501YVyACvJ3D6jXu0wFiaQ3huWa6tNr5+uD9vqVH3nEKDZClKxNBUPUs5cEVmhz91pMnDj1gzEg2paLODxAOBNmQWBkE2Imar2gnsX9hnNcF+sRedqz3VHdGbze+xmWzj82KL499AwE3BEyifj8f3gGy1ZqwSFscyAHAexYwHfuQnvz7Bs/KADka65jMkWNnUaWQjovB6D38MUc943xueiRHMXYfk+m9yiGuJ5WcToy4wu9i3uFQ== 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=7q6ELJM6BjbDltcPCcE+rurmzZcSqbEUUPmov2s6cDU=; b=Yqa/RzTq7E7lab7j9BRDRkQvl7AT3WBWtSCQgCWfgh8/X0tbWiGnAJJS8g2qTstMviFojuQqc4XXX0ZbwUATlRHPfynp3JJ61+/VGXUPnaPLd1iu0YYmTYy2rEeuOxl2HoBFCb7Ilv6ajdk0cG50B5gCvNeTm1PwC9TiUXESiiXfzPydHexnS6yfEG1lTZXHN/7C5p3KD0fopwaA7BZV1H0Mks+MXb+oIxQQlS4cjoRmDKh0mjDLFbc276p9BW+fAXfR33COriV+UIq2YuqfrcTJOAMdUoyl5NEPEaomMVBrjE94PYJm0gJeq9Yt0AMgBV9qZGbsFNSSvP3bNSZnFg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.160) smtp.rcpttodomain=intel.com 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=7q6ELJM6BjbDltcPCcE+rurmzZcSqbEUUPmov2s6cDU=; b=TQ2eko8+r1kHBDqI2DcYP6HuvhTtzM4vJ4EcAmnr6SHUsrr0ZBM4upl6LMV3pl6TJFWvQX68Mu2o8txstcsYORtqgP/OTtWm5k16RBzYqYf91m/tqc88SAu8UMcuLuI+cUmWNu+llCCr3UDLkKArDXTWJs8i6LpGEnL+H92WMiyWgsh+LQjatMImJmyRCl4RCtvlN4iVzGHiG3LJiDOWrz+sJ53iCTWSnTsdIydzPDLfS+j3gMRisFDG6q93vojfBD5nzxp//bWgln4pQeXMrv5Ux5ZPbqpcWVYYzFCqF2jjj3FcTT76BZCFvyQNA7vEA0My6KFqzCZPRl4tKfv6zA== Received: from BL1PR13CA0323.namprd13.prod.outlook.com (2603:10b6:208:2c1::28) by SA1PR12MB8985.namprd12.prod.outlook.com (2603:10b6:806:377::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7135.25; Wed, 3 Jan 2024 04:01:01 +0000 Received: from MN1PEPF0000F0E4.namprd04.prod.outlook.com (2603:10b6:208:2c1:cafe::fc) by BL1PR13CA0323.outlook.office365.com (2603:10b6:208:2c1::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7159.12 via Frontend Transport; Wed, 3 Jan 2024 04:01:00 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.117.160) 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.160 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.117.160; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (216.228.117.160) by MN1PEPF0000F0E4.mail.protection.outlook.com (10.167.242.42) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7159.9 via Frontend Transport; Wed, 3 Jan 2024 04:00:59 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by mail.nvidia.com (10.129.200.66) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.41; Tue, 2 Jan 2024 20:00:42 -0800 Received: from nvidia.com (10.126.230.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; Tue, 2 Jan 2024 20:00:41 -0800 From: Suanming Mou To: CC: Subject: [PATCH 2/2] app/test-crypto-perf: fix dst_mbuf size calculation Date: Wed, 3 Jan 2024 12:00:24 +0800 Message-ID: <20240103040024.720600-3-suanmingm@nvidia.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240103040024.720600-1-suanmingm@nvidia.com> References: <20240103040024.720600-1-suanmingm@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.230.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-TrafficTypeDiagnostic: MN1PEPF0000F0E4:EE_|SA1PR12MB8985:EE_ X-MS-Office365-Filtering-Correlation-Id: b8dc67e8-13ad-4783-8404-08dc0c1098b6 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: G4Zza3bHxyjwPAlVqvh28gJU7+N3uNLklneIRWGa2cKatZF5vXBVBMZlF/KVTZvB+HrxdYkQNg3EgHaebMDyyWHsMp9s5NFPJoa+kmHHyDwzcfSCgaH5rQqYUEtzx/KZDYfU4ureZZfd5TvNOJRqTUlTmrlslmBxEs2OVC5t78hwcAhWJrXYClU4vN0J9ZM0JNUflojGoLlr/9LQcINtbrIsVjkEXw8uSs38uVKtUJQUhNugFxPgnTZwB9llpzBIAnZakJWiUV0lBP6PvXeIXjxw2XV1SNBfCW9hmLs5MLYhYA4AtEcocg+3KeUvGwDPm9vcmkQZgnCCMkoYfAwYWhfGtUPP0PeJyErBrVkFbrXEB9+VRGdeOFlP6AlfyZKDNHEA4ahalErJZ+ZqOBk8rxBhDblaGbU/dK3dE5eANB1igMJMhVl3wO5l2LUnUVeLxXi90pe/xgdCVTl3ocl0bXBMc1Gq/CCvrKsYN2eadILn/oI7gdsApdz6aiP2BKNMa6P8NlCPOKrWqNfqb5IVwvGJwEPSdp1RkGNu5rnCMdB6F/M5K8tZDUXFh++KqIKBkHreatRsoNWyTmhEldtdnUuxl+7+LCSDlDQyrqJGT7UgAdS/nroeblvfcgtMYI9BQd5gMVcId8vjV7V2LBDzXyYweCBcD22TWgHgd2MXJRaUP+/N4hZLZrgBzNyucZW6C+X7JSo/7vmhSZi8fdS7W2O3CIgk/8FHqYIulUZIbjjivP04OqqGSs7yZFOsECwz X-Forefront-Antispam-Report: CIP:216.228.117.160; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:dc6edge1.nvidia.com; CAT:NONE; SFS:(13230031)(4636009)(346002)(396003)(136003)(39860400002)(376002)(230922051799003)(451199024)(1800799012)(186009)(82310400011)(64100799003)(36840700001)(46966006)(40470700004)(1076003)(26005)(47076005)(336012)(2616005)(6286002)(16526019)(356005)(7636003)(36860700001)(8936002)(8676002)(82740400003)(5660300002)(316002)(2906002)(4326008)(41300700001)(6666004)(6916009)(7696005)(83380400001)(70586007)(70206006)(478600001)(86362001)(426003)(36756003)(40480700001)(55016003)(40460700003); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 03 Jan 2024 04:00:59.9001 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: b8dc67e8-13ad-4783-8404-08dc0c1098b6 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.160]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: MN1PEPF0000F0E4.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SA1PR12MB8985 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 If crypto device requires headroom and tailroom, the mbuf of dst in out-of-place should reserve the headroom and tailroom as well, otherwise there will be no enough room for dst mbuf. Fixes: bf9d6702eca9 ("app/crypto-perf: use single mempool") Signed-off-by: Suanming Mou --- app/test-crypto-perf/cperf_test_common.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/test-crypto-perf/cperf_test_common.c b/app/test-crypto-perf/cperf_test_common.c index 8faf832527..c773dd48df 100644 --- a/app/test-crypto-perf/cperf_test_common.c +++ b/app/test-crypto-perf/cperf_test_common.c @@ -229,7 +229,8 @@ cperf_alloc_common_memory(const struct cperf_options *options, (mbuf_size * segments_nb); params.dst_buf_offset = *dst_buf_offset; /* Destination buffer will be one segment only */ - obj_size += max_size + sizeof(struct rte_mbuf); + obj_size += max_size + sizeof(struct rte_mbuf) + + options->headroom_sz + options->tailroom_sz; } *pool = rte_mempool_create_empty(pool_name, -- 2.34.1