diff options
author | Ben Pfaff <blp@nicira.com> | 2013-09-19 11:03:47 -0700 |
---|---|---|
committer | Ben Pfaff <blp@nicira.com> | 2013-09-19 11:03:47 -0700 |
commit | 04a19fb8f4b8ba19a9805906aac7b30b65b57206 (patch) | |
tree | b1c57c6e411072f3a89e86caea29482208f62a7c /ofproto/ofproto-dpif-upcall.h | |
parent | a31dab7f49223342012860c42d30aad5c3508031 (diff) | |
download | openvswitch-04a19fb8f4b8ba19a9805906aac7b30b65b57206.tar.gz |
ofproto-dpif-upcall: Forward packets in order of arrival.
Until now, the code in ofproto-dpif-upcall (and the code that preceded it
in ofproto-dpif) obtained a batch of incoming packets, inserted them into
a hash table based on hashes of their flows, processed them, and then
forwarded them in hash order. Usually this maintains order within a single
network connection, but because OVS's notion of a flow is so fine-grained,
it can reorder packets within (e.g.) a TCP connection if two packets
handled in a single batch have (e.g.) different ECN values.
This commit fixes the problem by making ofproto-dpif-upcall always forward
packets in the same order they were received.
This is far from the minimal change necessary to avoid reordering packets.
I think that the code is easier to understand afterward.
Reported-by: Dmitry Fleytman <dfleytma@redhat.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Jarno Rajahalme <jrajahalme@nicira.com>
Diffstat (limited to 'ofproto/ofproto-dpif-upcall.h')
-rw-r--r-- | ofproto/ofproto-dpif-upcall.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/ofproto/ofproto-dpif-upcall.h b/ofproto/ofproto-dpif-upcall.h index a23f7a0e2..9bd19ad52 100644 --- a/ofproto/ofproto-dpif-upcall.h +++ b/ofproto/ofproto-dpif-upcall.h @@ -59,6 +59,7 @@ enum upcall_type { /* An upcall. */ struct upcall { struct list list_node; /* For queuing upcalls. */ + struct flow_miss *flow_miss; /* This upcall's flow_miss. */ enum upcall_type type; /* Classification. */ @@ -94,8 +95,6 @@ struct flow_miss { struct dpif_flow_stats stats; struct xlate_out xout; - - struct list upcalls; /* Contains "struct upcall"s. */ }; struct flow_miss_batch { |