#include <linux/kernel.h>
#include <linux/netlink.h>
#include <linux/openvswitch.h>
#include <linux/spinlock.h>
#include <linux/types.h>
#include <linux/rcupdate.h>
#include <linux/if_ether.h>
#include <linux/in6.h>
#include <linux/jiffies.h>
#include <linux/time.h>
#include <linux/flex_array.h>
#include <net/inet_ecn.h>
Go to the source code of this file.
|
int | ovs_flow_init (void) |
|
void | ovs_flow_exit (void) |
|
struct sw_flow * | ovs_flow_alloc (void) |
|
void | ovs_flow_deferred_free (struct sw_flow *) |
|
void | ovs_flow_free (struct sw_flow *flow) |
|
struct sw_flow_actions * | ovs_flow_actions_alloc (const struct nlattr *) |
|
void | ovs_flow_deferred_free_acts (struct sw_flow_actions *) |
|
int | ovs_flow_extract (struct sk_buff *, u16 in_port, struct sw_flow_key *, int *key_lenp) |
|
void | ovs_flow_used (struct sw_flow *, struct sk_buff *) |
|
u64 | ovs_flow_used_time (unsigned long flow_jiffies) |
|
int | ovs_flow_to_nlattrs (const struct sw_flow_key *, struct sk_buff *) |
|
int | ovs_flow_from_nlattrs (struct sw_flow_key *swkey, int *key_lenp, const struct nlattr *) |
|
int | ovs_flow_metadata_from_nlattrs (u32 *priority, u16 *in_port, const struct nlattr *) |
|
struct sw_flow * | ovs_flow_tbl_lookup (struct flow_table *table, struct sw_flow_key *key, int len) |
|
void | ovs_flow_tbl_destroy (struct flow_table *table) |
|
void | ovs_flow_tbl_deferred_destroy (struct flow_table *table) |
|
struct flow_table * | ovs_flow_tbl_alloc (int new_size) |
|
struct flow_table * | ovs_flow_tbl_expand (struct flow_table *table) |
|
struct flow_table * | ovs_flow_tbl_rehash (struct flow_table *table) |
|
void | ovs_flow_tbl_insert (struct flow_table *table, struct sw_flow *flow) |
|
void | ovs_flow_tbl_remove (struct flow_table *table, struct sw_flow *flow) |
|
u32 | ovs_flow_hash (const struct sw_flow_key *key, int key_len) |
|
struct sw_flow * | ovs_flow_tbl_next (struct flow_table *table, u32 *bucket, u32 *idx) |
|
#define MAX_ACTIONS_BUFSIZE (16 * 1024) |
#define TBL_MIN_BUCKETS 1024 |
ovs_flow_extract - extracts a flow key from an Ethernet frame. : sk_buff that contains the frame, with skb->data pointing to the Ethernet header : port number on which was received. : output flow key : length of output flow key
The caller must ensure that skb->len >= ETH_HLEN.
Returns 0 if successful, otherwise a negative errno value.
Initializes header pointers as follows:
- skb->network_header: just past the Ethernet header, or just past the VLAN header, to the first byte of the Ethernet payload.
- skb->transport_header: If key->dl_type is ETH_P_IP or ETH_P_IPV6 on output, then just past the IP header, if one is present and of a correct length, otherwise the same as skb->network_header. For other key->dl_type values it is left untouched.
Definition at line 596 of file flow.c.
ovs_flow_from_nlattrs - parses Netlink attributes into a flow key. : receives the extracted flow key. : number of bytes used in . : Netlink attribute holding nested OVS_KEY_ATTR_* Netlink attribute sequence.
Definition at line 960 of file flow.c.
ovs_flow_metadata_from_nlattrs - parses Netlink attributes into a flow key. : receives the extracted input port. : Netlink attribute holding nested OVS_KEY_ATTR_* Netlink attribute sequence.
This parses a series of Netlink attributes that form a flow key, which must take the same form accepted by flow_from_nlattrs(), but only enough of it to get the metadata, that is, the parts of the flow key that cannot be extracted from the packet itself.
Definition at line 1125 of file flow.c.
u64 ovs_flow_used_time |
( |
unsigned long |
flow_jiffies | ) |
|