From: Eric Dumazet Date: Wed, 7 Mar 2007 04:23:10 +0000 (-0800) Subject: [IPV4]: Optimize inet_getpeer() X-Git-Tag: v2.6.22-rc1~1128^2~397 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=243bbcaa09e8482aa28065cbc2eb99f0ca2fc8d6;p=pandora-kernel.git [IPV4]: Optimize inet_getpeer() 1) Some sysctl vars are declared __read_mostly 2) We can avoid updating stack[] when doing an AVL lookup only. lookup() macro is extended to receive a second parameter, that may be NULL in case of a pure lookup (no need to save the AVL path). This removes unnecessary instructions, because compiler knows if this _stack parameter is NULL or not. text size of net/ipv4/inetpeer.o is 2063 bytes instead of 2107 on x86_64 Signed-off-by: Eric Dumazet Signed-off-by: David S. Miller --- Reading git-diff-tree failed