#include <inttypes.h>
#include <ncurses.h>
+#ifdef WITH_FWP
+#include <ul_logreg.h>
+#endif
+
#ifdef WITH_FWP
#include <frsh.h>
#include <fwp_res.h>
fflush(stderr);
}
+#ifdef WITH_FWP
+int print_log_domain(ul_log_domain_t *domain, void *context)
+{
+ printf("%s = %d\n", domain->name, domain->level);
+ return 0;
+}
+#endif
int main(int argc, char *argv[])
{
int i, rc, frames, seconds;
char opt;
- while ((opt = getopt(argc, argv, "B:b:C:c:Gg:I:j:o:qQ:s:T:")) != -1) {
+ while ((opt = getopt(argc, argv, "B:b:C:c:Gg:I:j:l:o:qQ:s:T:")) != -1) {
switch (opt) {
case 'B':
opt_def_bandwidth = atoi(optarg);
opt_jitter = atoi(optarg);
#endif
break;
+#ifdef WITH_FWP
+ case 'l':
+ if (*optarg == '?') {
+ ul_logreg_for_each_domain(print_log_domain, NULL);
+ exit(0);
+ }
+ {
+ int ret;
+ ret = ul_log_domain_arg2levels(optarg);
+ if (ret)
+ error(1, EINVAL, "Error parsing -l argument at char %d\n", ret);
+ }
+ break;
+#endif
case 'o':
opt_output = optarg;
break;
fprintf(stderr, " -c count (number of seconds to run)\n");
fprintf(stderr, " -g histogram granularity [usec]\n");
fprintf(stderr, " -I <interface> send packets from this interface\n");
+#ifdef WITH_FWP
+ fprintf(stderr, " -l <loglevel> uLUt logging levels\n");
+#endif
fprintf(stderr, " -j send jitter (0-100) [%%]\n");
fprintf(stderr, " -o output filename (.dat will be appended)\n");
fprintf(stderr, " -q gather statistics only after some queue becomes full\n");