1 // SPDX-License-Identifier: GPL-2.0+
3 * Copyright (C) 2021 Felix Fietkau <nbd@nbd.name>
9 #include <libubox/uloop.h>
13 static int usage(const char *progname
)
15 fprintf(stderr
, "Usage: %s [options]\n"
17 " -l <file> Load defaults from <file>\n"
18 " -o only load program/maps without running as daemon\n"
24 int main(int argc
, char **argv
)
26 const char *load_file
= NULL
;
30 while ((ch
= getopt(argc
, argv
, "fl:o")) != -1) {
41 return usage(argv
[0]);
45 if (qosify_loader_init())
48 if (qosify_map_init())
51 if (qosify_map_load_file(load_file
))
57 ulog_open(ULOG_SYSLOG
, LOG_DAEMON
, "qosify");
60 if (qosify_ubus_init() ||