aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/src/main.c b/src/main.c
index 0697741..9ed60d0 100644
--- a/src/main.c
+++ b/src/main.c
@@ -27,11 +27,9 @@ static int __init mod_init(void)
#endif
noise_init();
-#ifdef CONFIG_WIREGUARD_PARALLEL
- ret = packet_init_data_caches();
+ ret = init_crypt_cache();
if (ret < 0)
goto err_packet;
-#endif
ret = device_init();
if (ret < 0)
@@ -43,19 +41,15 @@ static int __init mod_init(void)
return 0;
err_device:
-#ifdef CONFIG_WIREGUARD_PARALLEL
- packet_deinit_data_caches();
+ deinit_crypt_cache();
err_packet:
-#endif
return ret;
}
static void __exit mod_exit(void)
{
device_uninit();
-#ifdef CONFIG_WIREGUARD_PARALLEL
- packet_deinit_data_caches();
-#endif
+ deinit_crypt_cache();
pr_debug("WireGuard unloaded\n");
}