There are several places where the flow table is accessed
without any kind of RCU protection. This is fine because dp
mutex is held so this adds checks for that condition.
Found with sparse.
Signed-off-by: Jesse Gross <jesse@nicira.com>
Acked-by: Ben Pfaff <blp@nicira.com>
err_destroy_local_port:
dp_detach_port(dp->ports[ODPP_LOCAL]);
err_destroy_table:
- tbl_destroy(dp->table, NULL);
+ tbl_destroy(get_table_protected(dp), NULL);
err_free_dp:
kfree(dp);
err_put_module:
rcu_assign_pointer(dps[dp->dp_idx], NULL);
dp_detach_port(dp->ports[ODPP_LOCAL]);
-
- tbl_destroy(dp->table, flow_free_tbl);
+ tbl_destroy(get_table_protected(dp), flow_free_tbl);
for (i = 0; i < DP_N_QUEUES; i++)
skb_queue_purge(&dp->queues[i]);