From patchwork Mon Nov 14 16:57:47 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Power, Ciara" X-Patchwork-Id: 119850 X-Patchwork-Delegate: gakhil@marvell.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id E6D74A00C4; Mon, 14 Nov 2022 17:57:54 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id D105440150; Mon, 14 Nov 2022 17:57:54 +0100 (CET) Received: from mga06.intel.com (mga06b.intel.com [134.134.136.31]) by mails.dpdk.org (Postfix) with ESMTP id A75AE4014F for ; Mon, 14 Nov 2022 17:57:53 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1668445073; x=1699981073; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=wW0h8VX/gG5DW11/4V5CbBnbBvpPa3nmSOULM3rxBOA=; b=GClDRyaMst5ktkrwPvMvuQPZHle0LEbd16urEk5ZhyAmYkguE6q7Hrb5 899oz3xTZLeVSOBy1IV16DdnhUKRXugWJp+xQjAb5C1dSQL3bukLpMhnf EyPxvz5xaMFwCK4bW9agbaQ1hUkc3qG1RCY/V+FLtsWyFUk0EG9FFSlTu UsAegQo+rF4BwY+oxZSywgxrD+weyjbqU/dIToF2pEAaKiUJpaXGrZRHY 5QTGezp9ROGdC97oy2ReQ9xmW4pR2ByBi6mPquVKdikTKdUCqPBwR08qF G/IJTXTGDDBdECUJZ6+i+yERsZJc9PraBLzC/bAKz/ponBRFl/7Feu7LQ g==; X-IronPort-AV: E=McAfee;i="6500,9779,10531"; a="374149380" X-IronPort-AV: E=Sophos;i="5.96,164,1665471600"; d="scan'208";a="374149380" Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Nov 2022 08:57:52 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10531"; a="813329312" X-IronPort-AV: E=Sophos;i="5.96,164,1665471600"; d="scan'208";a="813329312" Received: from silpixa00400883.ir.intel.com ([10.243.23.102]) by orsmga005.jf.intel.com with ESMTP; 14 Nov 2022 08:57:51 -0800 From: Ciara Power To: dev@dpdk.org Cc: kai.ji@intel.com, Ciara Power , Kevin O'Sullivan Subject: [PATCH 1/2] test/crypto-perf: fix number of sessions for cores Date: Mon, 14 Nov 2022 16:57:47 +0000 Message-Id: <20221114165748.307086-1-ciara.power@intel.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 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 Currently the performance application creates a device session per lcore. This was not reflected in how many session objects were available in the mempool, when using a scheduler device. The number of lcores is now taken into consideration when calculating how many sessions are needed for the scheduler. Fixes: 09fcf99dcad2 ("test/crypto-perf: fix number of scheduler sessions") Reported-by: Kevin O'Sullivan Signed-off-by: Ciara Power --- app/test-crypto-perf/main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/test-crypto-perf/main.c b/app/test-crypto-perf/main.c index 0fe47c6caa..22f6b2b3ba 100644 --- a/app/test-crypto-perf/main.c +++ b/app/test-crypto-perf/main.c @@ -269,8 +269,8 @@ cperf_initialize_cryptodev(struct cperf_options *opts, uint8_t *enabled_cdevs) uint32_t nb_slaves = rte_cryptodev_scheduler_workers_get(cdev_id, NULL); - /* scheduler session header + 1 session per worker qp */ - sessions_needed = 1 + enabled_cdev_count * + /* scheduler session header per lcore + 1 session per worker qp */ + sessions_needed = nb_lcores + enabled_cdev_count * opts->nb_qps * nb_slaves; #endif } else From patchwork Mon Nov 14 16:57:48 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Power, Ciara" X-Patchwork-Id: 119851 X-Patchwork-Delegate: gakhil@marvell.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 8657FA00C4; Mon, 14 Nov 2022 17:57:58 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id CB00742D0C; Mon, 14 Nov 2022 17:57:55 +0100 (CET) Received: from mga06.intel.com (mga06b.intel.com [134.134.136.31]) by mails.dpdk.org (Postfix) with ESMTP id 4BF974014F for ; Mon, 14 Nov 2022 17:57:54 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1668445074; x=1699981074; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=/ZDBirjiZ3f3oyzFZVwSHiHxxvEm3A1T8L0KAVBe7IU=; b=B/PvLMLIdU/MI+o59iGjXQwsVxjc5vTGYLdhJNr5SescaHxvfXmxpOeR cAFklckJ4LRlwapSOS40mmDC76H2Gq0bOeWSxPtq3rDuDPqPa9dgXnox8 RqpXiiVqkXd91uAa762Fa9p3j/Zg0+rtB5LuLGQGxu/uTOD4EPM4qgcjv Y4dUsUVTuJsPRo1f1t1KameSAbSYe16ZFsSSZRHR1nFi+Y30Bra9Ea/MA ov+L1x/wLzpsAl6rw4bTEo9nrUf8dUlYbGDmJSN6ZnSwVQvAI+z1mTH6y jgBoR1bkkzuoxxjHA7MxNL6BijppTErTTRImke7FLbeQHLPrsYh+2BM9C g==; X-IronPort-AV: E=McAfee;i="6500,9779,10531"; a="374149385" X-IronPort-AV: E=Sophos;i="5.96,164,1665471600"; d="scan'208";a="374149385" Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 14 Nov 2022 08:57:53 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10531"; a="813329335" X-IronPort-AV: E=Sophos;i="5.96,164,1665471600"; d="scan'208";a="813329335" Received: from silpixa00400883.ir.intel.com ([10.243.23.102]) by orsmga005.jf.intel.com with ESMTP; 14 Nov 2022 08:57:52 -0800 From: Ciara Power To: dev@dpdk.org Cc: kai.ji@intel.com, Ciara Power Subject: [PATCH 2/2] test/crypto-perf: replace slave with worker Date: Mon, 14 Nov 2022 16:57:48 +0000 Message-Id: <20221114165748.307086-2-ciara.power@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221114165748.307086-1-ciara.power@intel.com> References: <20221114165748.307086-1-ciara.power@intel.com> MIME-Version: 1.0 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 Update the use of outdated language "slaves" with "workers". Signed-off-by: Ciara Power --- app/test-crypto-perf/main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/test-crypto-perf/main.c b/app/test-crypto-perf/main.c index 22f6b2b3ba..af5bd0d23b 100644 --- a/app/test-crypto-perf/main.c +++ b/app/test-crypto-perf/main.c @@ -266,12 +266,12 @@ cperf_initialize_cryptodev(struct cperf_options *opts, uint8_t *enabled_cdevs) if (!strcmp((const char *)opts->device_type, "crypto_scheduler")) { #ifdef RTE_CRYPTO_SCHEDULER - uint32_t nb_slaves = + uint32_t nb_workers = rte_cryptodev_scheduler_workers_get(cdev_id, NULL); /* scheduler session header per lcore + 1 session per worker qp */ sessions_needed = nb_lcores + enabled_cdev_count * - opts->nb_qps * nb_slaves; + opts->nb_qps * nb_workers; #endif } else sessions_needed = enabled_cdev_count * opts->nb_qps;