aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/dev/wg/if_wg.c6
-rw-r--r--sys/dev/wg/wg_cookie.c5
2 files changed, 5 insertions, 6 deletions
diff --git a/sys/dev/wg/if_wg.c b/sys/dev/wg/if_wg.c
index 57caa69bde3b..d0b75d5cbf4b 100644
--- a/sys/dev/wg/if_wg.c
+++ b/sys/dev/wg/if_wg.c
@@ -3135,9 +3135,9 @@ wg_module_init(void)
[PR_METHOD_REMOVE] = wg_prison_remove,
};
- if ((wg_packet_zone = uma_zcreate("wg packet", sizeof(struct wg_packet),
- NULL, NULL, NULL, NULL, 0, 0)) == NULL)
- return (ENOMEM);
+ wg_packet_zone = uma_zcreate("wg packet", sizeof(struct wg_packet),
+ NULL, NULL, NULL, NULL, 0, 0);
+
ret = crypto_init();
if (ret != 0)
return (ret);
diff --git a/sys/dev/wg/wg_cookie.c b/sys/dev/wg/wg_cookie.c
index 6ff9325c6613..80617d473471 100644
--- a/sys/dev/wg/wg_cookie.c
+++ b/sys/dev/wg/wg_cookie.c
@@ -85,9 +85,8 @@ static uma_zone_t ratelimit_zone;
int
cookie_init(void)
{
- if ((ratelimit_zone = uma_zcreate("wg ratelimit",
- sizeof(struct ratelimit_entry), NULL, NULL, NULL, NULL, 0, 0)) == NULL)
- return ENOMEM;
+ ratelimit_zone = uma_zcreate("wg ratelimit",
+ sizeof(struct ratelimit_entry), NULL, NULL, NULL, NULL, 0, 0);
ratelimit_init(&ratelimit_v4);
#ifdef INET6