Hi Ben, This seires adds a command line options to ovs-vswitchd and various utilities to allow the range of Open Flow versions to be set at run-time.
The options are --max-ofp-version and --min-ofp-version. The values accepted are: OpenFlow10, OpenFlow11 and OpenFlow12. The default for both options is OpenFlow10 which means that by default the behaviour is unchanged. You mentioned to me in passing a month or so back that you envisaged some or all of this configuration residing in the database. I am happy to change the code accordingly if you give me some guidance on what and how configuration should be stored in the database. One problem with the max/min scheme is that although I believe it is in keeping with the spec it does not take into account that Open vSwtich doesn not have a working implementation of OpenFlow11. Or in other words, with these options in place if the negotiated version is OpenFlow10 or OpenFlow12 then things should work well, buts and a small number of outstanding OpenFlow12 features not withstanding, but if the negotiated version is OpenFlow11 then the session will be terminated. It ought to be possible to resolve this in the case that Open vSwtich code is on both sides of the session - e.g. by teaching the Open vSwtich code how to skip OpenFlow11 or providing a list of acceptable versions rather than a range. However, I'm unsure of a mechanism to do this that is within the OpenFlow spec. These patches are independenent of other outstanding OpenFlow 1.2 patches that I have previously posted. ---------------------------------------------------------------- The following changes since commit f0b8759908a74f018f6bd75fdc1b7f1ff8776f5f: tests: jemalloc debug config for FreeBSD 9 and 10. (2012-10-02 09:23:20 -0700) are available in the git repository at: git://github.com/horms/openvswitch.git devel/of1.2-runtime-switch for you to fetch changes up to b9c06aeba7715a699d47bb1640c796ecdd95bc1d: test: vswtichd: Set max-ofp-version OpenFlow12 (2012-10-04 11:26:53 +0900) ---------------------------------------------------------------- Simon Horman (17): ofp-util: Set Packet In Format: Use prevailing OpenFlow version vconn: Allow passing a maximum Open Flow version ofp-util: Allow use of OF12 flow format connmgr: Use version of underlying rconn connmgr: connmgr_destroy(): Paramatise Open Flow version ofproto: ofproto_run(): Paramatise Open Flow version rconn: Add minimum and maximum OpenFlow versions ofproto, connmgr: Parameterise OpenFlow versions for adding controller ofp-util: Add ofputil_protocols_{from,to}_string() util: ovs_print_version(): Show names of OpenFlow versions lib: Add helpers for OpenFlow version command line options ovs-vswitchd: Add options to allow seting of OpenFlow version ovs-ofctl: Add options to allow seting of OpenFlow version ovs-controller: Add options to allow seting of OpenFlow version ovs-ofctl: By default, do not set flow format for OpenFlow 1.1+ ofp-util: Open Flow 1.1 and 1.2 flow format capabilities test: vswtichd: Set max-ofp-version OpenFlow12 lib/automake.mk | 3 ++ lib/ofp-util.c | 81 ++++++++++++++++++++++++++--------- lib/ofp-util.h | 15 +++++-- lib/ofp-version-opt.c | 32 ++++++++++++++ lib/ofp-version-opt.h | 39 +++++++++++++++++ lib/ofp-version.man | 23 ++++++++++ lib/rconn.c | 12 +++++- lib/rconn.h | 5 ++- lib/util.c | 7 +++- lib/vconn-provider.h | 1 + lib/vconn.c | 35 +++++++++------- lib/vconn.h | 9 ++-- manpages.mk | 4 ++ ofproto/connmgr.c | 38 ++++++++++++----- ofproto/connmgr.h | 7 +++- ofproto/ofproto.c | 15 ++++--- ofproto/ofproto.h | 7 +++- tests/learn.at | 2 +- tests/ofproto-macros.at | 2 +- tests/ovs-ofctl.at | 2 +- tests/test-vconn.c | 16 +++---- utilities/ovs-controller.8.in | 1 + utilities/ovs-controller.c | 23 ++++++---- utilities/ovs-ofctl.8.in | 1 + utilities/ovs-ofctl.c | 93 +++++++++++++++++++++++++---------------- vswitchd/bridge.c | 27 +++++++----- vswitchd/bridge.h | 4 +- vswitchd/ovs-vswitchd.8.in | 1 + vswitchd/ovs-vswitchd.c | 16 ++++--- 29 files changed, 382 insertions(+), 139 deletions(-) create mode 100644 lib/ofp-version-opt.c create mode 100644 lib/ofp-version-opt.h create mode 100644 lib/ofp-version.man _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev