summaryrefslogtreecommitdiff
path: root/ofproto/netflow.h
Commit message (Collapse)AuthorAgeFilesLines
* netflow: Mark some function parameters 'const'.Ben Pfaff2015-07-231-3/+3
| | | | | Signed-off-by: Ben Pfaff <blp@nicira.com> Acked-by: Jarno Rajahalme <jrajahalme@nicira.com>
* netflow: Fold netflow_expire() into netflow_flow_clear().Anoob Soman2014-06-091-2/+1
| | | | | | | | | | | | | | | | | | | netflow_flow_clear() asserted that no packets or bytes were included in the statistics for the flow being cleared. Before threading Open vSwitch, this assertion was always true because netflow_expire() was always called before calling netflow_flow_clear(). Since Open vSwitch was threaded, however, it was possible that a packet arrived after netflow_expire() but before netflow_flow_clear(), since each of these function separately took the netflow mutex. This commit fixes the problem by merging netflow_expire() into netflow_flow_clear(), under a single acquisition of the netflow mutex. Signed-off-by: Anoob Soman <anoob.soman@citrix.com> [blp@nicira.com modified the patch to remove netflow_expire() and rewrote the commit message] Signed-off-by: Ben Pfaff <blp@nicira.com>
* netflow: Make netflow_flow_update() parameter const.Joe Stringer2014-03-111-1/+1
| | | | | | | The 'flow' parameter is not modified, so mark it const. Signed-off-by: Joe Stringer <joestringer@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
* ofproto: New function netflow_exists().Ethan Jackson2013-12-121-0/+1
| | | | | | | Useful in future patches. Signed-off-by: Ethan Jackson <ethan@nicira.com> Acked-by: Ben Pfaff <blp@nicira.com>
* netflow: Make thread safe.Ethan Jackson2013-12-121-1/+3
| | | | | | | In future patches upcall handler threads will need to update netflow. Signed-off-by: Ethan Jackson <ethan@nicira.com> Acked-by: Ben Pfaff <blp@nicira.com>
* ofproto: Modularize netflow.Ethan Jackson2013-12-121-22/+7
| | | | | | | | | | The netflow code has its tentacles all over the ofproto-dpif module. This is fine today, but in future facets, which correspond roughly to netflow_flows, will be retired. In preparation, this patch hides as much implementation detail as possible inside the netflow module. Signed-off-by: Ethan Jackson <ethan@nicira.com> Acked-by: Ben Pfaff <blp@nicira.com>
* Widen TCP flags handling.Jarno Rajahalme2013-10-291-2/+2
| | | | | | | | | | | Widen TCP flags handling from 7 bits (uint8_t) to 12 bits (uint16_t). The kernel interface remains at 8 bits, which makes no functional difference now, as none of the higher bits is currently of interest to the userspace. Signed-off-by: Jarno Rajahalme <jrajahalme@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com> Acked-by: Jesse Gross <jesse@nicira.com>
* netflow: Only un-wildcard IPv4 packets.Justin Pettit2013-06-271-1/+1
| | | | | | | | NetFlow v5 only supports IPv4, so don't bother un-wildcarding non-IPv4 packets. Signed-off-by: Justin Pettit <jpettit@nicira.com> Acked-by: Ethan Jackson <ethan@nicira.com>
* Create specific types for ofp and odp portAlex Wang2013-06-201-7/+5
| | | | | | | | | | | | Until now, datapath ports and openflow ports were both represented by unsigned integers of various sizes. With implicit conversions, etc., it is easy to mix them up and use one where the other is expected. This commit creates two typedefs, ofp_port_t and odp_port_t. Both of these two types are marked by "__attribute__((bitwise))" so that sparse can be used to detect any misuse. Signed-off-by: Alex Wang <alexw@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
* ofproto-dpif: Tighten up megaflow wildcard handling.Justin Pettit2013-06-191-0/+2
| | | | | | | | | | | A number of use-cases weren't handled properly when determining what can be wildcarded for megaflows. This commit both catches additional fields that cannot be wildcarded and loosens a few other cases. Bug #17979 Signed-off-by: Justin Pettit <jpettit@nicira.com> Acked-by: Ben Pfaff <blp@nicira.com>
* Global replace of Nicira Networks.Raju Subramanian2012-05-021-1/+1
| | | | | | | | Replaced all instances of Nicira Networks(, Inc) to Nicira, Inc. Feature #10593 Signed-off-by: Raju Subramanian <rsubramanian@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
* netflow: Move packet definitions to header file.Ben Pfaff2011-12-191-2/+2
| | | | | | | | An upcoming commit will introduce code outside of ofproto/netflow.c that works with NetFlow packets, so we need the protocol definitions in a common location. Signed-off-by: Ben Pfaff <blp@nicira.com>
* ofproto-dpif: Factor NetFlow active timeouts out of flow expiration.Ben Pfaff2011-11-231-1/+3
| | | | | | | | | | | | NetFlow active timeouts were only mixed in with flow expiration for convenience: both processes need to iterate all the facets. But an upcoming commit will change flow expiration to work in terms of a new "subfacet" entity, so they will no longer fit together well. This change could be seen as an optimization, since NetFlow active timeouts don't ordinarily have to run as often as flow expiration, especially when the flow expiration rate is stepped up due to a large volume of flows.
* ofproto: Change string sets in interface from svec to sset.Ben Pfaff2011-03-311-3/+3
|
* ofproto: Avoid clearing NetFlow stats twice upon rule creation.Ben Pfaff2010-11-111-0/+1
| | | | | This seems cleaner to me: it seems risky to "clear" something that has not been initialized yet. It's also a super-minor optimization, I suppose.
* datapath: Don't track IP TOS value two different ways.Ben Pfaff2010-08-021-3/+1
| | | | | | | | | | | | | Originally, the datapath didn't care about IP TOS at all. Then, to support NetFlow, we made it keep track of the last-seen IP TOS value on a per-flow basis. Then, to support OpenFlow 1.0, we added a nw_tos field to odp_flow_key. We don't need both methods, so this commit drops the NetFlow-specific tracking. This introduces a small kernel ABI break: upgrading the kernel module without upgrading the OVS userspace will mean that NetFlow records will all show an IP TOS value of 0. I don't consider that to be a serious problem.
* netflow: Use macro for constant instead of static const int.Ben Pfaff2010-05-191-1/+6
| | | | | It's just bizarre to put a static const int in a header file, at least in C.
* Merge "master" into "next".Ben Pfaff2010-02-241-1/+2
|\
| * Add missing <stdint.h> includes.Ben Pfaff2010-02-121-1/+2
| | | | | | | | Reported-by: Jean Tourrilhes <jt@hpl.hp.com>
* | netflow: Correctly set active timeout value.Jesse Gross2009-12-071-0/+2
|/ | | | | | | | | This fixes a bug originally introduced in commit 763435 "vswitchd: Initial conversion to database-based configuration." The bug reversed a less than operator when setting the active timeout field. Also add a warning if the timeout is set to an invalid value. CC: Glen Gibb <grg@stanford.edu>
* Merge citrix branch into master.Jesse Gross2009-11-101-5/+37
|
* Rename "secchan" to "ofproto" (library) and "ovs-openflowd" (program).Ben Pfaff2009-07-081-0/+33
These names are more meaningful, so we prefer them.