All of lore.kernel.org
 help / color / mirror / Atom feed
* [Bug 953] Virtio Crypto Test failed
@ 2022-03-07 17:02 bugzilla
  2022-03-08 15:38 ` bugzilla
  0 siblings, 1 reply; 2+ messages in thread
From: bugzilla @ 2022-03-07 17:02 UTC (permalink / raw)
  To: dev

https://bugs.dpdk.org/show_bug.cgi?id=953

            Bug ID: 953
           Summary: Virtio Crypto Test failed
           Product: DPDK
           Version: unspecified
          Hardware: All
                OS: All
            Status: UNCONFIRMED
          Severity: normal
          Priority: Normal
         Component: vhost/virtio
          Assignee: dev@dpdk.org
          Reporter: roy.fan.zhang@intel.com
  Target Milestone: ---

DPDK Virtio Crypto Test always fail.

RTE>>cryptodev_virtio_autotest
 + ------------------------------------------------------- +
 + Test Suite : Crypto VIRTIO Unit Test Suite
CRYPTODEV: elt_size 0 is expanded to 272

 + ------------------------------------------------------- +
SESSION: virtio_crypto_send_command(): Something wrong on backend! status=1,
session_id=0
SESSION: virtio_crypto_sym_configure_session(): create session failed: -1
CRYPTODEV: rte_cryptodev_sym_session_init() line 1744: dev_id 0 failed to
configure session details
  0) TestCase AES-128-CBC Encryption line 458 FAILED: Session creation failed
SESSION: virtio_crypto_send_command(): Something wrong on backend! status=1,
session_id=0
SESSION: virtio_crypto_sym_configure_session(): create session failed: -1
CRYPTODEV: rte_cryptodev_sym_session_init() line 1744: dev_id 0 failed to
configure session details
  1) TestCase AES-128-CBC Decryption line 458 FAILED: Session creation failed
SESSION: virtio_crypto_send_command(): Something wrong on backend! status=1,
session_id=0
SESSION: virtio_crypto_sym_configure_session(): create session failed: -1
CRYPTODEV: rte_cryptodev_sym_session_init() line 1744: dev_id 0 failed to
configure session details
  2) TestCase AES-192-CBC Encryption line 458 FAILED: Session creation failed
Device doesn't support out-of-place scatter-gather in input mbuf. Test Skipped.
  3) TestCase AES-192-CBC Encryption Scater gather SKIPPED
SESSION: virtio_crypto_send_command(): Something wrong on backend! status=1,
session_id=0
SESSION: virtio_crypto_sym_configure_session(): create session failed: -1
CRYPTODEV: rte_cryptodev_sym_session_init() line 1744: dev_id 0 failed to
configure session details
  4) TestCase AES-192-CBC Decryption line 458 FAILED: Session creation failed
Device doesn't support in-place scatter-gather mbufs. Test Skipped.
  5) TestCase AES-192-CBC Decryption Scatter Gather SKIPPED
SESSION: virtio_crypto_sym_configure_session(): Couldn't get object from
session mempool
CRYPTODEV: rte_cryptodev_sym_session_init() line 1744: dev_id 0 failed to
configure session details
  6) TestCase AES-256-CBC Encryption line 458 FAILED: Session creation failed
SESSION: virtio_crypto_sym_configure_session(): Couldn't get object from
session mempool
CRYPTODEV: rte_cryptodev_sym_session_init() line 1744: dev_id 0 failed to
configure session details
  7) TestCase AES-256-CBC Decryption line 458 FAILED: Session creation failed
SESSION: virtio_crypto_sym_configure_session(): Couldn't get object from
session mempool
CRYPTODEV: rte_cryptodev_sym_session_init() line 1744: dev_id 0 failed to
configure session details
  8) TestCase AES-256-CBC OOP Encryption line 458 FAILED: Session creation
failed
SESSION: virtio_crypto_sym_configure_session(): Couldn't get object from
session mempool
CRYPTODEV: rte_cryptodev_sym_session_init() line 1744: dev_id 0 failed to
configure session details
  9) TestCase AES-256-CBC OOP Decryption line 458 FAILED: Session creation
failed

The initial research to the problem is caused by recent change made to vhost
library

Debug info in lib/vhost/vhost_crypto.c:

470             switch (ctx->msg.request.master) {
471             case VHOST_USER_CRYPTO_CREATE_SESS:
472                     vhost_crypto_create_sess(vcrypto,
473                                     &ctx->msg.payload.crypto_session);
474                     ctx->fd_num = 0;
475                     ret = RTE_VHOST_MSG_RESULT_REPLY;
476                     break;
477             case VHOST_USER_CRYPTO_CLOSE_SESS:
478                     if (vhost_crypto_close_sess(vcrypto,
ctx->msg.payload.u64))
479                             ret = RTE_VHOST_MSG_RESULT_ERR;
(gdb) p ctx->msg.request.master
$12 = 0
(gdb) p ctx->msg.request
$13 = {master = 0, slave = 0}
(gdb) l
480                     break;
481             default:
482                     ret = RTE_VHOST_MSG_RESULT_NOT_HANDLED;
483                     break;
484             }
485
486             return ret;

The code expect the request.master to be 26, but got 0 in the end.
This cause the switch fallen into default case and return not handled.
Looks like this problem is caused by this commit

commit 5e0099dc709e4abce167907e14335d8381f1944e
Author: Christophe Fontaine <cfontain@redhat.com>
Date:   Mon Feb 7 11:21:29 2022 +0100

    vhost: remove payload size limitation

    FDs at the end of the VhostUserMessage structure limits the size
    of the payload. Move them to an other englobing structure, before
    the header & payload of a VhostUserMessage.
    Also removes a reference to fds in the VHUMsg structure defined in
    drivers/net/virtio/virtio_user/vhost_user.c

    Signed-off-by: Christophe Fontaine <cfontain@redhat.com>
    Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
    Reviewed-by: David Marchand <david.marchand@redhat.com>

-- 
You are receiving this mail because:
You are the assignee for the bug.

^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Bug 953] Virtio Crypto Test failed
  2022-03-07 17:02 [Bug 953] Virtio Crypto Test failed bugzilla
@ 2022-03-08 15:38 ` bugzilla
  0 siblings, 0 replies; 2+ messages in thread
From: bugzilla @ 2022-03-08 15:38 UTC (permalink / raw)
  To: dev

https://bugs.dpdk.org/show_bug.cgi?id=953

Fan Zhang (roy.fan.zhang@intel.com) changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|---                         |FIXED

--- Comment #5 from Fan Zhang (roy.fan.zhang@intel.com) ---
Resolved by
https://patchwork.dpdk.org/project/dpdk/patch/20220308094422.25685-1-david.marchand@redhat.com/

-- 
You are receiving this mail because:
You are the assignee for the bug.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-03-08 15:38 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-07 17:02 [Bug 953] Virtio Crypto Test failed bugzilla
2022-03-08 15:38 ` bugzilla

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.