aboutsummaryrefslogtreecommitdiff
path: root/lib/vconn-provider.h
AgeCommit message (Collapse)Author
2013-05-03vconn: Mark class structures as const.Ben Pfaff
These data structures are never modified so it seems logical for them to be const. Signed-off-by: Ben Pfaff <blp@nicira.com>
2013-01-24rconn: Fix null pointer dereference in rconn_add_monitor().Ben Pfaff
rconn_add_monitor() tries to check the version of the controller connection being monitored, so that it can decide what OpenFlow version to tell the monitor connection to negotiate. But at any given time an rconn may not have a controller connection (e.g. during backoff), so rc->vconn may be null and thus vconn_get_version(rc->vconn) dereferences a null pointer. Fixing the problem in a local way would require the rconn to remember the previous version negotiated, and that fails if the rconn hasn't yet connected or if the next connection negotiates a new version. This commit instead adds the ability to a vconn to accept any OpenFlow message version and modifies "ovs-ofctl snoop" to use that feature, thus removing the need to negotiate the "correct" version on snoops. Bug #14265. Reported-by: Pratap Reddy <preddy@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com> Acked-by: Ethan Jackson <ethan@nicira.com>
2013-01-16Replace most uses of assert by ovs_assert.Ben Pfaff
This is a straight search-and-replace, except that I also removed #include <assert.h> from each file where there were no assert calls left. Signed-off-by: Ben Pfaff <blp@nicira.com> Acked-by: Ethan Jackson <ethan@nicira.com>
2012-11-04vconn: Replace minimum version with bitmap of allowed versions.Simon Horman
This is in preparation for allowing the range of allowed OpenFlow versions to be configured. As part of this change pvconn_open() is now paramatised over the allowed versions. this is to avoid avoids needing to provide version information as a parameter to pvconn_accept(). This will in turn avoid the need to pass version information to connmgr_run(). Signed-off-by: Simon Horman <horms@verge.net.au> [blp@nicira.com simplified slightly and generalize log messages] Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-07-30openflow: Add enum ofp_versionSimon Horman
Use an enum for ofp_version in ofp-util and ofp-msg. This in conjunction with the use of switch() statements allows the compiler to warn when a new ofp_version isn't handled. Signed-off-by: Simon Horman <horms@verge.net.au> Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-05-02Global replace of Nicira Networks.Raju Subramanian
Replaced all instances of Nicira Networks(, Inc) to Nicira, Inc. Feature #10593 Signed-off-by: Raju Subramanian <rsubramanian@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-17socket-util: Remove DSCP_INVALID.Ethan Jackson
The DSCP_INVALID flag allowed callers to prevent socket-util from modify the DSCP bits of newly created sockets. However, the two really important callers (implementations of the controller and manager tables) never used it. Furthermore, the other callers would be fine always setting the DSCP bits to zero. This patch removes the DSCP_INVALID option in an effort to simplify the code. Signed-off-by: Ethan Jackson <ethan@nicira.com>
2012-03-23Allow configuring DSCP on controller and manager connections.Mehak Mahajan
The changes allow the user to specify a separate dscp value for the controller connection and the manager connection. The value will take effect on resetting the connections. If no value is specified a default value of 192 is chosen for each of the connections. Feature #10074 Requested-by: Rajiv Ramanathan <rramanathan@nicira.com> Signed-off-by: Mehak Mahajan <mmahajan@nicira.com>
2010-11-29Convert stream and vconn interfaces to use ovs_be16, ovs_be32.Ben Pfaff
2010-01-06vconn: Convert vconn code to modern OVS structure.Ben Pfaff
The vconn code is a relative fossil as OVS code goes. It was written before we had really figured how code should fit together. Part of that history is that it used poll_fd_callback() to register callbacks without the assistance of other code. That isn't how the rest of OVS works now; this code is the only remaining user of that function. To make it more like the rest of the system, this code gets rid of the use of poll_fd_callback(). It also adds vconn_run() and vconn_run_wait() functions and calls to them from the places where they are now required.
2009-09-21vconn: Remove unused "reconnectable" member from vconn.Ben Pfaff
This member is initialized, but nothing ever reads it, so get rid of it.
2009-07-13vconn: Fix detection of vconn local IP address, to fix in-band control.Ben Pfaff
The in-band control code needs to know the IP and port of both ends of the control connection. However, the vconn code was only reporting the local address after the connection had already succeeded, which created a chicken-and-egg problem. In practice we would fail to connect until the switch went into fail-open, at which point the connection would go through. Fortunately, we can get the local IP address right after we try to connect, not just after the connection completes, so this commit changes the code to do that. This commit also breaks setting the remote IP and port into functions separate from vconn_init(), which makes the code more readable.
2009-07-08Have rconn and vconn export information about IPs and portsJustin Pettit
Previously, rconn and vconn only allowed users to find out about the remote IP address. This set of changes allows users to retrieve the remote port, local IP, and local port used for the connection.
2009-06-15Update primary code license to Apache 2.0.Ben Pfaff
2009-07-08Import from old repository commit 61ef2b42a9c4ba8e1600f15bb0236765edc2ad45.v0.90.0Ben Pfaff