2 * Copyright (C) 2013 Felix Fietkau <nbd@openwrt.org>
3 * Copyright (C) 2013 John Crispin <blogic@openwrt.org>
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU Lesser General Public License version 2.1
7 * as published by the Free Software Foundation
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
18 #include <libubox/uloop.h>
19 #include <libubox/utils.h>
27 #define __init __attribute__((constructor))
29 extern char *ubus_socket
;
31 void procd_connect_ubus(void);
32 void procd_reconnect_ubus(int reconnect
);
33 void ubus_init_service(struct ubus_context
*ctx
);
34 void ubus_init_system(struct ubus_context
*ctx
);
36 void procd_state_next(void);
37 void procd_state_ubus_connect(void);
38 void procd_shutdown(int event
);
39 void procd_early(void);
40 void procd_preinit(void);
41 void procd_signal(void);
42 void procd_signal_preinit(void);
43 void procd_inittab(void);
44 void procd_inittab_run(const char *action
);
45 void procd_bcast_event(char *event
, struct blob_attr
*msg
);
48 void trigger_event(const char *type
, struct blob_attr
*data
);
49 void trigger_add(struct blob_attr
*rule
, void *id
);
50 void trigger_del(void *id
);
52 void watch_add(const char *_name
, void *id
);
53 void watch_del(void *id
);
54 void watch_ubus(struct ubus_context
*ctx
);