]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blobdiff - tools/perf/util/parse-options.h
perf annotate: Add the cmp_null function and make use of it
[mirror_ubuntu-bionic-kernel.git] / tools / perf / util / parse-options.h
index 8aa3464c709054ba8b6275f39d3bead3873f5936..2ee248ff27e5c5af9fe315c198308e9a2b9fa584 100644 (file)
@@ -104,6 +104,8 @@ struct option {
        { .type = OPTION_CALLBACK, .short_name = (s), .long_name = (l), .value = (v), .argh = "time", .help = (h), .callback = parse_opt_approxidate_cb }
 #define OPT_CALLBACK(s, l, v, a, h, f) \
        { .type = OPTION_CALLBACK, .short_name = (s), .long_name = (l), .value = (v), (a), .help = (h), .callback = (f) }
+#define OPT_CALLBACK_NOOPT(s, l, v, a, h, f) \
+       { .type = OPTION_CALLBACK, .short_name = (s), .long_name = (l), .value = (v), (a), .help = (h), .callback = (f), .flags = PARSE_OPT_NOARG }
 #define OPT_CALLBACK_DEFAULT(s, l, v, a, h, f, d) \
        { .type = OPTION_CALLBACK, .short_name = (s), .long_name = (l), .value = (v), (a), .help = (h), .callback = (f), .defval = (intptr_t)d, .flags = PARSE_OPT_LASTARG_DEFAULT }