diff options
Diffstat (limited to 'net/openvswitch/datapath.h')
-rw-r--r-- | net/openvswitch/datapath.h | 23 |
1 files changed, 15 insertions, 8 deletions
diff --git a/net/openvswitch/datapath.h b/net/openvswitch/datapath.h index 701b5738c38a..974135439c5c 100644 --- a/net/openvswitch/datapath.h +++ b/net/openvswitch/datapath.h | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * Copyright (c) 2007-2012 Nicira, Inc. | 2 | * Copyright (c) 2007-2014 Nicira, Inc. |
3 | * | 3 | * |
4 | * This program is free software; you can redistribute it and/or | 4 | * This program is free software; you can redistribute it and/or |
5 | * modify it under the terms of version 2 of the GNU General Public | 5 | * modify it under the terms of version 2 of the GNU General Public |
@@ -95,14 +95,15 @@ struct datapath { | |||
95 | /** | 95 | /** |
96 | * struct ovs_skb_cb - OVS data in skb CB | 96 | * struct ovs_skb_cb - OVS data in skb CB |
97 | * @flow: The flow associated with this packet. May be %NULL if no flow. | 97 | * @flow: The flow associated with this packet. May be %NULL if no flow. |
98 | * @pkt_key: The flow information extracted from the packet. Must be nonnull. | 98 | * @egress_tun_key: Tunnel information about this packet on egress path. |
99 | * @tun_key: Key for the tunnel that encapsulated this packet. NULL if the | 99 | * NULL if the packet is not being tunneled. |
100 | * packet is not being tunneled. | 100 | * @input_vport: The original vport packet came in on. This value is cached |
101 | * when a packet is received by OVS. | ||
101 | */ | 102 | */ |
102 | struct ovs_skb_cb { | 103 | struct ovs_skb_cb { |
103 | struct sw_flow *flow; | 104 | struct sw_flow *flow; |
104 | struct sw_flow_key *pkt_key; | 105 | struct ovs_tunnel_info *egress_tun_info; |
105 | struct ovs_key_ipv4_tunnel *tun_key; | 106 | struct vport *input_vport; |
106 | }; | 107 | }; |
107 | #define OVS_CB(skb) ((struct ovs_skb_cb *)(skb)->cb) | 108 | #define OVS_CB(skb) ((struct ovs_skb_cb *)(skb)->cb) |
108 | 109 | ||
@@ -183,17 +184,23 @@ static inline struct vport *ovs_vport_ovsl(const struct datapath *dp, int port_n | |||
183 | extern struct notifier_block ovs_dp_device_notifier; | 184 | extern struct notifier_block ovs_dp_device_notifier; |
184 | extern struct genl_family dp_vport_genl_family; | 185 | extern struct genl_family dp_vport_genl_family; |
185 | 186 | ||
186 | void ovs_dp_process_received_packet(struct vport *, struct sk_buff *); | 187 | void ovs_dp_process_packet(struct sk_buff *skb, struct sw_flow_key *key); |
187 | void ovs_dp_detach_port(struct vport *); | 188 | void ovs_dp_detach_port(struct vport *); |
188 | int ovs_dp_upcall(struct datapath *, struct sk_buff *, | 189 | int ovs_dp_upcall(struct datapath *, struct sk_buff *, |
189 | const struct dp_upcall_info *); | 190 | const struct dp_upcall_info *); |
190 | 191 | ||
192 | const char *ovs_dp_name(const struct datapath *dp); | ||
191 | struct sk_buff *ovs_vport_cmd_build_info(struct vport *, u32 pid, u32 seq, | 193 | struct sk_buff *ovs_vport_cmd_build_info(struct vport *, u32 pid, u32 seq, |
192 | u8 cmd); | 194 | u8 cmd); |
193 | 195 | ||
194 | int ovs_execute_actions(struct datapath *dp, struct sk_buff *skb); | 196 | int ovs_execute_actions(struct datapath *dp, struct sk_buff *skb, |
197 | struct sw_flow_key *); | ||
198 | |||
195 | void ovs_dp_notify_wq(struct work_struct *work); | 199 | void ovs_dp_notify_wq(struct work_struct *work); |
196 | 200 | ||
201 | int action_fifos_init(void); | ||
202 | void action_fifos_exit(void); | ||
203 | |||
197 | #define OVS_NLERR(fmt, ...) \ | 204 | #define OVS_NLERR(fmt, ...) \ |
198 | do { \ | 205 | do { \ |
199 | if (net_ratelimit()) \ | 206 | if (net_ratelimit()) \ |