summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--netsniff-ng.c3
-rw-r--r--pcap_io.h6
2 files changed, 6 insertions, 3 deletions
diff --git a/netsniff-ng.c b/netsniff-ng.c
index 42a56b5..8a4f7e6 100644
--- a/netsniff-ng.c
+++ b/netsniff-ng.c
@@ -1421,6 +1421,9 @@ int main(int argc, char **argv)
if (!ctx.enforce)
xlockme();
+ if (ctx.verbose)
+ printf("pcap file I/O method: %s\n", pcap_ops_group_to_str[ctx.pcap]);
+
main_loop(&ctx);
if (!ctx.enforce)
diff --git a/pcap_io.h b/pcap_io.h
index 5d338bb..1fe3b48 100644
--- a/pcap_io.h
+++ b/pcap_io.h
@@ -605,9 +605,9 @@ static inline void pcap_dump_type_features(void)
}
static const char *pcap_ops_group_to_str[] __maybe_unused = {
- [PCAP_OPS_RW] = "rw",
- [PCAP_OPS_SG] = "sg",
- [PCAP_OPS_MM] = "mm",
+ [PCAP_OPS_RW] = "read/write",
+ [PCAP_OPS_SG] = "scatter-gather",
+ [PCAP_OPS_MM] = "mmap",
};
static const struct pcap_file_ops *pcap_ops[] __maybe_unused = {
eter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: stable@vger.kernel.org # v4.5+ Cc: syzkaller <syzkaller@googlegroups.com> Fixes: 63b6da39bb38 ("perf: Fix perf_event_exit_task() race") Link: http://lkml.kernel.org/r/20170126153955.GD6515@twins.programming.kicks-ass.net Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'include/net/pkt_sched.h')