[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20070507.160911.35663865.davem@davemloft.net>
Date: Mon, 07 May 2007 16:09:11 -0700 (PDT)
From: David Miller <davem@...emloft.net>
To: bcrl@...ck.org
Cc: netdev@...r.kernel.org
Subject: Re: [PATCH] fib_info_hashfn leads to long hash chains
From: Benjamin LaHaise <bcrl@...ck.org>
Date: Sun, 29 Apr 2007 11:03:36 -0400
> Hello
>
> The patch below fixes a case where fib_find_info() is consume excessive
> amounts of CPU during the creation of 10000 PPP interfaces. In access
> servers, each point to point link has the same local address, but a different
> destination and interface. Because the device is not included in the hash
> calculation, the chain grows excessively large and we end up spinning the
> CPU walking the list. As near as I can tell, this shouldn't have any negative
> sideeffects, but someone with a better understanding of fib_semantics.c will
> need to check over it. Cheers,
fib_create_info() makes sure that fi->fib_nhs is always at least one.
So the conditional can be removed. After a fib_info is create, it's
fi->fib_nhs is immutable, it doesn't change.
In fact there are some checks for fi->fib_nhs == 0 elsewhere in this
code, those are bogus too, and I imagine you saw those when coding
up this patch. :-)
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists