From patchwork Wed Nov 30 17:10:11 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ganapati Kundapura X-Patchwork-Id: 120381 X-Patchwork-Delegate: jerinj@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 BA2A3A00C2; Wed, 30 Nov 2022 18:10:24 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6686342BDA; Wed, 30 Nov 2022 18:10:20 +0100 (CET) Received: from mga05.intel.com (mga05.intel.com [192.55.52.43]) by mails.dpdk.org (Postfix) with ESMTP id 1873B40395 for ; Wed, 30 Nov 2022 18:10:17 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1669828218; x=1701364218; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=ES049HzdBlO9tEex1L5BFgmJCx5JQEjfpcMgvjhJRaM=; b=Q5kJVzlRBLbibDkxiZfvJSxR7r1G3gJLEN84MAgxHGwRHtqD1Bs35lJm GzewFXlTnsF3bkQkuuTAcuFuRKI1nd6cBx2BT+TUKAs1ReF6xz2cJ8Wog v5KcQ9LBXOgxqbxSEzwQ3qa6n85k/FmsvJhJagQYo0A6dKiCeMZKXeu8r A62HDabmzFHR9nhxro1G5rG5xCfDeHgo7cjK7odg+Biz8Pwu2aKnyiqB0 UCrzxm6pqpia9x+H5AudNXJw0DRqlnNE2Xbm3ReW51JluEZvHoE90aKU+ LmIGaNl0lE/agfvRtZNZW96wcNtJO3gQUX4CeQshG22jEhwru6gPCqmPA g==; X-IronPort-AV: E=McAfee;i="6500,9779,10547"; a="401730672" X-IronPort-AV: E=Sophos;i="5.96,207,1665471600"; d="scan'208";a="401730672" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 30 Nov 2022 09:10:16 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10547"; a="973179926" X-IronPort-AV: E=Sophos;i="5.96,207,1665471600"; d="scan'208";a="973179926" Received: from txandevlnx322.an.intel.com ([10.123.117.44]) by fmsmga005.fm.intel.com with ESMTP; 30 Nov 2022 09:10:16 -0800 From: Ganapati Kundapura To: dev@dpdk.org, jerinj@marvell.com, s.v.naga.harish.k@intel.com, abhinandan.gujjar@intel.com Cc: jay.jayatheerthan@intel.com Subject: [PATCH v1 2/5] eventdev/crypto: wrong crypto enqueue count stats Date: Wed, 30 Nov 2022 11:10:11 -0600 Message-Id: <20221130171014.1723899-2-ganapati.kundapura@intel.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20221130171014.1723899-1-ganapati.kundapura@intel.com> References: <20221130171014.1723899-1-ganapati.kundapura@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 crypto_enq_count is updated on failure to enqueue ops to cryptodev. Updated crypto_enq_count on successful enqueue of ops to cryptodev. Signed-off-by: Ganapati Kundapura diff --git a/lib/eventdev/rte_event_crypto_adapter.c b/lib/eventdev/rte_event_crypto_adapter.c index 1c0a22b..ef3dbe9 100644 --- a/lib/eventdev/rte_event_crypto_adapter.c +++ b/lib/eventdev/rte_event_crypto_adapter.c @@ -485,6 +485,9 @@ eca_enq_to_cryptodev(struct event_crypto_adapter *adapter, struct rte_event *ev, cdev_id, qp_id, &nb_enqueued); + stats->crypto_enq_count += nb_enqueued; + n += nb_enqueued; + /** * If some crypto ops failed to flush to cdev and * space for another batch is not available, stop @@ -495,9 +498,6 @@ eca_enq_to_cryptodev(struct event_crypto_adapter *adapter, struct rte_event *ev, &qp_info->cbuf))) adapter->stop_enq_to_cryptodev = true; } - - stats->crypto_enq_count += nb_enqueued; - n += nb_enqueued; } return n;