datapath/flow: Fix ovs_flow_stats_get/clear RCU dereference.
authorJarno Rajahalme <jrajahalme@nicira.com>
Wed, 2 Apr 2014 18:14:58 +0000 (11:14 -0700)
committerJarno Rajahalme <jrajahalme@nicira.com>
Wed, 2 Apr 2014 18:14:58 +0000 (11:14 -0700)
commit4bb90bea0c4e725c4522f7de470a3b2f8251413a
tree8080ab679b9d1f636f3149baffd0af790838926b
parent87e6ccfba9ba8c94a09de1205da4a9f064ac7bd6
datapath/flow: Fix ovs_flow_stats_get/clear RCU dereference.

For ovs_flow_stats_get() using ovsl_dereference() was wrong, since
flow dumps call this with RCU read lock.

ovs_flow_stats_clear() is always called with ovs_mutex, so can use
ovsl_dereference().

Also, make the ovs_flow_stats_get() 'flow' argument const to make
later patches cleaner.

Signed-off-by: Jarno Rajahalme <jrajahalme@nicira.com>
Signed-off-by: Pravin B Shelar <pshelar@nicira.com>
datapath/flow.c
datapath/flow.h