From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lj1-f196.google.com (mail-lj1-f196.google.com [209.85.208.196]) by dpdk.org (Postfix) with ESMTP id 664C54F9B for ; Fri, 21 Sep 2018 16:54:07 +0200 (CEST) Received: by mail-lj1-f196.google.com with SMTP id x16-v6so5485491ljd.12 for ; Fri, 21 Sep 2018 07:54:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=semihalf-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=JFMsxv3Ue6TvCgiPbLm8fVO7197LpDc77a4WTFL8/Ic=; b=LmIw88C3B3KZRry+0iZoCjM2jIEVabGmS6dXN6APQm/teY76Oip2I3dvet7nR4wzGr DmSSLyExwevuSzZR5a30iAnx075L+rWSx9XsCnl1ubtzg4p9ZhmEgvDMVPahb7zqVqD1 UzA4o542XIn4jBzyndV9jsKia7+je4Dxa8UkuW9AB4PC3KjuSf6W9EExgxXl2pI8q3ge 4870A/5pZXWJDGRMfVzYz3RQPZZEA7R04JfHgs5emRZ0/R+7F8NgkkaFoUvu3ATQqrxC YyCALH9/9uNXI4Sety9WNIeiki+0mBnqhhHrqK3ZGp5FuTTYftErvAB0YHpDVtMZ5G9U VRcA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=JFMsxv3Ue6TvCgiPbLm8fVO7197LpDc77a4WTFL8/Ic=; b=DGe/WKByzOcvQiYPDRdcG/eqQMMxNoweSLPFsyJ18M5hT8eYxNsQYE+PvP4d3Xjtfh IDYcvIeMWSe0xDvcI8rG5zoj+C1ocyFaGqRgxPXNJeSozJoX2GdBiQzGpMZpu37GY/5G oy9DTDm6KBaN58AJ2iYs3etQdXWFLChyGP1MWhE9KTJUBQ2XL9nIu34mz5PBXYETSiFK K9L29Sly80fsdZDgjgNrELCNnGa/qEYXCeiTg/e8ymU9WDvqmZaKs5idYfdwKYQrHvLZ GvyqFJJklxBdtgKJwqhhqMMvACcs62yBxf+o+bNYydcuNYKbVCwwTLbuXLCc332Znn21 ANwQ== X-Gm-Message-State: ABuFfojc2VgfrXJsh9AteV7iNwzdhMiwCS9la//N8nAiD2bcTT4QRtKU dWZl9WLzPadwdtc2OTqjuYnzgkEKfHI= X-Google-Smtp-Source: ACcGV60ScyO+gpJUKcs9WnsS/+/Rfd9fKTT131i4QzPyMCzMWhLk0ocGn5IeNQ7Ma+SXv2zIoaYGXg== X-Received: by 2002:a2e:5d57:: with SMTP id r84-v6mr2082302ljb.89.1537541646848; Fri, 21 Sep 2018 07:54:06 -0700 (PDT) Received: from amok.semihalf.local (31-172-191-173.noc.fibertech.net.pl. [31.172.191.173]) by smtp.googlemail.com with ESMTPSA id d13-v6sm2268744lfi.74.2018.09.21.07.54.05 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 21 Sep 2018 07:54:06 -0700 (PDT) From: Andrzej Ostruszka To: dev@dpdk.org Cc: mw@semihalf.com, nadavh@marvell.com, Tomasz Duszynski Date: Fri, 21 Sep 2018 16:53:58 +0200 Message-Id: <1537541639-22764-6-git-send-email-amo@semihalf.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1537541639-22764-1-git-send-email-amo@semihalf.com> References: <1535118895-6505-1-git-send-email-tdu@semihalf.com> <1537541639-22764-1-git-send-email-amo@semihalf.com> Subject: [dpdk-dev] [PATCH v2 5/6] crypto/mvsam: support for crypto/auth NULL algorithms X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Sep 2018 14:54:07 -0000 From: Tomasz Duszynski Add support for both cipher and auth NULL algorithms. Signed-off-by: Tomasz Duszynski Reviewed-by: Natalie Samsonov --- drivers/crypto/mvsam/rte_mrvl_pmd.c | 6 +++++ drivers/crypto/mvsam/rte_mrvl_pmd_ops.c | 45 +++++++++++++++++++++++++++++++++ 2 files changed, 51 insertions(+) diff --git a/drivers/crypto/mvsam/rte_mrvl_pmd.c b/drivers/crypto/mvsam/rte_mrvl_pmd.c index 08d4a23..961802e 100644 --- a/drivers/crypto/mvsam/rte_mrvl_pmd.c +++ b/drivers/crypto/mvsam/rte_mrvl_pmd.c @@ -69,6 +69,9 @@ __rte_aligned(32); */ static const struct cipher_params_mapping cipher_map[RTE_CRYPTO_CIPHER_LIST_END] = { + [RTE_CRYPTO_CIPHER_NULL] = { + .supported = ALGO_SUPPORTED, + .cipher_alg = SAM_CIPHER_NONE }, [RTE_CRYPTO_CIPHER_3DES_CBC] = { .supported = ALGO_SUPPORTED, .cipher_alg = SAM_CIPHER_3DES, @@ -106,6 +109,9 @@ struct cipher_params_mapping cipher_map[RTE_CRYPTO_CIPHER_LIST_END] = { */ static const struct auth_params_mapping auth_map[RTE_CRYPTO_AUTH_LIST_END] = { + [RTE_CRYPTO_AUTH_NULL] = { + .supported = ALGO_SUPPORTED, + .auth_alg = SAM_AUTH_NONE }, [RTE_CRYPTO_AUTH_MD5_HMAC] = { .supported = ALGO_SUPPORTED, .auth_alg = SAM_AUTH_HMAC_MD5 }, diff --git a/drivers/crypto/mvsam/rte_mrvl_pmd_ops.c b/drivers/crypto/mvsam/rte_mrvl_pmd_ops.c index 3d3bbf1..f3251aa 100644 --- a/drivers/crypto/mvsam/rte_mrvl_pmd_ops.c +++ b/drivers/crypto/mvsam/rte_mrvl_pmd_ops.c @@ -413,6 +413,51 @@ static const struct rte_cryptodev_capabilities }, } }, } }, + { /* NULL (AUTH) */ + .op = RTE_CRYPTO_OP_TYPE_SYMMETRIC, + {.sym = { + .xform_type = RTE_CRYPTO_SYM_XFORM_AUTH, + {.auth = { + .algo = RTE_CRYPTO_AUTH_NULL, + .block_size = 1, + .key_size = { + .min = 0, + .max = 0, + .increment = 0 + }, + .digest_size = { + .min = 0, + .max = 0, + .increment = 0 + }, + .iv_size = { + .min = 0, + .max = 0, + .increment = 0 + } + }, }, + }, }, + }, + { /* NULL (CIPHER) */ + .op = RTE_CRYPTO_OP_TYPE_SYMMETRIC, + {.sym = { + .xform_type = RTE_CRYPTO_SYM_XFORM_CIPHER, + {.cipher = { + .algo = RTE_CRYPTO_CIPHER_NULL, + .block_size = 1, + .key_size = { + .min = 0, + .max = 0, + .increment = 0 + }, + .iv_size = { + .min = 0, + .max = 0, + .increment = 0 + } + }, }, + }, } + }, RTE_CRYPTODEV_END_OF_CAPABILITIES_LIST() }; -- 2.7.4