aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/fib_trie.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2007-01-26 22:39:40 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-01-26 22:39:40 -0500
commit7d620a4e531ae4d432d3c88f7d4b75327d881a87 (patch)
treefe4b226f695394383e546683755ebda9f37ac7b2 /net/ipv4/fib_trie.c
parent86d43258bcad2068744c85181b97bb35ab27a74d (diff)
parent095b8501e4168ae5a879fcb9420ac48cbd43f95a (diff)
Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6: [IPV4]: Fix single-entry /proc/net/fib_trie output. [SELINUX]: Fix 2.6.20-rc6 build when no xfrm
Diffstat (limited to 'net/ipv4/fib_trie.c')
-rw-r--r--net/ipv4/fib_trie.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/net/ipv4/fib_trie.c b/net/ipv4/fib_trie.c
index 13307c04d5a1..1e589b91605e 100644
--- a/net/ipv4/fib_trie.c
+++ b/net/ipv4/fib_trie.c
@@ -2290,16 +2290,17 @@ static int fib_trie_seq_show(struct seq_file *seq, void *v)
2290 if (v == SEQ_START_TOKEN) 2290 if (v == SEQ_START_TOKEN)
2291 return 0; 2291 return 0;
2292 2292
2293 if (!NODE_PARENT(n)) {
2294 if (iter->trie == trie_local)
2295 seq_puts(seq, "<local>:\n");
2296 else
2297 seq_puts(seq, "<main>:\n");
2298 }
2299
2293 if (IS_TNODE(n)) { 2300 if (IS_TNODE(n)) {
2294 struct tnode *tn = (struct tnode *) n; 2301 struct tnode *tn = (struct tnode *) n;
2295 __be32 prf = htonl(MASK_PFX(tn->key, tn->pos)); 2302 __be32 prf = htonl(MASK_PFX(tn->key, tn->pos));
2296 2303
2297 if (!NODE_PARENT(n)) {
2298 if (iter->trie == trie_local)
2299 seq_puts(seq, "<local>:\n");
2300 else
2301 seq_puts(seq, "<main>:\n");
2302 }
2303 seq_indent(seq, iter->depth-1); 2304 seq_indent(seq, iter->depth-1);
2304 seq_printf(seq, " +-- %d.%d.%d.%d/%d %d %d %d\n", 2305 seq_printf(seq, " +-- %d.%d.%d.%d/%d %d %d %d\n",
2305 NIPQUAD(prf), tn->pos, tn->bits, tn->full_children, 2306 NIPQUAD(prf), tn->pos, tn->bits, tn->full_children,