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 67552A00C2; Thu, 21 Jul 2022 06:59:05 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 1AADD40A87; Thu, 21 Jul 2022 06:59:05 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0a-0016f401.pphosted.com [67.231.148.174]) by mails.dpdk.org (Postfix) with ESMTP id 20C4840A7A for ; Thu, 21 Jul 2022 06:59:03 +0200 (CEST) Received: from pps.filterd (m0045849.ppops.net [127.0.0.1]) by mx0a-0016f401.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 26KMtDgI027044; Wed, 20 Jul 2022 21:59:03 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : mime-version : content-transfer-encoding : content-type; s=pfpt0220; bh=RU72s2BJMfWT1gC6MBm4Bg4gZle18uw6ICDft5P+nnE=; b=e8Uu8UdSARKj398YAmzifGzlB9HG7o2EubJlPFUNYzQLj/P95XzzQlUWtRS0Id+C/BSY mrz1EW+0++25vhFf5rmqjsiXonAcSZ5XwnXKm1JGnuReB7RWmgfzMVQumQCYWZ3PeKqY opBdVT01Kai3fiHYT62gU1164nNgmK+oWOOQ1UA9CdvjFtiXr1VbxapAPR4LlZK1TxxK mWl0ZYKfoRRfDsR1CJBVJYWa13qH/a8NjWFlbKofQCql+K0ZPZcGAFU26UGMsPZnKoP3 ynaRb2UnV1sMK59967M4uD9l0pCmwPzmrJ0STkVySu4/aNoyDFyzJepfw0uT7x1BbcD7 tw== Received: from dc5-exch02.marvell.com ([199.233.59.182]) by mx0a-0016f401.pphosted.com (PPS) with ESMTPS id 3hejwcaxb8-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Wed, 20 Jul 2022 21:59:03 -0700 Received: from DC5-EXCH02.marvell.com (10.69.176.39) by DC5-EXCH02.marvell.com (10.69.176.39) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Wed, 20 Jul 2022 21:59:01 -0700 Received: from maili.marvell.com (10.69.176.80) by DC5-EXCH02.marvell.com (10.69.176.39) with Microsoft SMTP Server id 15.0.1497.18 via Frontend Transport; Wed, 20 Jul 2022 21:59:01 -0700 Received: from HY-LT1002.marvell.com (unknown [10.193.69.69]) by maili.marvell.com (Postfix) with ESMTP id 322C73F7077; Wed, 20 Jul 2022 21:58:58 -0700 (PDT) From: Anoob Joseph To: Akhil Goyal , Ciara Power , "Fan Zhang" CC: Jerin Jacob , Hemant Agrawal , Gagandeep Singh , Subject: [PATCH] app/crypto-perf: remove redundant function return Date: Thu, 21 Jul 2022 10:28:57 +0530 Message-ID: <20220721045857.818-1-anoobj@marvell.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Proofpoint-GUID: jy8dF19s8aWSLAE2i_qxN97TFi8fJFi9 X-Proofpoint-ORIG-GUID: jy8dF19s8aWSLAE2i_qxN97TFi8fJFi9 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.883,Hydra:6.0.517,FMLib:17.11.122.1 definitions=2022-07-20_12,2022-07-20_01,2022-06-22_01 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 Remove redundant function return value. The function is used in datapath and the return value is not checked in any of the existing callers. Signed-off-by: Anoob Joseph --- app/test-crypto-perf/cperf_ops.c | 36 +++++++++----------------------- app/test-crypto-perf/cperf_ops.h | 2 +- 2 files changed, 11 insertions(+), 27 deletions(-) diff --git a/app/test-crypto-perf/cperf_ops.c b/app/test-crypto-perf/cperf_ops.c index 0417af2d5e..d746d51082 100644 --- a/app/test-crypto-perf/cperf_ops.c +++ b/app/test-crypto-perf/cperf_ops.c @@ -9,7 +9,7 @@ #include "cperf_ops.h" #include "cperf_test_vectors.h" -static int +static void cperf_set_ops_asym(struct rte_crypto_op **ops, uint32_t src_buf_offset __rte_unused, uint32_t dst_buf_offset __rte_unused, uint16_t nb_ops, @@ -33,7 +33,6 @@ cperf_set_ops_asym(struct rte_crypto_op **ops, asym_op->modex.result.length = options->modex_data->result.len; rte_crypto_op_attach_asym_session(ops[i], asym_sess); } - return 0; } #ifdef RTE_LIB_SECURITY @@ -52,7 +51,7 @@ test_ipsec_vec_populate(struct rte_mbuf *m, const struct cperf_options *options, } } -static int +static void cperf_set_ops_security(struct rte_crypto_op **ops, uint32_t src_buf_offset __rte_unused, uint32_t dst_buf_offset __rte_unused, @@ -120,11 +119,9 @@ cperf_set_ops_security(struct rte_crypto_op **ops, RTE_SET_USED(tsc_start); RTE_SET_USED(test_vector); - - return 0; } -static int +static void cperf_set_ops_security_ipsec(struct rte_crypto_op **ops, uint32_t src_buf_offset __rte_unused, uint32_t dst_buf_offset __rte_unused, @@ -166,7 +163,7 @@ cperf_set_ops_security_ipsec(struct rte_crypto_op **ops, } if (options->test_file != NULL) - return 0; + return; tsc_start_temp = rte_rdtsc_precise(); @@ -179,13 +176,11 @@ cperf_set_ops_security_ipsec(struct rte_crypto_op **ops, tsc_end_temp = rte_rdtsc_precise(); *tsc_start += tsc_end_temp - tsc_start_temp; - - return 0; } #endif -static int +static void cperf_set_ops_null_cipher(struct rte_crypto_op **ops, uint32_t src_buf_offset, uint32_t dst_buf_offset, uint16_t nb_ops, struct rte_cryptodev_sym_session *sess, @@ -221,11 +216,9 @@ cperf_set_ops_null_cipher(struct rte_crypto_op **ops, sym_op->cipher.data.length = options->test_buffer_size; sym_op->cipher.data.offset = 0; } - - return 0; } -static int +static void cperf_set_ops_null_auth(struct rte_crypto_op **ops, uint32_t src_buf_offset, uint32_t dst_buf_offset, uint16_t nb_ops, struct rte_cryptodev_sym_session *sess, @@ -261,11 +254,9 @@ cperf_set_ops_null_auth(struct rte_crypto_op **ops, sym_op->auth.data.length = options->test_buffer_size; sym_op->auth.data.offset = 0; } - - return 0; } -static int +static void cperf_set_ops_cipher(struct rte_crypto_op **ops, uint32_t src_buf_offset, uint32_t dst_buf_offset, uint16_t nb_ops, struct rte_cryptodev_sym_session *sess, @@ -318,11 +309,9 @@ cperf_set_ops_cipher(struct rte_crypto_op **ops, } } - - return 0; } -static int +static void cperf_set_ops_auth(struct rte_crypto_op **ops, uint32_t src_buf_offset, uint32_t dst_buf_offset, uint16_t nb_ops, struct rte_cryptodev_sym_session *sess, @@ -420,10 +409,9 @@ cperf_set_ops_auth(struct rte_crypto_op **ops, } } } - return 0; } -static int +static void cperf_set_ops_cipher_auth(struct rte_crypto_op **ops, uint32_t src_buf_offset, uint32_t dst_buf_offset, uint16_t nb_ops, struct rte_cryptodev_sym_session *sess, @@ -539,11 +527,9 @@ cperf_set_ops_cipher_auth(struct rte_crypto_op **ops, } } - - return 0; } -static int +static void cperf_set_ops_aead(struct rte_crypto_op **ops, uint32_t src_buf_offset, uint32_t dst_buf_offset, uint16_t nb_ops, struct rte_cryptodev_sym_session *sess, @@ -652,8 +638,6 @@ cperf_set_ops_aead(struct rte_crypto_op **ops, } } } - - return 0; } static struct rte_cryptodev_sym_session * diff --git a/app/test-crypto-perf/cperf_ops.h b/app/test-crypto-perf/cperf_ops.h index 30d38f90e3..1d2fbb4e30 100644 --- a/app/test-crypto-perf/cperf_ops.h +++ b/app/test-crypto-perf/cperf_ops.h @@ -18,7 +18,7 @@ typedef struct rte_cryptodev_sym_session *(*cperf_sessions_create_t)( const struct cperf_test_vector *test_vector, uint16_t iv_offset); -typedef int (*cperf_populate_ops_t)(struct rte_crypto_op **ops, +typedef void (*cperf_populate_ops_t)(struct rte_crypto_op **ops, uint32_t src_buf_offset, uint32_t dst_buf_offset, uint16_t nb_ops, struct rte_cryptodev_sym_session *sess, const struct cperf_options *options, -- 2.25.1