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 34C4945903 for ; Wed, 4 Sep 2024 16:24:22 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 126324025A; Wed, 4 Sep 2024 16:24:22 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mails.dpdk.org (Postfix) with ESMTP id 7B5FC4014F for ; Wed, 4 Sep 2024 16:24:20 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1725459860; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:autocrypt:autocrypt; bh=WR1s/qfqlllI9c+xZRGnGq122YuNZptd3YPKXrmxxl4=; b=a3O1QymOPvWQlQzNS6ErNCgq2TK+Z2VLhyePHlbD2exPHdda6Sy/JhxmurIspFC+myS5A7 6vem7dhn75gO/obXym3C5ylDsMneBJsFXwz6UxmiXIPyClmxX6YKrCQMjII5eSimqxDyEu uB0RHmmHXIVu7lZRAnkhcMZ6hBg6dNo= Received: from mail-ej1-f69.google.com (mail-ej1-f69.google.com [209.85.218.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-358-KPnGr0R0NYe-15s-C5BY2w-1; Wed, 04 Sep 2024 10:24:18 -0400 X-MC-Unique: KPnGr0R0NYe-15s-C5BY2w-1 Received: by mail-ej1-f69.google.com with SMTP id a640c23a62f3a-a867b95db47so462377866b.1 for ; Wed, 04 Sep 2024 07:24:18 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1725459857; x=1726064657; h=content-transfer-encoding:in-reply-to:autocrypt:content-language :references:cc:to:from:subject:user-agent:mime-version:date :message-id:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=WR1s/qfqlllI9c+xZRGnGq122YuNZptd3YPKXrmxxl4=; b=YdYRJIRJD+Mpu1W2VpOFYoFeBAEuhruKkU+w4VzXeVlvzuTsfQCWOE86DeSk6gtSoT Xdj6yh3KRym6x9uZ0i68jW1HOOzVdh/bcycfxqd2+Ta9gFoQ/6qADXyAx1KsS/Wj3/yR DCrhUGRJz9sw/psjm/seGPnqnyzcEGIgEkeWqLmRGRlZ2/Z9FdKlK4BJ2m6KyUsdveHp mYNy83MJFcZewT+kGWgUoXR8V8NqlX4xy21KpeD5IwmgFq1KB1VSm+v+jGWXdO3dTcy6 jMMQW188r4o4kgl2UaO1vhsO4fhrKS/b8x4h6CGINjPAVgMnJgN5lZ7vrXYnTovkPSZG kBaw== X-Forwarded-Encrypted: i=1; AJvYcCWDxbzmI2qCemCn530UBuKQ4VGODTOsPjtsZ6rpjlndHpS08hYTS8AdyUJhqrvfr2PwFzEWvB0=@dpdk.org X-Gm-Message-State: AOJu0YwK5H0mypr8pd8piGExmDfFKH4Ujy1AFIvQyNVZnwmyPC2CXG9p eDV2wcnm3iDdSPyvJs8g9JHzU56m8X80hhKPJ6+1BSQ7pyq9QsBdD/LHv3OGNNvhwEBVBPuJIVt sUoGpIwF4lxr6RU5yw+ivFSGWPOklFXkIJAQsai0N3d7L X-Received: by 2002:a17:906:6a28:b0:a86:90b8:9ac9 with SMTP id a640c23a62f3a-a89d879c689mr1053036666b.39.1725459857580; Wed, 04 Sep 2024 07:24:17 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEQdr+h9uujhGHonD9EoIUrwO7jIxeMTyDMvEOcpde2jlXJlJjf82lAMWm7fJ8j8R0meAiL6g== X-Received: by 2002:a17:906:6a28:b0:a86:90b8:9ac9 with SMTP id a640c23a62f3a-a89d879c689mr1053032966b.39.1725459856946; Wed, 04 Sep 2024 07:24:16 -0700 (PDT) Received: from [192.168.0.36] ([78.19.103.36]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a89891d77fasm813398466b.167.2024.09.04.07.24.15 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 04 Sep 2024 07:24:16 -0700 (PDT) Message-ID: <2448081f-cb09-4a11-bddb-3b904d26dbf2@redhat.com> Date: Wed, 4 Sep 2024 15:24:15 +0100 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: patch 'crypto/openssl: set cipher padding once' has been queued to stable release 21.11.8 From: Kevin Traynor To: Jack Bond-Preston Cc: Kai Ji , Wathsala Vithanage , dpdk stable References: <20240823161929.1004778-1-ktraynor@redhat.com> <20240823161929.1004778-65-ktraynor@redhat.com> Autocrypt: addr=ktraynor@redhat.com; keydata= xsFNBF2J2awBEADUEPNhgNI+nJNgiTAUcw4YIgVXEoHlsNPyyzG1BEXkWXALy0Y3fNTiw6+r ltWDkF9jzL9kfkecgQ67itGfk1OaBXgSGKuw1PUpxAwX2Bi76LAR6M5OsyGM9TSVVQwARalz hMwRBIZPzPc7or6Pw7jAOJ8SQGJ1Zlp1YJCjrvpe87V1tH/LY8Wnxn/EuoseFmWILAQZAtYS tGjcrAgYn3SPMLR1B0BP5bTBY06vWQjiufH8drenfDnMJAzuBdG1mqjnTqCjULZ3Hunv4xqZ aMnkvL/K5Tj1c12Oe4930EE53LrXIBUltRg5mBudSWHnC7twjH0082HH9f963Z/2UI63SFIT iUvRvAzJYytgy7XnWLQ0+goZBADKYfolOuC0H8VgCaux8u8KFF28Dy+N6TV2KI58jTlyg1Zu l7QwykZpnOkJFiy37Gfbu3YEOzO72cP/S7/A+zvuqkxi63jyEkd+FY99vLt/HN2MUZwRmKDw UPbLkmrs8WU01/POVsqDcfvz7vu2St8hqqTiSIdQGS2zyTKB2/DvPSM3jws3udkIYSuhn+X4 QBiV6lkVZ7DSE6a065gnAauAql+b32Eymy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u/0MVRg/roUTa0FyEbNsvz4qAecyW yWzMcVrcGJDQLC9JLKEpoyUF6gdTKaiDL2Vao4+XRIA3Y57b6MO35a3HuzAv7+i5Z0mnDEJO XxXqTOmKYpMIGexzM/PtuA0712sT1abG9tAJ17ao/B7cqMW5IkKkalemFbWfI2unns4Papvo tk9igVqyp6EJDU98z5TJioCVojwK2laDaoIjTJk9YYv3iwCsqPd5feU= In-Reply-To: <20240823161929.1004778-65-ktraynor@redhat.com> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org On 23/08/2024 17:18, Kevin Traynor wrote: > Hi, > > FYI, your patch has been queued to stable release 21.11.8 > > Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. > It will be pushed if I get no objections before 08/28/24. So please > shout if anyone has objections. > > Also note that after the patch there's a diff of the upstream commit vs the > patch applied to the branch. This will indicate if there was any rebasing > needed to apply to the stable branch. If there were code changes for rebasing > (ie: not only metadata diffs), please double check that the rebase was > correctly done. > > Queued patches are on a temporary branch at: > https://github.com/kevintraynor/dpdk-stable > > This queued commit can be viewed at: > https://github.com/kevintraynor/dpdk-stable/commit/d6048dac1e75d310ad2dc6b89278567c8c925b56 > > Thanks. > > Kevin > Hi, this patch was causing unit test failures in the CI. CI run without patch applied: https://dpdkdashboard.iol.unh.edu/results/dashboard/tarballs/30439/ CI run with this patch applied. See extra unit test fails. 1/2 DPDK:driver-tests / cryptodev_openssl_autotest FAIL 0.84 s (killed by signal 11 SIGSEGV) https://dpdkdashboard.iol.unh.edu/results/dashboard/tarballs/30433/ You can get full logs from the relevant platforms. I've removed it from 21.11.8. I can re-add for 21.11.9 if it is rebased and passing CI. thanks, Kevin. > --- > From d6048dac1e75d310ad2dc6b89278567c8c925b56 Mon Sep 17 00:00:00 2001 > From: Jack Bond-Preston > Date: Wed, 3 Jul 2024 13:45:51 +0000 > Subject: [PATCH] crypto/openssl: set cipher padding once > > [ upstream commit d2bf59017315dc18eb6c9f2d7acd10dfb8d7758e ] > > Setting the cipher padding has a noticeable performance footprint, > and it doesn't need to be done for every call to > process_openssl_cipher_{en,de}crypt(). Setting it causes OpenSSL to set > it on every future context re-init. Thus, for every buffer after the > first one, the padding is being set twice. > > Instead, just set the cipher padding once - when configuring the session > parameters - avoiding the unnecessary double setting behaviour. This is > skipped for AEAD ciphers, where disabling padding is not necessary. > > Throughput performance uplift measurements for AES-CBC-128 encrypt on > Ampere Altra Max platform: > 1 worker lcore > | buffer sz (B) | prev (Gbps) | optimised (Gbps) | uplift | > |-----------------+---------------+--------------------+----------| > | 64 | 2.97 | 3.72 | 25.2% | > | 256 | 8.10 | 9.42 | 16.3% | > | 1024 | 14.22 | 15.18 | 6.8% | > | 2048 | 16.28 | 16.93 | 4.0% | > | 4096 | 17.58 | 17.97 | 2.2% | > > 8 worker lcores > | buffer sz (B) | prev (Gbps) | optimised (Gbps) | uplift | > |-----------------+---------------+--------------------+----------| > | 64 | 21.27 | 29.85 | 40.3% | > | 256 | 60.05 | 75.53 | 25.8% | > | 1024 | 110.11 | 121.56 | 10.4% | > | 2048 | 128.05 | 135.40 | 5.7% | > | 4096 | 139.45 | 143.76 | 3.1% | > > Signed-off-by: Jack Bond-Preston > Acked-by: Kai Ji > Reviewed-by: Wathsala Vithanage > --- > drivers/crypto/openssl/rte_openssl_pmd.c | 6 ++---- > 1 file changed, 2 insertions(+), 4 deletions(-) > > diff --git a/drivers/crypto/openssl/rte_openssl_pmd.c b/drivers/crypto/openssl/rte_openssl_pmd.c > index a321258980..b82f6939a5 100644 > --- a/drivers/crypto/openssl/rte_openssl_pmd.c > +++ b/drivers/crypto/openssl/rte_openssl_pmd.c > @@ -615,4 +615,6 @@ openssl_set_session_auth_parameters(struct openssl_session *sess, > } > > + EVP_CIPHER_CTX_set_padding(sess->cipher.ctx, 0); > + > return 0; > } > @@ -943,6 +945,4 @@ process_openssl_cipher_encrypt(struct rte_mbuf *mbuf_src, uint8_t *dst, > goto process_cipher_encrypt_err; > > - EVP_CIPHER_CTX_set_padding(ctx, 0); > - > if (process_openssl_encryption_update(mbuf_src, offset, &dst, > srclen, ctx, inplace)) > @@ -993,6 +993,4 @@ process_openssl_cipher_decrypt(struct rte_mbuf *mbuf_src, uint8_t *dst, > goto process_cipher_decrypt_err; > > - EVP_CIPHER_CTX_set_padding(ctx, 0); > - > if (process_openssl_decryption_update(mbuf_src, offset, &dst, > srclen, ctx, inplace))