Commit Graph

61 Commits

Author SHA1 Message Date
Justin Pettit f1126f43ad Switch default OpenFlow port from 975 and 976 to 6633. 2008-10-22 17:17:50 -07:00
Ben Pfaff 4a4424a739 Support up to 0xff00 ports in OpenFlow, without changing the implemented max. 2008-10-14 10:53:27 -07:00
Justin Pettit a835cab0ea Return error message when a flow can't be added due to full tables.
When a flow cannot be added to any tables because they are full, send
a message with type OFPET_FLOW_MOD_FAILED and code OFPFMFC_ALL_TABLES_FULL.
2008-10-13 17:49:45 -07:00
Justin Pettit 48edfb7cf9 Remove OFPT_TABLE reference. 2008-10-12 00:46:52 -07:00
Justin Pettit 94f287969d Add support for Source-NAT to Linux 2.6 datapaths.
To enable SNAT, run configure with the "--enable-snat" flag.  This has
only been tested with the 2.6.23 kernel...more diverse testing will follow.
Documentation and a cleaner build setup will also be in a future check-in.
2008-10-11 00:30:02 -07:00
Justin Pettit 1489ca2657 Add support for vendor-defined and variable-length actions.
Allow vendors to define their own actions.  Actions were originally fixed-
length, which was a bit constraining.  Actions now contain a length field,
which gives them more flexibility.
2008-10-03 16:44:13 -07:00
Justin Pettit 06e22ff0fe Modify VLAN actions to support setting both VID and priority.
Stripping VLANs is now done through the OFPAT_STRIP_VLAN action (i.e., you
don't specify a magic value in the generirc VLAN action).  Also, it is now
possible to modify the priority bits associated with the VLAN tag through
the OFPAT_SET_VLAN_PCP action.  The OFPAT_SET_DL_VLAN has been renamed to
OFPAT_SET_VLAN_VID.
2008-09-25 15:00:38 -07:00
Justin Pettit 902b816539 Fix some old references to OFPPFL_ in comments. 2008-09-22 17:48:06 -07:00
Justin Pettit 9da88ee2ad Modify OpenFlow commands related to ports to be more expressive.
This new OpenFlow message format provides a cleaner interface and greater
detail and control over ports.  It is now possible to see what features
the switch's port is currently configured as having, what it's advertising,
and what it's capable of handling.  It is also possible to return the
features advertised by the port's peer.
2008-09-22 15:18:22 -07:00
Ben Pfaff 512f02d405 Get rid of per-port STP implemented bits, by reducing OFPP_MAX to 255.
802.1D Spanning Tree Protocol supports a maximum of 255 ports per bridge,
but OpenFlow supported 256, so 1 port had to not implement STP.  This
gets rid of the problem by reducing the maximum number of ports to 255.
2008-09-19 17:07:47 -07:00
Justin Pettit 034f125955 Added lookup count to ofp_table_stats. 2008-09-18 19:47:27 -07:00
Justin Pettit e4cf5c4b82 Added OFPFC_MODIFY_STRICT flow mod command.
This cleans up the handling of modifying existing flows.  There now exists
OFPFC_MODIFY and OFPFC_MODIFY_STRICT commands, which have the same matching
characteristics to their OFPFC_DELETE* counterparts.  When adding a flow that
already exists, the counters and timers are now reset (ie, its treated as a
new flow).  This commit also adds the "--strict" option to dpctl to allow
strict matching for "mod-flows" and "del-flows".
2008-09-16 16:07:41 -07:00
Justin Pettit 57d5205765 Add support for OFPFC_MODIFY Flow Mod command.
The OFPFC_MODIFY command allows the controller to modify the actions of
existing flows.  When it does this, it does not reset counters or timers.
2008-09-15 15:27:04 -07:00
Ben Pfaff 9c1b16772c Implement OFPT_HELLO simple version negotiation. 2008-09-15 14:29:53 -07:00
Ben Pfaff 74cacf6067 Get rid of OFP_MAXLEN.
Statistics or vendor extensions can fill up the whole 64 kB.
2008-09-10 20:05:49 -07:00
Ben Pfaff d0fb7347b9 Delete OFPST_SWITCH and make it available as a Nicira vendor extension. 2008-09-10 15:00:47 -07:00
Ben Pfaff 39136b0fb9 Make switches send error messages when they receive a bad request. 2008-09-10 13:22:25 -07:00
Ben Pfaff 696db2c3b6 Add vendor-specific messages and statistics to OpenFlow protocol. 2008-09-10 13:21:34 -07:00
Justin Pettit 176265ed07 Use new method to describe table entries in OpenFlow wire protocol.
Older versions of OpenFlow pre-defined a few different types of tables and the
Features Reply message would indicate how many of those entries existed.  This
was very inflexible, so now the Features Reply just indicates how many tables
there are.  The controller now sends a Table Stats request to find out how
many entries are supported and the fields that can be wildcarded.

This change also removes the "buffer_mb" field from the Features Reply, since
it was not being used and seemed to be of limited value.
2008-09-10 13:03:25 -07:00
Ben Pfaff b5e9402df5 Implement 802.1D Spanning Tree Protocol. 2008-09-09 14:15:57 -07:00
Justin Pettit 7d7d973d8b Add serial number to description status message. 2008-09-03 17:51:42 -07:00
Ben Pfaff e3d722e73b Implement new OpenFlow "switch statistics" feature.
This should be useful for reporting the status of a switch on its
front-panel display (for those switches that have one) or in the
controller UI.
2008-08-26 11:53:51 -07:00
Justin Pettit f1c6daebf3 Send PORT_STATUS messages on port and link changes. Add ability to remotely enable and disable a port through the PORT_MOD message. 2008-08-22 12:47:54 -07:00
Ben Pfaff 9630e41005 Implement subnet mask matching in OpenFlow. 2008-08-18 14:26:50 -07:00
Justin Pettit d6a1e67a8d Add stats message that allows querying description of components in OpenFlow. 2008-08-16 09:43:05 -07:00
Justin Pettit b41a6a0a6d Added new interface statistics. 2008-08-14 23:12:37 -07:00
Justin Pettit 0226bbc742 Switch to new packet-out format and add OFPP_IN_PORT.
The original packet-out format allowed multiple actions to be specified for
buffered packets, but only a destination port for messages including data.
This change makes packet-out more consistent by allowing multiple actions
regardless of how the packet is stored.

This change also disallows sending packets through the incoming port without
explicitly using the OFPP_IN_PORT virtual port.
2008-08-14 00:07:18 -07:00
Ben Pfaff 7bee00fad9 Implement OpenFlow hard timeouts.
This updates the OpenFlow protocol version and changes the names of
structure members, so any software that uses OpenFlow will need to be
updated to match.
2008-08-07 15:19:31 -07:00
Ben Pfaff eca2aeb329 Implement OFPC_FRAG_DROP fragment handling policy. 2008-08-07 10:34:37 -07:00
Ben Pfaff ca477c1000 Fix typo in comment. 2008-08-05 10:50:09 -07:00
Ben Pfaff 67a603dde8 Make openflow.h SWIG-friendly. 2008-07-21 11:39:39 -07:00
Ben Pfaff e88c18152d Assert on structure sizes in openflow.h.
This causes the build to fail if structures are not the sizes that we
expect.
2008-07-17 09:47:25 -07:00
Ben Pfaff b993fa9c2b Adjust OpenFlow to have same structure layout on 32- and 64-bit platforms.
Pointed out by "Brandon Heller" <brandon.heller@gmail.com>.
2008-07-17 09:47:25 -07:00
Ben Pfaff 258f32a084 Respond to echo requests in OpenFlow implementations.
Nothing yet sends such requests.  This is preparation for their
use in following commits.
2008-07-01 10:51:50 -07:00
Ben Pfaff 59ba307325 Make the OFPP_LOCAL port work in the kernel OpenFlow implementation. 2008-05-28 10:46:54 -07:00
Justin Pettit 2f009daf82 Clean-up OpenFlow main header a bit. 2008-05-04 21:05:51 -07:00
Ben Pfaff f7bf3916ff Implement aggregate flow statistics in kernel and userspace switches. 2008-05-02 16:58:33 -07:00
Ben Pfaff 4f5b4efc54 Send actions as part of flow statistics messages. 2008-05-02 10:58:53 -07:00
Ben Pfaff 2e12784892 Add max_idle field to flow stats messages. 2008-05-02 10:58:52 -07:00
Justin Pettit 917160e384 - Add priority to flow expiration messages.
- Clear contents of "pad" field port status messages.
2008-05-01 17:11:29 -07:00
Ben Pfaff 3b9c97ee01 Implement new statistics format in kernel and userspace switches.
This change really cuts the muster!
2008-05-01 17:04:44 -07:00
Justin Pettit 66b5c90376 - Add support for OpenFlow error message type.
- Ensure OpenFlow messages fit in 16-bit length field.
2008-04-30 17:38:03 -07:00
Justin Pettit d1d2f3f321 - On flow entries with wildcards, match priority field when doing a "strict" delete.
- Remove group_id from flow entries.
- Show priority when print flow mod messages.
2008-04-29 15:00:28 -07:00
Ben Pfaff 3ee68a5b11 Fix openflow.h compilation with GCC 2.95.
Necessary because older Linux 2.4 releases will only compile with GCC 2.95.
2008-04-29 10:19:36 -07:00
Ben Pfaff 9b97611f42 Fix typo in comment. 2008-04-28 13:52:27 -07:00
Justin Pettit 44e9d4f5fc Clean-up related to supporting priorities...mostly suggestions from Ben. 2008-04-26 14:27:32 -07:00
Justin Pettit bfe3b4df89 - Add support for flow entry priorities.
- Fix "flow-add" action for dpctl.
2008-04-26 14:08:41 -07:00
Justin Pettit fc2925fecf Add priority field to flow_mod...code to support this forthcoming. 2008-04-21 18:13:42 -07:00
Justin Pettit 0d3a0643c4 Switch from "stat" to "stats" everywhere. 2008-04-16 15:38:25 -07:00
Justin Pettit 541d0fee0d - Keep datapath config in host-byte order (and fix a couple of bugs related to this).
- Fix type for "get config" replies.
2008-04-16 14:09:27 -07:00