X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=datapath%2Fdatapath.h;h=bb714d357e00ee0473b9dd71ac1257bfc97a1752;hb=32c18a40af5495395d7df133dae95dabc81d4877;hp=76798ef8e72dc8c66a05ea1b4ff13aab8c78c9e1;hpb=66b5c90376a6a4b9f01258c0a452256f65d42d9e;p=sliver-openvswitch.git diff --git a/datapath/datapath.h b/datapath/datapath.h index 76798ef8e..bb714d357 100644 --- a/datapath/datapath.h +++ b/datapath/datapath.h @@ -19,7 +19,10 @@ #endif /* Capabilities supported by this implementation. */ -#define OFP_SUPPORTED_CAPABILITIES (OFPC_MULTI_PHY_TX) +#define OFP_SUPPORTED_CAPABILITIES ( OFPC_FLOW_STATS \ + | OFPC_TABLE_STATS \ + | OFPC_PORT_STATS \ + | OFPC_MULTI_PHY_TX ) /* Actions supported by this implementation. */ #define OFP_SUPPORTED_ACTIONS ( (1 << OFPAT_OUTPUT) \ @@ -45,8 +48,7 @@ struct datapath { struct task_struct *dp_task; /* Kernel thread for maintenance. */ /* Data related to the "of" device of this datapath */ - struct net_device dev; - struct net_device_stats stats; + struct net_device *netdev; /* Configuration set from controller */ uint16_t flags; @@ -54,7 +56,8 @@ struct datapath { /* Switch ports. */ struct net_bridge_port *ports[OFPP_MAX]; - struct list_head port_list; /* List of ports, for flooding. */ + struct net_bridge_port *local_port; /* OFPP_LOCAL port. */ + struct list_head port_list; /* All ports, including local_port. */ }; /* Information necessary to reply to the sender of an OpenFlow message. */ @@ -71,13 +74,11 @@ int dp_set_origin(struct datapath *, uint16_t, struct sk_buff *); int dp_send_features_reply(struct datapath *, const struct sender *); int dp_send_config_reply(struct datapath *, const struct sender *); int dp_send_flow_expired(struct datapath *, struct sw_flow *); -int dp_send_flow_stats(struct datapath *, const struct sender *, - const struct ofp_match *); -int dp_send_table_stats(struct datapath *, const struct sender *); -int dp_send_port_stats(struct datapath *, const struct sender *); int dp_send_error_msg(struct datapath *, const struct sender *, uint16_t, uint16_t, const uint8_t *, size_t); int dp_update_port_flags(struct datapath *dp, const struct ofp_phy_port *opp); +int dp_send_echo_reply(struct datapath *, const struct sender *, + const struct ofp_header *); /* Should hold at least RCU read lock when calling */ struct datapath *dp_get(int dp_idx);