cccl: A wrapper that calls visual c++ compiler.

One option to compile Open vSwitch code in windows
is to use Visual c++ compiler.

From http://cccl.sourceforge.net/ :
"cccl is a wrapper around Microsoft Visual C++'s cl.exe
and link.exe.  It converts Unix compiler parameters
into parameters understood by cl and link.  cccl's main
use is for using Unix build processes with Microsoft
compilers. Using cccl in conjunction with ports of Unix
utilities, it is possible to build many Unix packages
using MSVC, without modifying the build process."

There are couple of forks of the project in the internet.
This particular piece is copied from:
https://gitorious.org/swift/swift/source/\
cf9b391b40a9c59a620c8093d438370381949c60:autoconf/cccl

Signed-off-by: Gurucharan Shetty <gshetty@nicira.com>
Acked-by: Ben Pfaff <blp@nicira.com>
cccl: Provide '-' before the options instead of double slash.

While compiling Open vSwitch with visual c++ in
a mingw environment, I have observed that "//" before
options does not work for all the compiler options of
MSVC. Using "-" on the other hand seems to work.

Also, echo the command line options passed to
the MSVC compiler.

Signed-off-by: Gurucharan Shetty <gshetty@nicira.com>
Acked-by: Ben Pfaff <blp@nicira.com>
BUILD.Windows: Some details on the proposed build system.

Signed-off-by: Gurucharan Shetty <gshetty@nicira.com>
Acked-by: Ben Pfaff <blp@nicira.com>
ofp-actions: Make ofpacts_check() report consistency for all protocols.

Until now ofpacts_check() has been told either to enforce consistency or
not, but that means that the caller has to know exactly what protocol is
going to be in use (because some protocols require consistency to be
enforced and others don't).  This commit changes ofpacts_check() to just
rule out protocols that require enforcement when it detects
inconsistencies.

Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Jarno Rajahalme <jrajahalme@nicira.com>
FAQ: Update description of datapath flows.

They have not been exact-match only for a while.

Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Justin Pettit <jpettit@nicira.com>
FAQ: More explicitly draw attention to explanation of different flow types.

Signed-off-by: Ben Pfaff <blp@nicira.com>
Acked-by: Justin Pettit <jpettit@nicira.com>
Makefile.am: Distribute BUILD.Windows.

Fixes a build failure:
    The distribution is missing the following files:
    BUILD.Windows

CC: Gurucharan Shetty <gshetty@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
coverage: Synchronize per-thread counters less aggressively

When profiling CPU usage in situations involving high numbers of ports,
coverage_clear() was highlighted as a commonly called function. It
appears that it can be quite expensive to access all of the per-thread
coverage counters when threads are constantly waking up.

This patch makes each thread only do coverage_clear() logic roughly once
per second by introducing per-thread timers. Upcall handler counters may
become less accurate, as these threads may sleep without synchronising
and not wake up for some time. When the main thread is under load at
~90% CPU, this drops to ~85%. Upcall handler threads sitting at ~2.5%
drop to ~1.5%.

Signed-off-by: Joe Stringer <joestringer@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
bfd: Add forwarding flag to struct bfd.

This commit adds a forwarding flag to "struct bfd".  This flag
is for indicating the interface's capability of packet I/O.
Also, this flag makes it possible to count the number of interface
state flapping.  bfd_forwarding__() will update this flag at
each invocation.

Signed-off-by: Alex Wang <alexw@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
bfd: Add new key "flap_count" to "bfd_status".

This commit adds a new key "flap_count" to "bfd_status" to count
the number of bfd "forwarding" flag flaps.  A flap is considered
as a change of the "forwarding" flag value.

Signed-off-by: Alex Wang <alexw@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
ipfix: fix segfault for Flow_Sample_Collector_Set without ipfix

Guard any access to an IPFIX row referenced from
Flow_Sample_Collector_Set by a test that the reference is not NULL.

Signed-off-by: Romain Lenglet <rlenglet@vmware.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
ipfix: allow empty targets column in table IPFIX

The "targets" column in IPFIX had a min=1 constraints, so OVSDB
implicitly adds an empty string "" into that column if no value is
given.  No connection can be opened to a target with address "", so
the whole IPFIX exporter for that row was disabled until that ""
target was removed by users.  That behavior is correct but proved to
be unintuitive to users.

This patch removes the min=1 constraint, to avoid the trouble for
users who insert IPFIX rows with no targets: it eliminates the log
messages due to failed connections to target "", and eliminates the
need to manually remove the "" target after row insertion.

This doesn't impact the behavior for any existing row, whether it has
a "" target or not.

Signed-off-by: Romain Lenglet <rlenglet@vmware.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>