aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@osdl.org>2005-09-21 03:15:39 -0400
committerDavid S. Miller <davem@davemloft.net>2005-09-21 03:15:39 -0400
commit78c6671a88313fd3c4364dc46e8c8186612616b8 (patch)
tree55ad469a2f178eb7a0172daf06798a356aa314f9
parent0fb375fb9b93b7d822debc6a734052337ccfdb1f (diff)
[FIB_TRIE]: message cleanup
Cleanup the printk's in fib_trie: * Convert a couple of places in the dump code to BUG_ON * Put log level's on each message The version message really needed the message since it leaks out on the pretty Fedora bootup. Signed-off-by: Stephen Hemminger <shemminger@osdl.org> Acked-by: Robert Olsson <Robert.Olsson@data.slu.se>, Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--net/ipv4/fib_trie.c15
1 files changed, 3 insertions, 12 deletions
diff --git a/net/ipv4/fib_trie.c b/net/ipv4/fib_trie.c
index 90ae70870a10..50c0519cd70d 100644
--- a/net/ipv4/fib_trie.c
+++ b/net/ipv4/fib_trie.c
@@ -1086,7 +1086,7 @@ fib_insert_node(struct trie *t, int *err, u32 key, int plen)
1086 } 1086 }
1087 1087
1088 if (tp && tp->pos + tp->bits > 32) 1088 if (tp && tp->pos + tp->bits > 32)
1089 printk("ERROR tp=%p pos=%d, bits=%d, key=%0x plen=%d\n", 1089 printk(KERN_WARNING "fib_trie tp=%p pos=%d, bits=%d, key=%0x plen=%d\n",
1090 tp, tp->pos, tp->bits, key, plen); 1090 tp, tp->pos, tp->bits, key, plen);
1091 1091
1092 /* Rebalance the trie */ 1092 /* Rebalance the trie */
@@ -1832,16 +1832,7 @@ static int fn_trie_dump_fa(t_key key, int plen, struct list_head *fah, struct fi
1832 i++; 1832 i++;
1833 continue; 1833 continue;
1834 } 1834 }
1835 if (fa->fa_info->fib_nh == NULL) { 1835 BUG_ON(!fa->fa_info);
1836 printk("Trie error _fib_nh=NULL in fa[%d] k=%08x plen=%d\n", i, key, plen);
1837 i++;
1838 continue;
1839 }
1840 if (fa->fa_info == NULL) {
1841 printk("Trie error fa_info=NULL in fa[%d] k=%08x plen=%d\n", i, key, plen);
1842 i++;
1843 continue;
1844 }
1845 1836
1846 if (fib_dump_info(skb, NETLINK_CB(cb->skb).pid, 1837 if (fib_dump_info(skb, NETLINK_CB(cb->skb).pid,
1847 cb->nlh->nlmsg_seq, 1838 cb->nlh->nlmsg_seq,
@@ -1964,7 +1955,7 @@ struct fib_table * __init fib_hash_init(int id)
1964 trie_main = t; 1955 trie_main = t;
1965 1956
1966 if (id == RT_TABLE_LOCAL) 1957 if (id == RT_TABLE_LOCAL)
1967 printk("IPv4 FIB: Using LC-trie version %s\n", VERSION); 1958 printk(KERN_INFO "IPv4 FIB: Using LC-trie version %s\n", VERSION);
1968 1959
1969 return tb; 1960 return tb;
1970} 1961}