https://bugs.dpdk.org/show_bug.cgi?id=377
Bug ID: 377 Summary: CRYPTODEV: set_sym_session_private_data() line 489: Set private data for driver 0 not allowed Product: DPDK Version: unspecified Hardware: x86 OS: All Status: UNCONFIRMED Severity: normal Priority: Normal Component: cryptodev Assignee: dev@dpdk.org Reporter: sunnyla...@gmail.com Target Milestone: --- Environment: Xeon E5-2640, Ubuntu 16.04, DPDK 19.11, Intel AESNI-MB library 0.53.0 When OpenSSL or AESNI-MB cryptodev is being used in sessionless mode for symmetric crypto operation (e.g. SHA256 hash), the driver prints error message: CRYPTODEV: set_sym_session_private_data() line 489: Set private data for driver 0 not allowed This error is caused by: 1. set_sym_session_private_data() checks sess->nb_drivers > driver_id, or it will print the above error. 2. In session-based mode, rte_cryptodev_sym_session_create() allocates a session structure from the session pool, then sets sess->nb_drivers = pool_priv->nb_drivers, so that there wouldn't be an error. 3. In sessionless mode, get_session() in rte_openssl_pmd.c or rte_aesni_mb_pmd.c allocates a session structure from the session pool, but does not set sess->nb_drivers, causing the error. Due to this error, AESNI-MB driver segfaults in post_process_mb_job() after get_sym_session_private_data() returns NULL. OpenSSL driver can still compute SHA256 digest successfully, apart from the error message, because it does not actually use get_sym_session_private_data(). -- You are receiving this mail because: You are the assignee for the bug.