MCPcopy Create free account
hub / github.com/F-Stack/f-stack / null_testsuite_setup

Function null_testsuite_setup

dpdk/app/test/test_cryptodev.c:759–789  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

757}
758
759static int
760null_testsuite_setup(void)
761{
762 struct crypto_testsuite_params *ts_params = &testsuite_params;
763 uint8_t dev_id = ts_params->valid_devs[0];
764 struct rte_cryptodev_info dev_info;
765 const enum rte_crypto_cipher_algorithm ciphers[] = {
766 RTE_CRYPTO_CIPHER_NULL
767 };
768 const enum rte_crypto_auth_algorithm auths[] = {
769 RTE_CRYPTO_AUTH_NULL
770 };
771
772 rte_cryptodev_info_get(dev_id, &dev_info);
773
774 if (!(dev_info.feature_flags & RTE_CRYPTODEV_FF_SYMMETRIC_CRYPTO)) {
775 RTE_LOG(INFO, USER1, "Feature flag requirements for NULL "
776 "testsuite not met\n");
777 return TEST_SKIPPED;
778 }
779
780 if (check_cipher_capabilities_supported(ciphers, RTE_DIM(ciphers)) != 0
781 && check_auth_capabilities_supported(auths,
782 RTE_DIM(auths)) != 0) {
783 RTE_LOG(INFO, USER1, "Capability requirements for NULL "
784 "testsuite not met\n");
785 return TEST_SKIPPED;
786 }
787
788 return 0;
789}
790
791static int
792crypto_gen_testsuite_setup(void)

Callers

nothing calls this directly

Tested by

no test coverage detected