Re: dev_get_by_index is not hashed: O(n)

From: Ben Greear (
Date: Thu Aug 29 2002 - 19:37:36 EST

David S. Miller wrote:
> From: Dennis <>
> Date: Thu, 29 Aug 2002 18:16:00 -0400
> Yes, linux is quite a pig with 800 frame relay interfaces
> Try it with 'ip' or modern 'ifconfig' I bet your
> results change.
> Funniest part is that "ifconfig -a" doesn't even use
> dev_get_by_index so this whole conversation is one
> big crap :-)

What does it use? And btw, I'd hash get-by-name too.

The index hash is interesting because it's used so often in the kernel code,
though, evidently, not in critical paths as you note. Someday I'll put
a counter in to see how many times we do call it...just in case :)


Ben Greear <>          <>
President of Candela Technologies Inc

- To unsubscribe from this list: send the line "unsubscribe linux-net" in the body of a message to More majordomo info at

This archive was generated by hypermail 2b29 : Sat Aug 31 2002 - 22:00:01 EST