2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-31 22:35:15 +00:00

upcall: Remove redundant xlate_actions_for_side_effects().

As a result of commit a0bab87 (ofproto: Remove per-flow miss hash
table from upcall handler.) we're guaranteed that every packet has had
xlate_actions() called on it at least once.  Therefore, there's no
need to re-xlate slow path flows just to shove their packets through
the system.

This also may fix a bug discussed here:
http://openvswitch.org/pipermail/discuss/2014-April/013670.html

Signed-off-by: Ethan Jackson <ethan@nicira.com>
Reported-by: Murphy McCauley <murphy.mccauley@gmail.com>
Acked-by: Ben Pfaff <blp@nicira.com>
This commit is contained in:
Ethan Jackson
2014-05-22 10:53:27 -07:00
parent 3b3f885732
commit 691d39b2f9

View File

@@ -692,8 +692,8 @@ upcall_init(struct upcall *upcall, struct flow *flow, struct ofpbuf *packet,
struct ofproto_dpif *ofproto, struct dpif_upcall *dupcall,
odp_port_t odp_in_port)
{
struct xlate_in xin;
struct pkt_metadata md = pkt_metadata_from_flow(flow);
struct xlate_in xin;
flow_extract(packet, &md, &upcall->flow);
@@ -708,8 +708,7 @@ upcall_init(struct upcall *upcall, struct flow *flow, struct ofpbuf *packet,
upcall->odp_in_port = odp_in_port;
xlate_in_init(&xin, upcall->ofproto, &upcall->flow, NULL,
upcall->stats.tcp_flags, NULL);
xin.may_learn = true;
upcall->stats.tcp_flags, packet);
if (upcall->upcall_type == DPIF_UC_MISS) {
xin.resubmit_stats = &upcall->stats;
@@ -867,13 +866,6 @@ handle_upcalls(struct handler *handler, struct upcall *upcalls,
fail_open = fail_open || upcall->xout.fail_open;
if (upcall->xout.slow) {
struct xlate_in xin;
xlate_in_init(&xin, upcall->ofproto, &upcall->flow, NULL, 0, packet);
xlate_actions_for_side_effects(&xin);
}
if (upcall->flow.in_port.ofp_port
!= vsp_realdev_to_vlandev(upcall->ofproto,
upcall->flow.in_port.ofp_port,