RE: [PATCH] test/crypto: fix RSA decrypt op validation

2025-06-12 Thread Gowrishankar Muthukrishnan
, for openssl PMD ? If required, I can start filing a Bugzilla as well. Thanks, Gowrishankar > > Following RSA encrypt op, same plaintext buffer is used as output buffer for > decrypt op, hence comparing plaintext buffer against same buffer pointer in > crypto op always succeed irresp

[PATCH] test/crypto: test vectors for additional ECDH groups

2025-05-28 Thread Gowrishankar Muthukrishnan
Add test vectors for ECDH groups 19, 20 and 21. Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev_asym.c | 39 ++- app/test/test_cryptodev_ecdh_test_vectors.h | 344 +++ app/test/test_cryptodev_ecdsa_test_vectors.h | 6 + 3 files changed

RE: [PATCH] test/crypto: fix RSA decrypt op validation

2025-05-28 Thread Gowrishankar Muthukrishnan
Recheck unit test failure for openssl 1.1.1 in some distros. Recheck-request: iol-unit-amd64-testing -- Gowrishankar > > Following RSA encrypt op, same plaintext buffer is used as output buffer for > decrypt op, hence comparing plaintext buffer against same buffer pointer in > cryp

RE: [PATCH] crypto/cnxk: fix uninitialized scalar variable

2025-05-15 Thread Gowrishankar Muthukrishnan
Dispatcher unit test failed which is unrelated to this patch and looks like infrastructure issue. Recheck-request: loongarch-unit-testing -- Gowrishankar > This change fixes an uninitialized local variable as reported in coverity > issue > 445390. > > Coverity-issue:

[PATCH] crypto/cnxk: fix out-of-bounds access

2025-05-15 Thread Gowrishankar Muthukrishnan
Fix coverity issue on out-of-bounds access. Coverity-issue: 403166, 403171, 403172 Fixes: 5686b573e4b ("crypto/cnxk: support SM2") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/cnxk/cnxk_ae.h | 9 + 1 file changed, 9 insertions(+) di

[PATCH] vhost/crypto: fix uninitialized variable

2025-05-15 Thread Gowrishankar Muthukrishnan
Fix uninitialized variable as reported in coverity scan. Coverity-issue: 457449 Fixes: d1b484bf187 ("vhost/crypto: support asymmetric RSA") Signed-off-by: Gowrishankar Muthukrishnan --- lib/vhost/vhost_crypto.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a

[PATCH] test/crypto: fix return value in RSA test

2025-05-15 Thread Gowrishankar Muthukrishnan
This patch fixes incorrect return value when RSA negative test scenario is validated. Coverity-issue: 457463 Fixes: 9682e8246ae ("test/crypto: add negative case for RSA verification") Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev_asym.c | 1 + 1 file

[PATCH] crypto/cnxk: fix uninitialized scalar variable

2025-05-15 Thread Gowrishankar Muthukrishnan
This change fixes an uninitialized local variable as reported in coverity issue 445390. Coverity-issue: 445390 Fixes: a8ebe94f8cc ("crypto/cnxk: support EdDSA") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/cnxk/cnxk_ae.h | 2 +- 1 file changed, 1

[PATCH] crypto/virtio: check for invalid IOVA address

2025-05-15 Thread Gowrishankar Muthukrishnan
This change fixes coverity issue on overflowed constant. Bad phys address should be checked before using it in descriptor. Coverity issue: 457462, 457465 Fixes: 10702138f1a ("crypto/virtio: support asymmetric RSA") Signed-off-by: Gowrishankar Muthukrishnan --- drivers/cry

[PATCH v2] test/crypto: increment dequeue timeout

2025-05-14 Thread Gowrishankar Muthukrishnan
Increment dequeue timeout to allow implementations taking longer cycles. Signed-off-by: Gowrishankar Muthukrishnan --- v2: - no changes. only for CI. --- app/test/test_cryptodev_asym.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/test/test_cryptodev_asym.c b/app/test

[PATCH] test/crypto: fix return value in RSA verify test

2025-05-10 Thread Gowrishankar Muthukrishnan
This patch fixes incorrect return value when RSA negative test scenario is validated. Coverity-issue: 457463 Fixes: 9682e8246ae ("test/crypto: add negative case for RSA verification") Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev_asym.c | 1 + 1 file

[PATCH] test/crypto: fix RSA decrypt op validation

2025-05-10 Thread Gowrishankar Muthukrishnan
. Fixes: 5ae36995f10 ("test/crypto: move RSA enqueue/dequeue into functions") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev_asym.c | 21 + 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/app/test/test_cryptodev_as

[PATCH] crypto/virtio: fix DER encoding for positive RSA param

2025-05-10 Thread Gowrishankar Muthukrishnan
As per RFC 8017, RSA parameter needs to be positive integer. This patch fixes TLV encoding function appropriately. Fixes: 6fe6a7f7bcf ("crypto/virtio: add asymmetric RSA support") Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/virtio/virtio_crypto

[PATCH] crypto/virtio: fix DER encoding of RSA public key

2025-05-10 Thread Gowrishankar Muthukrishnan
As per RFC 8017, RSA public key in ASN.1 should have only modulus and exponent values. Add a separate encoding function to follow this standard. Fixes: 6fe6a7f7bcf ("crypto/virtio: add asymmetric RSA support") Signed-off-by: Gowrishankar Muthukrishnan --- drivers/cry

[PATCH v2] test/crypto: increment dequeue timeout

2025-05-06 Thread Gowrishankar Muthukrishnan
Increment dequeue timeout to allow implementations taking longer cycles. Signed-off-by: Gowrishankar Muthukrishnan --- v2: - no changes. only for CI. --- app/test/test_cryptodev_asym.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/test/test_cryptodev_asym.c b/app/test

[PATCH] app/crypto-perf: add RSA test vectors

2025-04-29 Thread Gowrishankar Muthukrishnan
Add test vectors to benchmark larger RSA modulus. Signed-off-by: Gowrishankar Muthukrishnan --- app/test-crypto-perf/cperf_options.h |3 + app/test-crypto-perf/cperf_options_parsing.c | 132 +- app/test-crypto-perf/cperf_test_vectors.c| 1386 +- app/test-crypto

[PATCH] crypto/virtio: support RSA 8K mod ops

2025-04-29 Thread Gowrishankar Muthukrishnan
Support RSA 8K mod ops in virtio PMD. Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/virtio/virtio_cryptodev.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/crypto/virtio/virtio_cryptodev.h b/drivers/crypto/virtio/virtio_cryptodev.h index

[PATCH] test/crypto: increment dequeue timeout

2025-04-20 Thread Gowrishankar Muthukrishnan
Increment dequeue timeout to allow implementations taking longer cycles. Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev_asym.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/test/test_cryptodev_asym.c b/app/test/test_cryptodev_asym.c index

[PATCH] test/crypto: add test case for modex group 24

2025-04-20 Thread Gowrishankar Muthukrishnan
Add test case for modex group 24. Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev_asym.c | 16 ++ app/test/test_cryptodev_mod_test_vectors.h | 227 + 2 files changed, 243 insertions(+) diff --git a/app/test/test_cryptodev_asym.c b/app/test

[PATCH] test/crypto: skip test when virtio PMD not loaded

2025-03-11 Thread Gowrishankar Muthukrishnan
Skip asymmetric test when virtio PMD is not loaded. Fixes: 7e2e9d5f3227 ("test/crypto: add asymmetric cases for virtio") Fixes: a8f3d4f5b547 ("test/crypto: add cases for virtio-user") Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev_asym.c | 4 ++-

RE: [EXTERNAL] [PATCH] vhost/crypto: fix locking

2025-03-05 Thread Gowrishankar Muthukrishnan
t; Fixes: 88c73b5434e6 ("vhost/crypto: fix thread safety check") > > Signed-off-by: David Marchand Tested-by: Gowrishankar Muthukrishnan Thanks, Gowrishankar

RE: [EXTERNAL] [PATCH] vhost/crypto: fix build with asserts

2025-03-05 Thread Gowrishankar Muthukrishnan
> > Fixes: d1b484bf1876 ("vhost/crypto: support asymmetric RSA") > > Signed-off-by: David Marchand Tested-by: Gowrishankar Muthukrishnan

[v6 4/6] crypto/virtio: add vDPA backend

2025-03-04 Thread Gowrishankar Muthukrishnan
Add vDPA backend to virtio_user crypto. Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/virtio/meson.build | 7 + drivers/crypto/virtio/virtio_cryptodev.c | 57 +- drivers/crypto/virtio/virtio_cryptodev.h | 3 + drivers/crypto/virtio/virtio_logs.h

[v6 3/6] crypto/virtio: add packed ring support

2025-03-04 Thread Gowrishankar Muthukrishnan
Add packed ring support. Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/virtio/virtio_cryptodev.c | 125 +++ drivers/crypto/virtio/virtio_cryptodev.h | 13 +- drivers/crypto/virtio/virtio_cvq.c | 103 +- drivers/crypto/virtio/virtio_pci.h | 25 ++ drivers

[v6 6/6] test/crypto: add tests for virtio user PMD

2025-03-04 Thread Gowrishankar Muthukrishnan
Reuse virtio_crypto tests for testing virtio_crypto_user PMD. Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev.c | 7 +++ app/test/test_cryptodev.h | 1 + app/test/test_cryptodev_asym.c | 15 +++ 3 files changed, 23 insertions(+) diff --git a

[v6 5/6] test/crypto: add asymmetric tests for virtio PMD

2025-03-04 Thread Gowrishankar Muthukrishnan
Add asymmetric tests for Virtio PMD. Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev_asym.c | 28 1 file changed, 28 insertions(+) diff --git a/app/test/test_cryptodev_asym.c b/app/test/test_cryptodev_asym.c index 9b5f3c545e..ac47be724f 100644

[v6 2/6] crypto/virtio: refactor queue operations

2025-03-04 Thread Gowrishankar Muthukrishnan
Move existing control queue operations into a common place that would be shared with other virtio type of devices. Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/virtio/meson.build | 1 + drivers/crypto/virtio/virtio_crypto_algs.h | 2 +- drivers/crypto/virtio

[v6 0/6] crypto/virtio: enhancements for RSA and vDPA

2025-03-04 Thread Gowrishankar Muthukrishnan
This patch series enhances virtio crypto PMD to: * support RSA * support packed virtio ring * support vDPA backend v6: - patches rebased. Gowrishankar Muthukrishnan (6): crypto/virtio: add asymmetric RSA support crypto/virtio: refactor queue operations crypto/virtio: add packed ring

[v6 1/6] crypto/virtio: add asymmetric RSA support

2025-03-04 Thread Gowrishankar Muthukrishnan
Asymmetric RSA operations (SIGN, VERIFY, ENCRYPT and DECRYPT) are supported in virtio PMD. Signed-off-by: Gowrishankar Muthukrishnan --- doc/guides/cryptodevs/features/virtio.ini | 4 + doc/guides/rel_notes/release_25_03.rst| 4 + .../virtio/virtio_crypto_capabilities.h

RE: [EXTERNAL] Re: [v6 1/5] vhost: skip crypto op fetch before vring init

2025-02-28 Thread Gowrishankar Muthukrishnan
x27;t see little point > in having > in the first place..) and adjust annotations. > Yes I thought about it initially, but then I had thought vhost_crypto_process_one_req() is only static and called with locks held. Anyway, I have come up with one additional patch in series to fix it specifically. Thanks for your suggestion. Regards, Gowrishankar > > -- > David Marchand

RE: [EXTERNAL] Re: [v6 1/5] vhost: skip crypto op fetch before vring init

2025-02-28 Thread Gowrishankar Muthukrishnan
any other changes are required, we can assist going forward. We also believe this software backend needs to be reliable and hence can help test required virtio functionalities. Thanks, Gowrishankar Regards, Gowrishankar > Maxime

[v9 5/6] vhost: support asymmetric RSA crypto ops

2025-02-28 Thread Gowrishankar Muthukrishnan
Support asymmetric RSA crypto operations in vhost-user. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- doc/guides/rel_notes/release_25_03.rst | 3 + lib/vhost/vhost_crypto.c | 484 +++-- lib/vhost/virtio_crypto.h | 67

[v9 6/6] examples/vhost_crypto: support asymmetric crypto

2025-02-28 Thread Gowrishankar Muthukrishnan
Support asymmetric crypto operations. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- doc/guides/sample_app_ug/vhost_crypto.rst | 5 +++ examples/vhost_crypto/main.c | 50 +-- 2 files changed, 43 insertions(+), 12 deletions(-) diff --git a

[v9 4/6] examples/vhost_crypto: fix user callbacks

2025-02-28 Thread Gowrishankar Muthukrishnan
In order to handle new vhost user connection, use new_connection and destroy_connection callbacks. Fixes: f5188211c721 ("examples/vhost_crypto: add sample application") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- examples/vhost_crypto/

[v9 2/6] vhost: skip crypto op fetch before vring init

2025-02-28 Thread Gowrishankar Muthukrishnan
Until virtio avail ring is initialized (by VHOST_USER_SET_VRING_ADDR), worker thread should not try to fetch crypto op, which would lead to memory fault. Fixes: 939066d96563 ("vhost/crypto: add public function implementation") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrish

[v9 3/6] vhost: update vhost_user crypto session parameters

2025-02-28 Thread Gowrishankar Muthukrishnan
. Hence, it would break parsing vhost_user messages. This patch addresses both of the above problems. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- lib/vhost/vhost_crypto.c | 12 ++-- lib/vhost/vhost_user.h | 33 + 2 files changed, 35

[v9 1/6] vhost: fix thread safety checks for vhost crypto data req

2025-02-28 Thread Gowrishankar Muthukrishnan
not recognise this inherited lock and stops compilation. This patch explicitly uses vhost_virtqueue where ever required and fulfills thread safety checks. Signed-off-by: Gowrishankar Muthukrishnan --- lib/vhost/vhost_crypto.c | 76 ++-- 1 file changed, 41 inserti

[v9 0/6] vhost: add RSA support

2025-02-28 Thread Gowrishankar Muthukrishnan
This patch series supports asymmetric RSA in vhost crypto library. It also includes changes to improve vhost crypto library: * support newer QEMU versions. * fix broken vhost_crypto example application. * stabilize crypto fastpath operations. v9: - new patch 1/6 Gowrishankar Muthukrishnan (6

[v2] app/crypto-perf: add RSA support

2025-02-27 Thread Gowrishankar Muthukrishnan
From: Akhil Goyal Add RSA support in crypto-perf application. Signed-off-by: Akhil Goyal --- v2: - fixed RSA padding type. --- app/test-crypto-perf/cperf_ops.c | 69 app/test-crypto-perf/cperf_options.h | 4 + app/test-crypto-perf/cperf_options_parsing.c | 38

[v8 3/5] examples/vhost_crypto: fix user callbacks

2025-02-27 Thread Gowrishankar Muthukrishnan
In order to handle new vhost user connection, use new_connection and destroy_connection callbacks. Fixes: f5188211c721 ("examples/vhost_crypto: add sample application") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- examples/vhost_crypto/

[v8 2/5] vhost: update vhost_user crypto session parameters

2025-02-27 Thread Gowrishankar Muthukrishnan
. Hence, it would break parsing vhost_user messages. This patch addresses both of the above problems. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- lib/vhost/vhost_crypto.c | 12 ++-- lib/vhost/vhost_user.h | 33 + 2 files changed, 35

[v8 4/5] vhost: support asymmetric RSA crypto ops

2025-02-27 Thread Gowrishankar Muthukrishnan
Support asymmetric RSA crypto operations in vhost-user. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- doc/guides/rel_notes/release_25_03.rst | 3 + lib/vhost/vhost_crypto.c | 486 +++-- lib/vhost/virtio_crypto.h | 67

[v8 5/5] examples/vhost_crypto: support asymmetric crypto

2025-02-27 Thread Gowrishankar Muthukrishnan
Support asymmetric crypto operations. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- doc/guides/sample_app_ug/vhost_crypto.rst | 5 +++ examples/vhost_crypto/main.c | 50 +-- 2 files changed, 43 insertions(+), 12 deletions(-) diff --git a

[v8 1/5] vhost: skip crypto op fetch before vring init

2025-02-27 Thread Gowrishankar Muthukrishnan
Until virtio avail ring is initialized (by VHOST_USER_SET_VRING_ADDR), worker thread should not try to fetch crypto op, which would lead to memory fault. Fixes: 939066d96563 ("vhost/crypto: add public function implementation") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrish

[v8 0/5] vhost: add RSA support

2025-02-27 Thread Gowrishankar Muthukrishnan
This patch series supports asymmetric RSA in vhost crypto library. It also includes changes to improve vhost crypto library: * support newer QEMU versions. * fix broken vhost_crypto example application. * stabilize crypto fastpath operations. Gowrishankar Muthukrishnan (5): vhost: skip

RE: [EXTERNAL] Re: [v6 1/5] vhost: skip crypto op fetch before vring init

2025-02-27 Thread Gowrishankar Muthukrishnan
vc_req->dev = vcrypto->dev; vc_req->vq = vq; Thanks, Gowrishankar

[v7 5/5] examples/vhost_crypto: support asymmetric crypto

2025-02-27 Thread Gowrishankar Muthukrishnan
Support asymmetric crypto operations. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- doc/guides/sample_app_ug/vhost_crypto.rst | 5 +++ examples/vhost_crypto/main.c | 50 +-- 2 files changed, 43 insertions(+), 12 deletions(-) diff --git a

[v7 4/5] vhost: support asymmetric RSA crypto ops

2025-02-27 Thread Gowrishankar Muthukrishnan
Support asymmetric RSA crypto operations in vhost-user. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- doc/guides/rel_notes/release_25_03.rst | 3 + lib/vhost/vhost_crypto.c | 486 +++-- lib/vhost/virtio_crypto.h | 67

[v7 3/5] examples/vhost_crypto: fix user callbacks

2025-02-27 Thread Gowrishankar Muthukrishnan
In order to handle new vhost user connection, use new_connection and destroy_connection callbacks. Fixes: f5188211c721 ("examples/vhost_crypto: add sample application") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- examples/vhost_crypto/

[v7 2/5] vhost: update vhost_user crypto session parameters

2025-02-27 Thread Gowrishankar Muthukrishnan
. Hence, it would break parsing vhost_user messages. This patch addresses both of the above problems. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- lib/vhost/vhost_crypto.c | 12 ++-- lib/vhost/vhost_user.h | 33 + 2 files changed, 35

[v7 1/5] vhost: skip crypto op fetch before vring init

2025-02-27 Thread Gowrishankar Muthukrishnan
Until virtio avail ring is initialized (by VHOST_USER_SET_VRING_ADDR), worker thread should not try to fetch crypto op, which would lead to memory fault. Fixes: 939066d96563 ("vhost/crypto: add public function implementation") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrish

[v7 0/5] vhost: add RSA support

2025-02-27 Thread Gowrishankar Muthukrishnan
This patch series supports asymmetric RSA in vhost crypto library. It also includes changes to improve vhost crypto library: * support newer QEMU versions. * fix broken vhost_crypto example application. * stabilize crypto fastpath operations. Gowrishankar Muthukrishnan (5): vhost: skip

RE: [EXTERNAL] Re: [v6 1/5] vhost: skip crypto op fetch before vring init

2025-02-27 Thread Gowrishankar Muthukrishnan
eq() once implemented. > Ack. Thanks, Gowrishankar.

[v5 3/6] crypto/virtio: add packed ring support

2025-02-26 Thread Gowrishankar Muthukrishnan
Add packed ring support. Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/virtio/virtio_cryptodev.c | 125 +++ drivers/crypto/virtio/virtio_cryptodev.h | 13 +- drivers/crypto/virtio/virtio_cvq.c | 103 +- drivers/crypto/virtio/virtio_pci.h | 25 ++ drivers

[v5 1/6] crypto/virtio: add asymmetric RSA support

2025-02-26 Thread Gowrishankar Muthukrishnan
Asymmetric RSA operations (SIGN, VERIFY, ENCRYPT and DECRYPT) are supported in virtio PMD. Signed-off-by: Gowrishankar Muthukrishnan --- Depends-on: patch-152109 ("vhost: support asymmetric RSA crypto ops") v5: - fixed asym enqueue xmit func for correct head idx. - release not

[v5 0/6] crypto/virtio: enhancements for RSA and vDPA

2025-02-26 Thread Gowrishankar Muthukrishnan
This patch series enhances virtio crypto PMD to: * support RSA * support packed virtio ring * support vDPA backend Depends-on: patch-152109 ("vhost: support asymmetric RSA crypto ops") Gowrishankar Muthukrishnan (6): crypto/virtio: add asymmetric RSA support crypto/virtio: refa

[v5 2/6] crypto/virtio: refactor queue operations

2025-02-26 Thread Gowrishankar Muthukrishnan
Move existing control queue operations into a common place that would be shared with other virtio type of devices. Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/virtio/meson.build | 1 + drivers/crypto/virtio/virtio_crypto_algs.h | 2 +- drivers/crypto/virtio

[v5 5/6] test/crypto: add asymmetric tests for virtio PMD

2025-02-26 Thread Gowrishankar Muthukrishnan
Add asymmetric tests for Virtio PMD. Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev_asym.c | 28 1 file changed, 28 insertions(+) diff --git a/app/test/test_cryptodev_asym.c b/app/test/test_cryptodev_asym.c index 9b5f3c545e..ac47be724f 100644

[v5 6/6] test/crypto: add tests for virtio user PMD

2025-02-26 Thread Gowrishankar Muthukrishnan
Reuse virtio_crypto tests for testing virtio_crypto_user PMD. Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev.c | 7 +++ app/test/test_cryptodev.h | 1 + app/test/test_cryptodev_asym.c | 15 +++ 3 files changed, 23 insertions(+) diff --git a

[v5 4/6] crypto/virtio: add vDPA backend

2025-02-26 Thread Gowrishankar Muthukrishnan
Add vDPA backend to virtio_user crypto. Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/virtio/meson.build | 7 + drivers/crypto/virtio/virtio_cryptodev.c | 57 +- drivers/crypto/virtio/virtio_cryptodev.h | 3 + drivers/crypto/virtio/virtio_logs.h

[v6 5/5] examples/vhost_crypto: support asymmetric crypto

2025-02-26 Thread Gowrishankar Muthukrishnan
Support asymmetric crypto operations. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- doc/guides/sample_app_ug/vhost_crypto.rst | 5 +++ examples/vhost_crypto/main.c | 50 +-- 2 files changed, 43 insertions(+), 12 deletions(-) diff --git a

[v6 4/5] vhost: support asymmetric RSA crypto ops

2025-02-26 Thread Gowrishankar Muthukrishnan
Support asymmetric RSA crypto operations in vhost-user. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- doc/guides/rel_notes/release_25_03.rst | 3 + lib/vhost/vhost_crypto.c | 486 +++-- lib/vhost/virtio_crypto.h | 67

[v6 3/5] examples/vhost_crypto: fix user callbacks

2025-02-26 Thread Gowrishankar Muthukrishnan
In order to handle new vhost user connection, use new_connection and destroy_connection callbacks. Fixes: f5188211c721 ("examples/vhost_crypto: add sample application") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- examples/vhost_crypto/

[v6 2/5] vhost: update vhost_user crypto session parameters

2025-02-26 Thread Gowrishankar Muthukrishnan
. Hence, it would break parsing vhost_user messages. This patch addresses both of the above problems. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- lib/vhost/vhost_crypto.c | 12 ++-- lib/vhost/vhost_user.h | 33 + 2 files changed, 35

[v6 1/5] vhost: skip crypto op fetch before vring init

2025-02-26 Thread Gowrishankar Muthukrishnan
Until virtio avail ring is initialized (by VHOST_USER_SET_VRING_ADDR), worker thread should not try to fetch crypto op, which would lead to memory fault. Fixes: 939066d96563 ("vhost/crypto: add public function implementation") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrish

[v6 0/5] vhost: add RSA support

2025-02-26 Thread Gowrishankar Muthukrishnan
This patch series supports asymmetric RSA in vhost crypto library. It also includes changes to improve vhost crypto library: * support newer QEMU versions. * fix broken vhost_crypto example application. * stabilize crypto fastpath operations. Gowrishankar Muthukrishnan (5): vhost: skip

RE: [EXTERNAL] Re: [v5 1/5] vhost: skip crypto op fetch before vring init

2025-02-26 Thread Gowrishankar Muthukrishnan
> Ack. Except for vq->enabled, next version of this patch would carry these checks. Current virtio crypto for vhost_user does not request SET_VRING_ENABLE, so this flag would not be set. Thanks, Gowrishankar > You can have a look at rte_vhost_dequeue_burst for example. > > > avail_idx = *((volatile uint16_t *)&vq->avail->idx); > > start_idx = vq->last_used_idx; > > count = avail_idx - start_idx;

[v5 5/5] examples/vhost_crypto: support asymmetric crypto

2025-02-24 Thread Gowrishankar Muthukrishnan
Support asymmetric crypto operations. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- v5: - doc update --- doc/guides/sample_app_ug/vhost_crypto.rst | 5 +++ examples/vhost_crypto/main.c | 50 +-- 2 files changed, 43 insertions(+), 12

[v5 4/5] vhost: support asymmetric RSA crypto ops

2025-02-24 Thread Gowrishankar Muthukrishnan
Support asymmetric RSA crypto operations in vhost-user. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- v5: - release notes --- doc/guides/rel_notes/release_25_03.rst | 3 + lib/vhost/vhost_crypto.c | 486 +++-- lib/vhost/virtio_crypto.h

[v5 3/5] examples/vhost_crypto: fix user callbacks

2025-02-24 Thread Gowrishankar Muthukrishnan
In order to handle new vhost user connection, use new_connection and destroy_connection callbacks. Fixes: f5188211c721 ("examples/vhost_crypto: add sample application") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- examples/vhost_crypto/

[v5 2/5] vhost: update vhost_user crypto session parameters

2025-02-24 Thread Gowrishankar Muthukrishnan
. Hence, it would break parsing vhost_user messages. This patch addresses both of the above problems. Signed-off-by: Gowrishankar Muthukrishnan Acked-by: Akhil Goyal --- v5: - updated patch description for QEMU version. --- lib/vhost/vhost_crypto.c | 12 ++-- lib/vhost/vhost_user.h | 33

[v5 1/5] vhost: skip crypto op fetch before vring init

2025-02-24 Thread Gowrishankar Muthukrishnan
Until virtio avail ring is initialized (by VHOST_USER_SET_VRING_ADDR), worker thread should not try to fetch crypto op, which would lead to memory fault. Fixes: 939066d96563 ("vhost/crypto: add public function implementation") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrish

[v5 0/5] vhost: add RSA support

2025-02-24 Thread Gowrishankar Muthukrishnan
This patch series supports asymmetric RSA in vhost crypto library. It also includes changes to improve vhost crypto library: * support newer QEMU versions. * fix broken vhost_crypto example application. * stabilize crypto fastpath operations. v5: - added docs. Gowrishankar Muthukrishnan (5

[v2 2/2] test/crypto: add negative test for RSA verify op

2025-02-22 Thread Gowrishankar Muthukrishnan
Add negative test for RSA verify operation to check if incorrect signature is validated. Signed-off-by: Gowrishankar Muthukrishnan --- v2: - no changes, but added openssl pmd patch for CI. --- app/test/test_cryptodev_asym.c | 27 +-- 1 file changed, 25 insertions(+), 2

[v2 1/2] crypto/openssl: validate incorrect signature in verify op

2025-02-22 Thread Gowrishankar Muthukrishnan
Return correct error status when incorrect signature is used in RSA verify op. Fixes: d7bd42f6db19 ("crypto/openssl: update RSA routine with 3.0 EVP API") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrishnan --- v2: - clubbed with test patch --- drivers/cryp

[v4 2/6] crypto/virtio: refactor queue operations

2025-02-22 Thread Gowrishankar Muthukrishnan
Move existing control queue operations into a common place that would be shared with other virtio type of devices. Signed-off-by: Gowrishankar Muthukrishnan --- Depends-on: series-34682 ("vhost: add RSA support") --- drivers/crypto/virtio/meson.build | 1 + drivers/cry

[v4 4/6] crypto/virtio: add vDPA backend

2025-02-22 Thread Gowrishankar Muthukrishnan
Add vDPA backend to virtio_user crypto. Signed-off-by: Gowrishankar Muthukrishnan --- Depends-on: series-34682 ("vhost: add RSA support") v4: - fixed CI issue. --- drivers/crypto/virtio/meson.build | 7 + drivers/crypto/virtio/virtio_cryptodev.c | 57 +- driv

[v4 5/6] test/crypto: add asymmetric tests for virtio PMD

2025-02-22 Thread Gowrishankar Muthukrishnan
Add asymmetric tests for Virtio PMD. Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev_asym.c | 28 1 file changed, 28 insertions(+) diff --git a/app/test/test_cryptodev_asym.c b/app/test/test_cryptodev_asym.c index 9b5f3c545e..ac47be724f 100644

[v4 5/5] examples/vhost_crypto: support asymmetric crypto

2025-02-22 Thread Gowrishankar Muthukrishnan
Support asymmetric crypto operations. Signed-off-by: Gowrishankar Muthukrishnan --- examples/vhost_crypto/main.c | 50 +++- 1 file changed, 38 insertions(+), 12 deletions(-) diff --git a/examples/vhost_crypto/main.c b/examples/vhost_crypto/main.c index

[v4 6/6] test/crypto: add tests for virtio user PMD

2025-02-22 Thread Gowrishankar Muthukrishnan
Reuse virtio_crypto tests for testing virtio_crypto_user PMD. Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev.c | 7 +++ app/test/test_cryptodev.h | 1 + app/test/test_cryptodev_asym.c | 15 +++ 3 files changed, 23 insertions(+) diff --git a

[v4 2/5] vhost: update vhost_user crypto session parameters

2025-02-22 Thread Gowrishankar Muthukrishnan
parsing vhost_user message. This patch addresses both of the above problems. Signed-off-by: Gowrishankar Muthukrishnan --- lib/vhost/vhost_crypto.c | 12 ++-- lib/vhost/vhost_user.h | 33 + 2 files changed, 35 insertions(+), 10 deletions(-) diff --git a/lib

[v4 3/6] crypto/virtio: add packed ring support

2025-02-22 Thread Gowrishankar Muthukrishnan
Add packed ring support. Signed-off-by: Gowrishankar Muthukrishnan --- Depends-on: series-34682 ("vhost: add RSA support") --- drivers/crypto/virtio/virtio_cryptodev.c | 125 +++ drivers/crypto/virtio/virtio_cryptodev.h | 13 +- drivers/crypto/virtio/virtio_cvq.c

[v4 1/6] crypto/virtio: add asymmetric RSA support

2025-02-22 Thread Gowrishankar Muthukrishnan
Asymmetric RSA operations (SIGN, VERIFY, ENCRYPT and DECRYPT) are supported in virtio PMD. Signed-off-by: Gowrishankar Muthukrishnan --- Depends-on: series-34682 ("vhost: add RSA support") --- .../virtio/virtio_crypto_capabilities.h | 19 + drivers/crypto/virtio/virtio_c

[v4 0/6] crypto/virtio: enhancements for RSA and vDPA

2025-02-22 Thread Gowrishankar Muthukrishnan
This patch series enhances virtio crypto PMD to: * support RSA * support packed virtio ring * support vDPA backend v4: - CI issue fixed. Depends-on: series-34682 ("vhost: add RSA support") Gowrishankar Muthukrishnan (6): crypto/virtio: add asymmetric RSA support crypto/virtio

[v4 4/5] vhost: support asymmetric RSA crypto ops

2025-02-22 Thread Gowrishankar Muthukrishnan
Support asymmetric RSA crypto operations in vhost-user. Signed-off-by: Gowrishankar Muthukrishnan --- v4: - fixed CI issue. --- lib/vhost/vhost_crypto.c | 486 +++--- lib/vhost/virtio_crypto.h | 67 ++ 2 files changed, 518 insertions(+), 35 deletions

[v4 3/5] examples/vhost_crypto: fix user callbacks

2025-02-22 Thread Gowrishankar Muthukrishnan
In order to handle new vhost user connection, use new_connection and destroy_connection callbacks. Fixes: f5188211c721 ("examples/vhost_crypto: add sample application") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrishnan --- examples/vhost_crypto/main.c | 4 ++-- 1 file

[v4 0/5] vhost: add RSA support

2025-02-22 Thread Gowrishankar Muthukrishnan
This patch series supports asymmetric RSA in vhost crypto library. It also includes changes to improve vhost crypto library: * support newer QEMU versions. * fix broken vhost_crypto example application. * stabilize crypto fastpath operations. v4: - fixed CI issues. Gowrishankar Muthukrishnan

[v4 1/5] vhost: skip crypto op fetch before vring init

2025-02-22 Thread Gowrishankar Muthukrishnan
Until virtio avail ring is initialized (by VHOST_USER_SET_VRING_ADDR), worker thread should not try to fetch crypto op, which would lead to memory fault. Fixes: 939066d96563 ("vhost/crypto: add public function implementation") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Mut

[v3 3/6] crypto/virtio: add packed ring support

2025-02-21 Thread Gowrishankar Muthukrishnan
Add packed ring support. Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/virtio/virtio_cryptodev.c | 125 +++ drivers/crypto/virtio/virtio_cryptodev.h | 13 +- drivers/crypto/virtio/virtio_cvq.c | 103 +- drivers/crypto/virtio/virtio_pci.h | 25 ++ drivers

[PATCH v2] crypto/openssl: validate incorrect signature in verify op

2025-02-21 Thread Gowrishankar Muthukrishnan
Return correct error status when incorrect signature is used in RSA verify op. Fixes: d7bd42f6db19 ("crypto/openssl: update RSA routine with 3.0 EVP API") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrishnan --- v2: - added comments. --- drivers/crypto/openssl/rte_openssl_

[v1] app/crypto-perf: add RSA support

2025-02-21 Thread Gowrishankar Muthukrishnan
From: Akhil Goyal Add RSA support in crypto-perf application. Signed-off-by: Akhil Goyal --- app/test-crypto-perf/cperf_ops.c | 68 app/test-crypto-perf/cperf_options.h | 4 + app/test-crypto-perf/cperf_options_parsing.c | 38 +++- app/test-crypto-perf/cperf_te

[v3 2/5] vhost: update vhost_user crypto session parameters

2025-02-21 Thread Gowrishankar Muthukrishnan
parsing vhost_user message. This patch addresses both of the above problems. Signed-off-by: Gowrishankar Muthukrishnan --- v3: - decoupled originally from v2 series single patch. --- lib/vhost/vhost_crypto.c | 12 ++-- lib/vhost/vhost_user.h | 33 + 2

[v3 1/6] crypto/virtio: add asymmetric RSA support

2025-02-21 Thread Gowrishankar Muthukrishnan
Asymmetric RSA operations (SIGN, VERIFY, ENCRYPT and DECRYPT) are supported in virtio PMD. Signed-off-by: Gowrishankar Muthukrishnan --- Depends-on: series-34674 ("vhost: add RSA support") v3: - fast path optimizations. --- .../virtio/virtio_crypto_capabilities.h | 19 + driv

[v3 5/6] test/crypto: add asymmetric tests for virtio PMD

2025-02-21 Thread Gowrishankar Muthukrishnan
Add asymmetric tests for Virtio PMD. Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev_asym.c | 28 1 file changed, 28 insertions(+) diff --git a/app/test/test_cryptodev_asym.c b/app/test/test_cryptodev_asym.c index 9b5f3c545e..ac47be724f 100644

[v3 6/6] test/crypto: add tests for virtio user PMD

2025-02-21 Thread Gowrishankar Muthukrishnan
Reuse virtio_crypto tests for testing virtio_crypto_user PMD. Signed-off-by: Gowrishankar Muthukrishnan --- app/test/test_cryptodev.c | 7 +++ app/test/test_cryptodev.h | 1 + app/test/test_cryptodev_asym.c | 15 +++ 3 files changed, 23 insertions(+) diff --git a

[v3 4/6] crypto/virtio: add vDPA backend

2025-02-21 Thread Gowrishankar Muthukrishnan
Add vDPA backend to virtio_user crypto. Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/virtio/meson.build | 7 + drivers/crypto/virtio/virtio_cryptodev.c | 57 +- drivers/crypto/virtio/virtio_cryptodev.h | 3 + drivers/crypto/virtio/virtio_logs.h

[v3 2/6] crypto/virtio: refactor queue operations

2025-02-21 Thread Gowrishankar Muthukrishnan
Move existing control queue operations into a common place that would be shared with other virtio type of devices. Signed-off-by: Gowrishankar Muthukrishnan --- drivers/crypto/virtio/meson.build | 1 + drivers/crypto/virtio/virtio_crypto_algs.h | 2 +- drivers/crypto/virtio

[v3 0/6] crypto/virtio: enhancements for RSA and vDPA

2025-02-21 Thread Gowrishankar Muthukrishnan
This patch series enhances virtio crypto PMD to: * support RSA * support packed virtio ring * support vDPA backend v3: - vDPA backend code majorly sourced from virtio net. Gowrishankar Muthukrishnan (6): crypto/virtio: add asymmetric RSA support crypto/virtio: refactor queue operations

[v3 3/5] examples/vhost_crypto: fix user callbacks

2025-02-21 Thread Gowrishankar Muthukrishnan
In order to handle new vhost user connection, use new_connection and destroy_connection callbacks. Fixes: f5188211c721 ("examples/vhost_crypto: add sample application") Cc: sta...@dpdk.org Signed-off-by: Gowrishankar Muthukrishnan --- v3: - decoupled from v2 single patch. ---

[v3 5/5] examples/vhost_crypto: support asymmetric crypto

2025-02-21 Thread Gowrishankar Muthukrishnan
Support asymmetric crypto operations. Signed-off-by: Gowrishankar Muthukrishnan --- examples/vhost_crypto/main.c | 50 +++- 1 file changed, 38 insertions(+), 12 deletions(-) diff --git a/examples/vhost_crypto/main.c b/examples/vhost_crypto/main.c index

  1   2   3   4   5   6   7   8   9   >