[ovs-git] [openvswitch/ovs] 117d72: types: Change ofp_port_t from uint16_t to uint32_t...

GitHub noreply at github.com
Fri Jun 3 20:18:41 UTC 2016


  Branch: refs/heads/master
  Home:   https://github.com/openvswitch/ovs
  Commit: 117d72495467efaa3eb7e7e4f7d110cd1223b967
      https://github.com/openvswitch/ovs/commit/117d72495467efaa3eb7e7e4f7d110cd1223b967
  Author: Ben Pfaff <blp at ovn.org>
  Date:   2016-06-03 (Fri, 03 Jun 2016)

  Changed paths:
    M include/openvswitch/flow.h
    M include/openvswitch/types.h
    M lib/ofp-actions.c
    M utilities/ovs-ofctl.c

  Log Message:
  -----------
  types: Change ofp_port_t from uint16_t to uint32_t.

This fixes several tests that failed on big-endian systems because "union
flow_in_port" overlays an ofp_port_t and odp_port_t and in some cases it
is not easy to determine which one is in use.

This commit also fixes up a few places where this broke other code.

Signed-off-by: Ben Pfaff <blp at ovn.org>
Acked-by: Aaron Conole <aconole at redhat.com>
Acked-by: Gerhard Stenzel <gstenzel at linux.vnet.ibm.com>


  Commit: 3d75c66007c88f886864df02b86afaa3a440088a
      https://github.com/openvswitch/ovs/commit/3d75c66007c88f886864df02b86afaa3a440088a
  Author: Ben Pfaff <blp at ovn.org>
  Date:   2016-06-03 (Fri, 03 Jun 2016)

  Changed paths:
    M lib/byte-order.h
    M lib/netdev-native-tnl.c

  Log Message:
  -----------
  netdev-native-tnl: Fix treatment of GRE key on big-endian systems.

The GRE implementation used bitwise shifts to convert an ovs_be32 to an
ovs_be64 (with zero extension), but on big-endian systems these conversions
are no-ops.  This fixes the problem.

Signed-off-by: Ben Pfaff <blp at ovn.org>
Acked-by: Aaron Conole <aconole at redhat.com>
Acked-by: Gerhard Stenzel <gstenzel at linux.vnet.ibm.com>


  Commit: a28239c009bcb3389c036e4ebafe7c2dc3502c7f
      https://github.com/openvswitch/ovs/commit/a28239c009bcb3389c036e4ebafe7c2dc3502c7f
  Author: Ben Pfaff <blp at ovn.org>
  Date:   2016-06-03 (Fri, 03 Jun 2016)

  Changed paths:
    M lib/ofp-print.c
    M tests/ofp-print.at
    M tests/ofproto.at

  Log Message:
  -----------
  ofp-print: Sort queues before printing in OFPT_QUEUE_GET_CONFIG_REPLY.

Otherwise the ordering tends to vary across endianness.

Signed-off-by: Ben Pfaff <blp at ovn.org>
Acked-by: Aaron Conole <aconole at redhat.com>
Acked-by: Gerhard Stenzel <gstenzel at linux.vnet.ibm.com>


  Commit: 3a6e67fa5267eed92e351b8da2eb68d0ba71df41
      https://github.com/openvswitch/ovs/commit/3a6e67fa5267eed92e351b8da2eb68d0ba71df41
  Author: Ben Pfaff <blp at ovn.org>
  Date:   2016-06-03 (Fri, 03 Jun 2016)

  Changed paths:
    M tests/ofproto-dpif.at

  Log Message:
  -----------
  tests: Fix select group test on big-endian systems.

This test ensures that, when the selection criteria for a select group are
the same from packet to packet, the same bucket is always selected.
However, it hardcoded the bucket that was selected to the one that happens
to be selected with the current OVS hash function on little-endian systems.
On big-endian systems, the current OVS hash functions turns out to select
the other bucket.  That's fine (it's consistent, it just consistently makes
the other choice), so this commit fixes the problem by allowing either
bucket to be selected.

Signed-off-by: Ben Pfaff <blp at ovn.org>
Acked-by: Aaron Conole <aconole at redhat.com>
Acked-by: Gerhard Stenzel <gstenzel at linux.vnet.ibm.com>


  Commit: 961cf8e090ec977f890df3da1b65b7d94d218cbe
      https://github.com/openvswitch/ovs/commit/961cf8e090ec977f890df3da1b65b7d94d218cbe
  Author: Ben Pfaff <blp at ovn.org>
  Date:   2016-06-03 (Fri, 03 Jun 2016)

  Changed paths:
    M tests/ofproto-dpif.at

  Log Message:
  -----------
  tests: Avoid endianness sensitivity in MPLS handling test.

The test "ofproto-dpif - MPLS handling" included a test of the "multipath"
action whose results depended on the hash function in use.  The OVS hash
function yields different results on little-endian and big-endian systems,
so this caused a failure.

This commit fixes the problem by changing the modulus in the multipath
action from 256 to 1; any (nonnegative) value modulo 1 is 0, so this makes
the results consistent across endianness (and across hash function
changes).  I think that this is still a good enough test.

Signed-off-by: Ben Pfaff <blp at ovn.org>
Acked-by: Aaron Conole <aconole at redhat.com>
Acked-by: Gerhard Stenzel <gstenzel at linux.vnet.ibm.com>


Compare: https://github.com/openvswitch/ovs/compare/b5936d520b50...961cf8e090ec


More information about the git mailing list