ofp-util: Allow use of OF12 flow format

This enables the use of the OF12 format, the prerequisites of which were
added by "Add OFPUTIL_P_OF12 and NXFF_OPENFLOW12" and patches to fill out
other functions that use OFPUTIL_P_OF12 directly.

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* No change

v9
* No change

v8
* Initial post
ofp-util: Allow decoding of Open Flow 1.2 Flow Statistics Request Messages

Allow decoding of Open Flow 1.1 and 1.2 flow and aggregate flow statistics
request messages.

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* Break Open FLow 1.1+ logic out into a separate function
  and leave Open Flow 1.0 logic function untouched other than
  renaming it.

v11
* No change

v10
* Manual rebase

v9
* No change

v8
* Manual rebase
* Add ofp-print test

v7
* Omitted

v6
* No change

v5
* Manual rebase

v4
* Use OFPG11_ANY in place of OFPG_ANY.
  The value is the same, but it seems to make sense to
  use the Open Flow 1.1 constant when working with Open Flow 1.1.
* Do not handle Open Flow 1.1, the parsing is slightly different
  and not supplied by this patch.
* Use sizeof(struct ofp11_flow_stats_request) as the minimum size of the
  message, previously sizeof(struct ofp10_flow_stats_request) was
  incorrectly used.
* Indicate that the message may be larger than the minimum size.
* Handle OFPUTIL_OFPST11_FLOW_REQUEST and OFPUTIL_OFPST11_AGGREGATE_REQUEST in
  ofputil_decode_flow_stats_request().
* Add entry for Open Flow 1.2 aggregate request to ofputil_msg_types[]

v3
* Initial post
ofp-msgs: Split OFPRAW_OFPST_AGGREGATE_REQUEST

Split OFPRAW_OFPST_AGGREGATE_REQUEST into OpenFlow 1.0 and 1.1+
versions.

This should be sufficient to allow adding encoding and decoding of
Open Flow 1.1 and 1.2 Aggregate Stats Request messages.

Encoding and decoding of Open Flow 1.1 and 1.2 Aggregate Stats Response
messages works using the existing code without modification.

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* Manual rebase

v11
* No change

v10
* Remove OpenFlow1.1 ofp-print tests, I do not have data
  for these at this time.

v9
* No change

v8
* Initial post
ofp-util: Allow decoding of Open Flow 1.1 & 1.2 Table Statistics Request Messages

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* No change

v9
* Set wildcards, match, write_setfields and apply_setfields based
  on a bitmap of (1 << OFPXMT_*)

v8
* Manual rebase
* Make use of enum ofp_version
* Add ofp-tests

v7
* Omitted

v6
* No change

v5
* Manual rebase
* Add OFPST_TABLE entry for Open Flow 1.1 and 1.2 to ofputil_msg_types,
  this wires-up decoding of table statistics messages.

v4
* Initial post

table test
ovs-ofctl: Use vconn as a parameter of dump_stats_transaction()

In order to form a stats message for the prevailing OpenFlow version
of a vconn the vconn needs to be open at the time the request is
encoded. Thus there is no longer a case where it makes sense to
use dump_stats_transaction() without a vconn already being open and
available to pass as a parameter.

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* No change

v9
* No change

v8
* Initial post
ofp-msgs: Allow encoding and decoding of Open Flow 1.1 & 1.2 Barrier Messages

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* No change

v9
* No change

v8
* Initial post
ofp-msgs: Split OFPRAW_OFPST_PORT_{REQUEST,REPLY}

Split OFPRAW_OFPST_PORT_{REQUEST,REPLY} into OpenFlow 1.0 and 1.1+
versions.

This prepares for encoding and decoding Open Flow 1.1 and 1.2 Port Stats
Request and Reply messages.

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* No change

v9
* Update description - this only prepares for both encoding and decoding
* Move tests to "ofp-print: Allow printing of Open Flow 1.1 & 1.2 Port
  Reply Messages" as this is just a preparatory patch.

v8
* Initial post
ovs-ofputil: Make str_to_port_no() aware of invalid ports

Open Flow 1.1 and 1.2 make use of 32 bit ports,
however Open vSwtich maps them to 16 bits. Make
ovs-ofputl aware of this.

Also, only accept ports that fit into 16 bits
for Open Flow 1.0.

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* No change

v9
* Manual Rebase

v8
* Omitted

v7
* Omitted

v6
* No change

v5
* Initial post
ofp-util: Pass vconn to fetch_port_by_features()

Pass vconn to fetch_port_by_features() and callers.
In some cases this will reduce the number of connections
that ovs-ofputil sets up.

It should not alter the behaviour of ovs-ofputil.

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* No change

v9
* Manual rebase

v8
* Omitted

v7
* Omitted

v6
* No change

v5
* Initial post
ofp-util: Allow encoding of Open Flow 1.1 & 1.2 Port Statistics Reply Messages

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* No change

v9
* Move print test to "ofp-print: Allow printing of Open Flow 1.1 & 1.2 Port
  Reply Messages"

v8
* Manual rebase
* Make use of enum ofp_version
* Add ofp-print test

v7
* Omitted

v6
* No change

v5
* No change

v4
* Initial post

fix port test
ofp-print: Allow printing of Open Flow 1.1 & 1.2 Port Reply Messages

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* No change

v9
* Make use of enum ofp_version
* Add ofp-print test
* Correct printing of port number for Open Flow 1.0
* Replace UINT64_MAX with htonll(UINT64_MAX) in ofp_print_port_stat()
  to correct byte-order problem detected by sparse

v8
* Omitted

v7
* Omitted

v6
* No change

v5
* Initial Post
ofp-util: Allow decoding of Open Flow 1.1 & 1.2 Port Status Request Messages

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* No change

v9
* Manual Rebase
* Make use of enum ofp_version

v8
* Omitted

v7
* Omitted

v6
* No change

v5
* Initial Post
ofp-print: Allow printing of Open Flow 1.1 & 1.2 Port Status Request Messages

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* No change

v9
* Manual Rebase
* Make use of enum ofp_version
* Change title from "ofp-print: Allow display of Open Flow 1.1 & 1.2 Port Status
  Request Messages" to "ofp-print: Allow printing of Open Flow 1.1 & 1.2 Port Status
  Request Messages"
* Add ofp-print test

v8
* Omitted

v7
* Omitted

v6
* No change

v5
* Initial Post
ovs-ofctl: Teach dump-ports about Open Flow 1.1 & 1.2

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* No change

v9
* Initial post
ofp-msgs: Split OFPRAW_OFPST_QUEUE_{REQUEST,REPLY}

Split OFPRAW_OFPST_QUEUE_{REQUEST,REPLY} into OpenFlow 1.0 and 1.1+
versions.

This prepares for encoding and decoding Open Flow 1.1 and 1.2 Queue Stats
Request and Reply messages.

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* Initial Post
ofp-print: Enable display of Open Flow 1.1 & 1.2 Queue Status Reply Messages

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* Make use of enum ofp_version
* Add ofp-print test

v9
* Omitted

v8
* Omitted

v7
* Omitted

v6
* No change

v5
* Initial Post
ofp-util: Allow encoding of Open Flow 1.1 & 1.2 Queue Stats Reply Messages

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* Manual rebase
* Make use of enum ofp_version

v9
* Omitted

v8
* Omitted

v7
* Omitted

v6
* No change

v5
* Initial Post
ofp-util: Allow decoding of Open Flow 1.1 & 1.2 Queue Stats Request Messages

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* Make use of enum ofp_version

v9
* Omitted

v8
* Omitted

v7
* Omitted

v6
* No change

v5
* Initial Post
ovs-print: Enable display of Open Flow 1.1 & 1.2 Queue Stats Request

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* Manual rebase
* Make use of enum ofp_version
* Change subject name from "ovs-print: Enable display of Open Flow 1.1 &
  1.2 Queue Stats Response" to "ovs-print: Enable display of Open Flow 1.1
  & 1.2 Queue Stats Request"
* Add ofp-print test
* Use ofputil_port_from_ofp11 to decode port number

v9
* Omitted

v8
* Omitted

v7
* Omitted

v6
* No change

v5
* Initial Post
ovs-ofpctl: Enable queue-stats for Open Flow 1.1 & 1.2

Signed-off-by: Simon Horman <horms@verge.net.au>

---

v12
* No change

v11
* No change

v10
* Manual rebase
* Make use of enum ofp_version

v9
* Omitted

v8
* Omitted

v7
* Omitted

v6
* The queue_id variable in do_dump_aggregate() should be uint32_t not
  uint16_t.

v5
* Initial Post