From: Kirill Rybalchenko Date: Mon, 17 Jul 2017 15:25:00 +0000 (+0100) Subject: cryptodev: remove crypto operation status value X-Git-Tag: spdx-start~2386 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=26c4ab1a16be8f0c5c2262d182afa86397c39969;p=dpdk.git cryptodev: remove crypto operation status value Crypto operation status RTE_CRYPTO_OP_STATUS_ENQUEUED is removed from rte_crypto.h as it is not needed for crypto operation processing. This status value is redundant to RTE_CRYPTO_OP_STATUS_NOT_PROCESSED value and it was not intended to be part of public API. Signed-off-by: Kirill Rybalchenko Acked-by: Declan Doherty --- diff --git a/doc/guides/rel_notes/release_17_08.rst b/doc/guides/rel_notes/release_17_08.rst index cf0b7cb3f9..292e87a1a7 100644 --- a/doc/guides/rel_notes/release_17_08.rst +++ b/doc/guides/rel_notes/release_17_08.rst @@ -293,6 +293,7 @@ API Changes * Added new field ``session_pool`` to ``rte_cryptodev_queue_pair_setup()``. * Removed ``aad_size`` parameter from ``rte_cryptodev_sym_capability_check_auth()``. * Added ``iv_size`` parameter to ``rte_cryptodev_sym_capability_check_auth()``. + * Removed ``RTE_CRYPTO_OP_STATUS_ENQUEUED`` from enum ``rte_crypto_op_status``. ABI Changes diff --git a/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c b/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c index fda662fe4f..032d264db7 100644 --- a/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c +++ b/drivers/crypto/aesni_mb/rte_aesni_mb_pmd.c @@ -414,7 +414,6 @@ set_mb_job_params(JOB_AES_HMAC *job, struct aesni_mb_qp *qp, op->status = RTE_CRYPTO_OP_STATUS_INVALID_SESSION; return -1; } - op->status = RTE_CRYPTO_OP_STATUS_ENQUEUED; /* Set crypto operation */ job->chain_order = session->chain_order; @@ -541,7 +540,7 @@ post_process_mb_job(struct aesni_mb_qp *qp, JOB_AES_HMAC *job) op->sym->session, cryptodev_driver_id); - if (unlikely(op->status == RTE_CRYPTO_OP_STATUS_ENQUEUED)) { + if (likely(op->status == RTE_CRYPTO_OP_STATUS_NOT_PROCESSED)) { switch (job->status) { case STS_COMPLETED: op->status = RTE_CRYPTO_OP_STATUS_SUCCESS; diff --git a/drivers/crypto/scheduler/scheduler_pmd_private.h b/drivers/crypto/scheduler/scheduler_pmd_private.h index a786d3a4d9..e606716ac7 100644 --- a/drivers/crypto/scheduler/scheduler_pmd_private.h +++ b/drivers/crypto/scheduler/scheduler_pmd_private.h @@ -142,8 +142,7 @@ scheduler_order_drain(struct rte_ring *order_ring, while (nb_ops_to_deq < nb_objs) { SCHEDULER_GET_RING_OBJ(order_ring, nb_ops_to_deq, op); - if (op->status == RTE_CRYPTO_OP_STATUS_NOT_PROCESSED || - op->status == RTE_CRYPTO_OP_STATUS_ENQUEUED) + if (op->status == RTE_CRYPTO_OP_STATUS_NOT_PROCESSED) break; nb_ops_to_deq++; } diff --git a/lib/librte_cryptodev/rte_crypto.h b/lib/librte_cryptodev/rte_crypto.h index 4695229e69..09083687d1 100644 --- a/lib/librte_cryptodev/rte_crypto.h +++ b/lib/librte_cryptodev/rte_crypto.h @@ -66,8 +66,6 @@ enum rte_crypto_op_status { /**< Operation completed successfully */ RTE_CRYPTO_OP_STATUS_NOT_PROCESSED, /**< Operation has not yet been processed by a crypto device */ - RTE_CRYPTO_OP_STATUS_ENQUEUED, - /**< Operation is enqueued on device */ RTE_CRYPTO_OP_STATUS_AUTH_FAILED, /**< Authentication verification failed */ RTE_CRYPTO_OP_STATUS_INVALID_SESSION,