aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/fib_semantics.c
diff options
context:
space:
mode:
authorEric Dumazet <eric.dumazet@gmail.com>2010-10-20 18:03:38 -0400
committerDavid S. Miller <davem@davemloft.net>2010-10-21 06:09:41 -0400
commit9b0c290e78d667e6a483bde8c7cef7dd15f49017 (patch)
treeed68f6cbcc9a512106217694b16a846147cdf54a /net/ipv4/fib_semantics.c
parent7b5edbc4cfe2297b0915adea5aa1eafcafadbf06 (diff)
fib: introduce fib_alias_accessed() helper
Perf tools session at NFWS 2010 pointed out a false sharing on struct fib_alias that can be avoided pretty easily, if we set FA_S_ACCESSED bit only if needed (ie : not already set) Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/fib_semantics.c')
-rw-r--r--net/ipv4/fib_semantics.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/fib_semantics.c b/net/ipv4/fib_semantics.c
index 6734c9cab248..3e0da3ef6116 100644
--- a/net/ipv4/fib_semantics.c
+++ b/net/ipv4/fib_semantics.c
@@ -901,7 +901,7 @@ int fib_semantic_match(struct list_head *head, const struct flowi *flp,
901 if (fa->fa_scope < flp->fl4_scope) 901 if (fa->fa_scope < flp->fl4_scope)
902 continue; 902 continue;
903 903
904 fa->fa_state |= FA_S_ACCESSED; 904 fib_alias_accessed(fa);
905 905
906 err = fib_props[fa->fa_type].error; 906 err = fib_props[fa->fa_type].error;
907 if (err == 0) { 907 if (err == 0) {