mirror of
https://github.com/openvswitch/ovs
synced 2025-08-30 22:05:19 +00:00
dpif-netdev: Remove unneeded 'key' parameter from dp_netdev_flow_used().
The 'key' passed to dp_netdev_flow_used() is the same as the 'key' member in the struct dp_netdev_flow also passed to the function. Signed-off-by: Ben Pfaff <blp@nicira.com> Acked-by: Ethan Jackson <ethan@nicira.com>
This commit is contained in:
@@ -996,13 +996,12 @@ dpif_netdev_recv_purge(struct dpif *dpif)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
dp_netdev_flow_used(struct dp_netdev_flow *flow, struct flow *key,
|
dp_netdev_flow_used(struct dp_netdev_flow *flow, const struct ofpbuf *packet)
|
||||||
const struct ofpbuf *packet)
|
|
||||||
{
|
{
|
||||||
flow->used = time_msec();
|
flow->used = time_msec();
|
||||||
flow->packet_count++;
|
flow->packet_count++;
|
||||||
flow->byte_count += packet->size;
|
flow->byte_count += packet->size;
|
||||||
flow->tcp_flags |= packet_get_tcp_flags(packet, key);
|
flow->tcp_flags |= packet_get_tcp_flags(packet, &flow->key);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
@@ -1018,7 +1017,7 @@ dp_netdev_port_input(struct dp_netdev *dp, struct dp_netdev_port *port,
|
|||||||
flow_extract(packet, 0, 0, odp_port_to_ofp_port(port->port_no), &key);
|
flow_extract(packet, 0, 0, odp_port_to_ofp_port(port->port_no), &key);
|
||||||
flow = dp_netdev_lookup_flow(dp, &key);
|
flow = dp_netdev_lookup_flow(dp, &key);
|
||||||
if (flow) {
|
if (flow) {
|
||||||
dp_netdev_flow_used(flow, &key, packet);
|
dp_netdev_flow_used(flow, packet);
|
||||||
dp_netdev_execute_actions(dp, packet, &key,
|
dp_netdev_execute_actions(dp, packet, &key,
|
||||||
flow->actions, flow->actions_len);
|
flow->actions, flow->actions_len);
|
||||||
dp->n_hit++;
|
dp->n_hit++;
|
||||||
|
Reference in New Issue
Block a user