Add BuildRequires to RHEL specfile

Added a build-time dependency on openssl-devel, so you can easily build
a source RPM and then pass it into mock for building in a clean build
environment (without manually having to install the buildrequires).

Signed-off-by: Jasper Capel <jasper@capel.tv>
lib/classifier: Use a prefix tree to optimize ports wildcarding.

Using a prefix tree (aka 'trie') for transport ports matching produces
less specific (more wildcarded) datapath megaflows.

Each subtable that matches on transport ports has it's own ports trie.
This trie is consulted only after a failing lookup to determine the
number of bits that need to be unwildcarded to guarantee that any
packet that should match on any of the other rules will not match this
megaflow.

Signed-off-by: Jarno Rajahalme <jrajahalme@nicira.com>
Acked-by: Ethan Jackson <ethan@nicira.com>
bridge: Remove traces of flow-eviction-threshold.

This configuration option was shifted in 2.0, then removed in 2.1.
Remove the misleading log message.

Signed-off-by: Joe Stringer <joestringer@nicira.com>
Acked-by: Ethan Jackson <ethan@nicira.com>
cfm: Require ccm received in demand mode.

This commit adds a new requirement that cfm session must receive
at least one ccm every 100 * cfm_interval amount of time in demand
mode.  Otherwise, even if the data packets are received on the
monitored interface, the cfm session still reports "[recv]" fault.

Since the datapath flow is not purged when the userspace Open Vswitch
crashes, data packet can still be forwarded through the tunnel and
fool the remote CFM session in demand mode.  Thus, this commit can
prevent the remote CFM session from falsely declaring tunnel liveness
in this situation.

Signed-off-by: Alex Wang <alexw@nicira.com>
Acked-by: Ethan Jackson <ethan@nicira.com>
bfd: Require bfd control packet received in forwarding_if_rx mode.

This commit adds a requirement that bfd session must receive at least
one bfd control packet every 100 * bfd->cfg_min_rx amount of time in
forwarding_if_rx mode.  Otherwise, even if the data packets are received
on the monitored interface, the bfd->forwarding is still false.

Since the datapath flow is not purged when the userspace Open Vswitch
crashes, data packet can still be forwarded through the tunnel and
fool the remote BFD session in forwarding_if_rx mode.  Thus, this commit
can prevent the remote BFD session from falsely declaring tunnel liveness
in this situation.

Signed-off-by: Alex Wang <alexw@nicira.com>
Acked-by: Ethan Jackson <ethan@nicira.com>
ofproto-dpif-xlate: Fix in_port=controller case for NORMAL action

The problem mentioned by Simon Horman in the following mail.
http://openvswitch.org/pipermail/dev/2014-April/039492.html

Cc: Simon Horman <horms@verge.net.au>
Acked-by: Ben Pfaff <blp@nicira.com>
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp>
ofproto-dpif: Move recirc members from struct xlate_out to struct xlate_ctx

There does not seem to be a reason to expose
recirc members in struct xlate_out to move them
to struct xlate_ctx.

Signed-off-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Ben Pfaff <blp@nicira.com>
ofp-print: Enable printing OF1.4 version

Also fix some tests that can now properly print packets
with the new protocol version.

Signed-off-by: Alexandru Copot <alex.mihai.c@gmail.com>
Cc: Daniel Baluta <dbaluta@ixiacom.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
ofproto-dpif: Correct check_recirc comment

This is a proposed correction for what appears to be
an editing error.

Signed-off-by: Simon Horman <horms@verge.net.au>
Signed-off-by: Ben Pfaff <blp@nicira.com>
Merge pull request #1 from spil-jasper/master

Add BuildRequires to RHEL specfile
ovs-ctl: Install manpage.

It seems that it is useful to admins after all.

Reported-by: Brian Candler <b.candler@pobox.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
ovs-thread: Fix OVS_ADAPTIVE_MUTEX_INITIALIZER.

Commit 05bf6d3c62e1d (ovs-thread: Add checking for mutex and rwlock
initialization.) updated mutex and rwlock initializers to set the "where"
member to a nonnull value, but missed this one.  This commit fixes the
problem.

This does not cause real problems in practice because
OVS_ADAPTIVE_MUTEX_INITIALIZER has no existing users.

Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Jarno Rajahalme <jrajahalme@nicira.com>