git://git.onelab.eu
/
sliver-openvswitch.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
c62caaa
)
sflow: Properly fill in initial destination VLAN in sFlow output.
author
Neil McKee
<neil.mckee@inmon.com>
Wed, 5 May 2010 20:24:27 +0000
(13:24 -0700)
committer
Ben Pfaff
<blp@nicira.com>
Wed, 5 May 2010 20:27:08 +0000
(13:27 -0700)
ofproto/ofproto-sflow.c
patch
|
blob
|
history
diff --git
a/ofproto/ofproto-sflow.c
b/ofproto/ofproto-sflow.c
index
5488724
..
f764dc4
100644
(file)
--- a/
ofproto/ofproto-sflow.c
+++ b/
ofproto/ofproto-sflow.c
@@
-533,7
+533,9
@@
ofproto_sflow_received(struct ofproto_sflow *os, struct odp_msg *msg)
switchElem.tag = SFLFLOW_EX_SWITCH;
switchElem.flowType.sw.src_vlan = ntohs(flow.dl_vlan);
switchElem.flowType.sw.src_priority = -1; /* XXX */
switchElem.tag = SFLFLOW_EX_SWITCH;
switchElem.flowType.sw.src_vlan = ntohs(flow.dl_vlan);
switchElem.flowType.sw.src_priority = -1; /* XXX */
- switchElem.flowType.sw.dst_vlan = -1; /* Filled in correctly below. */
+ /* Initialize the output VLAN and priority to be the same as the input,
+ but these fields can be overriden below if affected by an action. */
+ switchElem.flowType.sw.dst_vlan = switchElem.flowType.sw.src_vlan;
switchElem.flowType.sw.dst_priority = switchElem.flowType.sw.src_priority;
/* Figure out the output ports. */
switchElem.flowType.sw.dst_priority = switchElem.flowType.sw.src_priority;
/* Figure out the output ports. */