} else {
/* We found a matching flow. */
struct sw_flow_actions *old_acts, *new_acts;
- unsigned long int flags;
flow = flow_cast(flow_node);
}
/* Fetch stats, then clear them if necessary. */
- spin_lock_irqsave(&flow->lock, flags);
+ spin_lock_bh(&flow->lock);
get_stats(flow, stats);
if (uf->flags & ODPPF_ZERO_STATS)
clear_stats(flow);
- spin_unlock_irqrestore(&flow->lock, flags);
+ spin_unlock_bh(&flow->lock);
}
return 0;
{
struct sw_flow_actions *sf_acts;
struct odp_flow_stats stats;
- unsigned long int flags;
u32 n_actions;
- spin_lock_irqsave(&flow->lock, flags);
+ spin_lock_bh(&flow->lock);
get_stats(flow, &stats);
- if (query_flags & ODPFF_ZERO_TCP_FLAGS) {
+ if (query_flags & ODPFF_ZERO_TCP_FLAGS)
flow->tcp_flags = 0;
- }
- spin_unlock_irqrestore(&flow->lock, flags);
+
+ spin_unlock_bh(&flow->lock);
if (copy_to_user(ustats, &stats, sizeof(struct odp_flow_stats)) ||
get_user(n_actions, n_actionsp))