diff --git a/linuxkm/module_hooks.c b/linuxkm/module_hooks.c index 17a386f83..634e0b65b 100644 --- a/linuxkm/module_hooks.c +++ b/linuxkm/module_hooks.c @@ -241,7 +241,14 @@ static int wolfssl_init(void) #endif #ifndef NO_CRYPT_TEST - ret = wolfcrypt_test(NULL); + +#ifdef WC_RNG_SEED_CB + ret = wc_SetSeed_Cb(wc_GenerateSeed); + if (ret == 0) +#endif + { + ret = wolfcrypt_test(NULL); + } if (ret < 0) { pr_err("wolfcrypt self-test failed with return code %d.\n", ret); (void)libwolfssl_cleanup();