]> git.proxmox.com Git - mirror_ovs.git/commit
lib/bfd: Used relaxed atomics and optimize bfd_should_process_flow().
authorJarno Rajahalme <jrajahalme@nicira.com>
Fri, 29 Aug 2014 17:34:52 +0000 (10:34 -0700)
committerJarno Rajahalme <jrajahalme@nicira.com>
Fri, 29 Aug 2014 17:34:52 +0000 (10:34 -0700)
commit94f756daf21af97876266015e758aa96556ff6e8
treecc827982747cdf658590d1188df5c2088f1115bf
parentca4fbdfe52f4dee36391fb8ec006ee2190a339fc
lib/bfd: Used relaxed atomics and optimize bfd_should_process_flow().

The atomics here do not synchronize the state of any other variables,
so we can use atomic_count and relaxed atomics.

bfd_should_process_flow() is rearranged to set the megaflow mask bits
only if necessary, and to avoid the atomic operation on non-BFD
packets.

Signed-off-by: Jarno Rajahalme <jrajahalme@nicira.com>
Acked-by: Ben Pfaff <blp@nicira.com>
lib/bfd.c