Skip to contentSkip to conversation

netfilter: conntrack: proc: rename stat column

PATCH Applied Florian Westphal 2 participants 2 messages Sep 9, 2020 – Sep 21, 2020

Subsystems (2)
lore
Share & tools
lore

Florian Westphal

author maintainer
#0 lore raw

PATCH 1/1 netfilter: conntrack: proc: rename stat column

Rename 'searched' column to 'clashres' (same len).

conntrack(8) using the old /proc interface (ctnetlink not available) shows:

cpu=0 entries=4784 clashres=2292 [..]

Another alternative is to add another column, but this increases the number of always-0 columns.

Fixes bc92470413f3af1 ("netfilter: conntrack: add clash resolution stat counter")
---
 net/netfilter/nf_conntrack_standalone.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
net/netfilter/nf_conntrack_standalone.c +2 -2
index 0ff39740797d..46c5557c1fec 100644
@@ -428,14 +428,14 @@ static int ct_cpu_seq_show(struct seq_file *seq, void *v)
 	const struct ip_conntrack_stat *st = v;
 
 	if (v == SEQ_START_TOKEN) {
-		seq_puts(seq, "entries  searched found new invalid ignore delete delete_list insert insert_failed drop early_drop icmp_error  expect_new expect_create expect_delete search_restart\n");
+		seq_puts(seq, "entries  clashres found new invalid ignore delete delete_list insert insert_failed drop early_drop icmp_error  expect_new expect_create expect_delete search_restart\n");
 		return 0;
 	}
 
 	seq_printf(seq, "%08x  %08x %08x %08x %08x %08x %08x %08x "
 			"%08x %08x %08x %08x %08x  %08x %08x %08x %08x\n",
 		   nr_conntracks,
-		   st->clash_resolve, /* was: searched */
+		   st->clash_resolve,
 		   st->found,
 		   0,
 		   st->invalid,
Signature · 1 line
2.26.2
maintainer Applied
#1 lore raw
Quoted 8 lines · Florian Westphal

Rename 'searched' column to 'clashres' (same len).

conntrack(8) using the old /proc interface (ctnetlink not available) shows:

cpu=0 entries=4784 clashres=2292 [..]

Another alternative is to add another column, but this increases the number of always-0 columns.

Applied, thanks.