aboutsummaryrefslogtreecommitdiffstats
path: root/include/subsys.h
diff options
context:
space:
mode:
authorturret <turret@duck.com>2023-11-19 18:57:55 -0600
committerturret <turret@duck.com>2023-11-19 18:57:55 -0600
commita8b2282eb88f24c3c5f461e1557fa2cf76ebc251 (patch)
tree67544659f7df20e0286cb82e17aa47520a601f14 /include/subsys.h
downloaddiscord-bot-skeleton-a8b2282eb88f24c3c5f461e1557fa2cf76ebc251.tar.gz
discord-bot-skeleton-a8b2282eb88f24c3c5f461e1557fa2cf76ebc251.tar.bz2
discord-bot-skeleton-a8b2282eb88f24c3c5f461e1557fa2cf76ebc251.zip
Initial commit
- create subsystem system using clone syscall, shared memory, shared file descriptors - printk-like logging facility (TODO: console loglevel) - initcall system (like linux kernel) TODO: determine license factors: linker.ld, linux kernel licensing (some ideas are more liberally taken rather than paraphrased)
Diffstat (limited to 'include/subsys.h')
-rw-r--r--include/subsys.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/subsys.h b/include/subsys.h
new file mode 100644
index 0000000..1515293
--- /dev/null
+++ b/include/subsys.h
@@ -0,0 +1,7 @@
+#ifndef __SUBSYS_H
+#define __SUBSYS_H
+
+int __impl_start_subsystem(char *name, int (*fn)(void));
+#define start_subsystem(fn) __impl_start_subsystem(#fn, fn)
+
+#endif