summaryrefslogtreecommitdiffhomepage
path: root/src/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.c')
-rw-r--r--src/main.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index 67ce6a6..d1e8a00 100644
--- a/src/main.c
+++ b/src/main.c
@@ -43,6 +43,12 @@ static void __exit mod_exit(void)
pr_debug("WireGuard has been unloaded\n");
}
+/* We want our selftest debug messages loaded after serial drivers. */
+#if !defined(MODULE) && defined(DEBUG)
+#undef module_init
+#define module_init(a) late_initcall(a)
+#endif
+
module_init(mod_init);
module_exit(mod_exit);
MODULE_LICENSE("GPL v2");