mirror of
https://github.com/troglobit/finit.git
synced 2026-10-24 11:54:36 +00:00
initctl: Add dependency on bootmisc
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
1 parent
b3fb9ab3ed
commit
74eb2bf4d2
1 file changed
+10
-2
+10
-2
@@ -46,8 +46,8 @@
|
|||||||
*/
|
*/
|
||||||
shutop_t halt = SHUT_DEFAULT;
|
shutop_t halt = SHUT_DEFAULT;
|
||||||
|
|
||||||
|
|
||||||
static void parse(void *arg, int fd, int events);
|
static void parse(void *arg, int fd, int events);
|
||||||
|
static void setup(void *arg);
|
||||||
|
|
||||||
static plugin_t plugin = {
|
static plugin_t plugin = {
|
||||||
.name = __FILE__,
|
.name = __FILE__,
|
||||||
@@ -55,6 +55,9 @@ static plugin_t plugin = {
|
|||||||
.cb = parse,
|
.cb = parse,
|
||||||
.flags = PLUGIN_IO_READ,
|
.flags = PLUGIN_IO_READ,
|
||||||
},
|
},
|
||||||
|
.hook[HOOK_BASEFS_UP] = {
|
||||||
|
.cb = setup
|
||||||
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
static void fifo_open(void)
|
static void fifo_open(void)
|
||||||
@@ -173,12 +176,17 @@ static void parse(void *UNUSED(arg), int fd, int UNUSED(events))
|
|||||||
fifo_open();
|
fifo_open();
|
||||||
}
|
}
|
||||||
|
|
||||||
PLUGIN_INIT(plugin_init)
|
/* Must run after the base FS is up, needs /run, or /var/run */
|
||||||
|
static void setup(void *UNUSED(arg))
|
||||||
{
|
{
|
||||||
_d("Setting up %s", FINIT_FIFO);
|
_d("Setting up %s", FINIT_FIFO);
|
||||||
makefifo(FINIT_FIFO, 0600);
|
makefifo(FINIT_FIFO, 0600);
|
||||||
|
|
||||||
fifo_open();
|
fifo_open();
|
||||||
|
}
|
||||||
|
|
||||||
|
PLUGIN_INIT(plugin_init)
|
||||||
|
{
|
||||||
plugin_register(&plugin);
|
plugin_register(&plugin);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user