| To: | Andrew Morton <akpm@xxxxxxxx> |
|---|---|
| Subject: | [TRIVIAL] Fix recent bug in fib_semantics.c |
| From: | David Gibson <david@xxxxxxxxxxxxxxxxxxxxx> |
| Date: | Fri, 17 Sep 2004 16:20:42 +1000 |
| Cc: | David Miller <davem@xxxxxxxxxx>, trivial@xxxxxxxxxxxxxxx, linux-kernel@xxxxxxxxxxxxxxx, netdev@xxxxxxxxxxx |
| Mail-followup-to: | David Gibson <david@xxxxxxxxxxxxxxxxxxxxx>, Andrew Morton <akpm@xxxxxxxx>, David Miller <davem@xxxxxxxxxx>, trivial@xxxxxxxxxxxxxxx, linux-kernel@xxxxxxxxxxxxxxx, netdev@xxxxxxxxxxx |
| Sender: | netdev-bounce@xxxxxxxxxxx |
| User-agent: | Mutt/1.5.6+20040818i |
Andrew, please apply:
When fib_create_info() allocates new hash tables, it neglects to
initialize them. This leads to an oops during boot on at least
machine I use. This patch addresses the problem.
Signed-off-by: David Gibson <dwg@xxxxxxxxxxx>
Index: working-2.6/net/ipv4/fib_semantics.c
===================================================================
--- working-2.6.orig/net/ipv4/fib_semantics.c 2004-09-17 09:20:04.000000000
+1000
+++ working-2.6/net/ipv4/fib_semantics.c 2004-09-17 16:24:42.634638304
+1000
@@ -604,8 +604,12 @@
if (!new_info_hash || !new_laddrhash) {
fib_hash_free(new_info_hash, bytes);
fib_hash_free(new_laddrhash, bytes);
- } else
+ } else {
+ memset(new_info_hash, 0, bytes);
+ memset(new_laddrhash, 0, bytes);
+
fib_hash_move(new_info_hash, new_laddrhash, new_size);
+ }
if (!fib_hash_size)
goto failure;
--
David Gibson | For every complex problem there is a
david AT gibson.dropbear.id.au | solution which is simple, neat and
| wrong.
http://www.ozlabs.org/people/dgibson
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: Patch submission for S2io Xframe driver to 2.6 kernel, Randy.Dunlap |
|---|---|
| Next by Date: | Re: [TRIVIAL] Fix recent bug in fib_semantics.c, Jeff Garzik |
| Previous by Thread: | CBQ quits when HZ=1000, Tim Gardner |
| Next by Thread: | Re: [TRIVIAL] Fix recent bug in fib_semantics.c, Jeff Garzik |
| Indexes: | [Date] [Thread] [Top] [All Lists] |