aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2012-06-25Update dates for 1.6.1 release.v1.6.1Justin Pettit
Signed-off-by: Justin Pettit <jpettit@nicira.com>
2012-06-25ofp-util: Avoid use-after-free in ofputil_encode_flow_mod().Ben Pfaff
nx_put_match() can reallocate the ofpbuf's data so we need to reload the pointer. Found by inspection. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-06-19debian: Make DKMS automatically build for running kernel.Ben Pfaff
By default DKMS doesn't build on demand for each kernel booted or updated. Adding AUTOINSTALL=yes gives it this behavior. Based on a small sample of Debian packages and how-to guides for Ubuntu, AUTOINSTALL=yes is what most packages use and what users expect. Fix-suggested-by: Kirill Kabardin Reported-by: Ralf Heiringhoff <ralf@frosty-geek.net> Reported-at: https://bugs.launchpad.net/bugs/962189 Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-06-14Declare the version as "1.6.1".Justin Pettit
Signed-off-by: Justin Pettit <jpettit@nicira.com>
2012-06-13vlog: Avoid use-after-free in corner case.Ben Pfaff
Found by valgrind. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-06-12datapath: Check currect return value from skb_gso_segment()Pravin B Shelar
Fix return check typo. Signed-off-by: Pravin B Shelar <pshelar@nicira.com> Acked-by: Jesse Gross <jesse@nicira.com> Bug #11933
2012-06-07datapath: Fix use-after-free bug in dp_notify.Pravin B Shelar
dp_notify, in unregister case, is accessing vport after detaching it. Following patch fixes it. Signed-off-by: Pravin B Shelar <pshelar@nicira.com> Acked-by: Jesse Gross <jesse@nicira.com>
2012-06-07ofproto: Fix use after free in ofoperation_complete().Ethan Jackson
In one edge case, ofoperation_complete() destroys its rule, without updating its ofoperation that the rule is gone. Later in the same function, ofoperation_destroy() attempts to modify the rule which already destroyed. Bug #11797. Signed-off-by: Ethan Jackson <ethan@nicira.com>
2012-06-04Set dates for release of 1.5.0.Justin Pettit
Signed-off-by: Justin Pettit <jpettit@nicira.com>
2012-06-04NEWS: Move learning timeout changes to 1.5.0 section.Justin Pettit
Changes to the default MAC learning timeout and making it configurable were added in 1.5.0, not 1.6.0. Signed-off-by: Justin Pettit <jpettit@nicira.com>
2012-05-29ofp-util: Clean up cookie handling.Justin Pettit
Commit e72e793 (Add ability to restrict flow mods and flow stats requests to cookies.) modified cookie handling. Some of its behavior was unintuitive and there was at least one bug (described below). Commit f66b87d (DESIGN: Document uses for flow cookies.) attempted to document a clean design for cookie handling. This commit updates the DESIGN document and brings the implementation in line with it. In commit e72e793, the code that handled processing OpenFlow flow modification requests set the cookie mask to exact-match. This seems reasonable for adding flows, but is not correct for matching, since OpenFlow 1.0 doesn't support matching based on the cookie. This commit changes to cookie mask to fully wildcarded, which is the correct behavior for modifications and deletions. It doesn't cause any problems for flow additions, since the mask is ignored for that operation. Bug #9742 Reported-by: Luca Giraudo <lgiraudo@nicira.com> Reported-by: Paul Ingram <paul@nicira.com> Signed-off-by: Justin Pettit <jpettit@nicira.com>
2012-05-25ofproto-dpif: Fix CONTROLLER actions for LLC frames.Ethan Jackson
The CONTROLLER action assumed that all Ethernet frames stored their Ethernet Type in the two bytes succeeding the source and destination addresses. This turns out not to be true for 802.2 LLC frames, potentially causing an assertion failure. This patch solves the issue by skipping the assertion in this case. Bug #10349. Signed-off-by: Ethan Jackson <ethan@nicira.com>
2012-05-21bridge: Ignore "null" interfaces as required.Ethan Jackson
Commit bae7208e91a0 (bridge: Refactor bridge_reconfigure().) introduced a regression in which the switch would attempt to instantiate "null" interfaces in the datapath. This would, of course, fail and trigger a warning. Though harmless, these warnings confused users. Signed-off-by: Ethan Jackson <ethan@nicira.com>
2012-05-22Fix typo in "PYTHONPATH".Ben Pfaff
Reported-by: Justin Pettit <jpettit@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-05-17datapath: Reset upper layer protocol info on internal devices.Jesse Gross
It's possible that packets that are sent on internal devices (from the OVS perspective) have already traversed the local IP stack. After they go through the internal device, they will again travel through the IP stack which may get confused by the presence of existing information in the skb. The problem can be observed when switching between namespaces. This clears out that information to avoid problems but deliberately leaves other metadata alone. This is to provide maximum flexibility in chaining together OVS and other Linux components. Bug #10995 Signed-off-by: Jesse Gross <jesse@nicira.com> Acked-by: Ben Pfaff <blp@nicira.com>
2012-05-16odp-util: Update ODPUTIL_FLOW_KEY_BYTES for current kernel flow format.Ben Pfaff
Before we submitted the kernel module upstream, we updated the flow format by adding two fields to the description of packets with VLAN headers, but we forgot to update ODPUTIL_FLOW_KEY_BYTES to reflect these changes. The result was that a maximum-length flow did not fit in the given space. This fixes a crash processing IPv6 neighbor discovery packets with VLAN headers received in a tunnel configured with key=flow or in_key=flow. This updates some comments to better describe the implications of ODPUTIL_FLOW_KEY_BYTES (suggested by Justin). This also updates test-odp.c so that it would have caught this problem, and updates odp.at to demonstrate that a full 156 bytes are necessary. (To see that, revert the change to ODPUTIL_FLOW_KEY_BYTES and run the test.) Reported-by: Dan Wendlandt <dan@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-05-16dpif-netdev: allow for proper destruction of netdev datapathsGiuseppe Lettieri
Until now, bridges with datapath_type=netdev did not destroy the datapath when deleted. In particular, the tap device implementing the internal interface was not close()d, and therefore the tap persists until ovs-vswitchd exit()s. This behaviour was caused by the missing callback for 'enumerate' in the dpif-netdev class. Without this callback 'bridge_reconfigure' failed to realize that there are datapaths with no bridge, and thus cannot destroy them. Providing an 'enumerate' callback fixes this. Signed-off-by: Giuseppe Lettieri <g.lettieri@iet.unipi.it> Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-05-14ofp-util: Treat a packet-out in_port of OFPP_CONTROLLER as OFPP_NONE.Ben Pfaff
Some OpenFlow 1.0 controllers incorrectly use OPFP_CONTROLLER as the in_port in packet-out messages, when OFPP_NONE is their intent. Until now, Open vSwitch has rejected such requests with an error message. This commit makes Open vSwitch instead treat OFPP_CONTROLLER the same as OFPP_NONE for compatibility with those controllers. (Also, as of this writing, OpenFlow 1.0.1 appears to be changing the port to use from OFPP_NONE to OFPP_CONTROLLER.) Suggested-by: Rob Sherwood <rob.sherwood@bigswitch.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-05-10odp-util: Fix parsing of actions encapsulated within "sample" actions.Ben Pfaff
Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-05-09rhel: Add timeouts to network scripts.Brian Kruger
If the daemon(s) aren't running for whatever reason, the RHEL ovs ifup/ifdown scripts don't take that into account and an attempt to reboot a system could take forever. (literally. endless loop!) Here are a couple of patches (one of ifup, one for ifdown) to add timeouts (10 seconds), because it runs per interface you have configured and that could take awhile to reboot a system if needed. Signed-off-by: Brian Kruger <bkruger+ovsdev@gmail.com> [blp@nicira.com fixed up a conflict against master] Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-05-08datapath: Validation of IPv6 set port action uses IPv4 headerPravin B Shelar
When the kernel validates set TCP/UDP port actions, it looks at the ports in the existing flow to make sure that the L4 header exists. However, these actions always use the IPv4 version of the struct. Following patch fixes this by checking for flow ip protocol first. Signed-off-by: Pravin B Shelar <pshelar@nicira.com> Acked-by: Jesse Gross <jesse@nicira.com> Bug #11205
2012-05-02ofproto: Don't allow feature reply to overflow max OpenFlow message size.Ben Pfaff
An OpenFlow message is limited to 65535 bytes so if there are more than (65535 - sizeof(struct ofp_switch_features)) / sizeof(struct ofp_phy_port) == 1364 ports then the feature reply cannot hold them all. This commit prevents the feature reply from overflowing, at the cost of only reporting a random sampling of ports. Bug #11087. Reported-by: Michael Mao <mmao@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-27meta-flow: Correctly set destination MAC in mf_set_flow_value().Ben Pfaff
Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-25Fix memory leaks.Ben Pfaff
Found by valgrind. Reported-by: Ethan Jackson <ethan@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-24vswitchd: Avoid GCC warning.Ben Pfaff
GCC 4.4.5 issues the following warning without this patch: bridge.c: In function ‘bridge_run’: bridge.c:2032: error: ‘database_changed’ may be used uninitialized in this function I think it's unnecessary, but it doesn't hurt to always initialize this variable. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-24vswitchd: Clean up iface_create().Ben Pfaff
iface_create() did its work in an order that meant it had to do a lot more cleanup on error paths than is otherwise needed. This commit reorders the work to avoid this extra cleanup. bridge_ofproto_port_del() is no longer used after the refactoring so this commit deletes it. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-24vswitchd: Make reconfiguration update port configuration again.Ben Pfaff
Commit bae7208e91a0 (bridge: Refactor bridge_reconfigure().) introduced a regression in bridge reconfiguration. Previously, reconfiguration would update the configuration of each bridge port, so that if the controller (or the admin) changed a port's options, then that change would propagate to the datapath. Following that commit, that no longer happened. This commit restores that feature. Bug #10972. Reported-by: Michael Hu <mhu@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-24vswitchd: Make iface_create() return an indication of success.Ben Pfaff
This is the minimal change that gets the job done. There are much nicer ways to do this, but I'll leave that refactoring for later in the series. The return value will have its first user in an upcoming commit. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-24vswitchd: Factor code to configure netdevs out of iface_create().Ben Pfaff
An upcoming patch will need the same code in another function. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-24vswitchd: Refactor iface_refresh_type() into iface_get_type().Ben Pfaff
The calculation that this function does will need to be used in a context where no "struct iface" is available in an upcoming commit. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-24vswitchd: Drop 'need_refresh' member from struct iface.Ben Pfaff
It's no longer useful. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-24vswitchd: Push ofproto_port declaration down to inner blocks.Ben Pfaff
Just a tiny code cleanup. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-24vswitchd: Report actual port number, not -1, in "added interface" message.Ben Pfaff
CC: Ethan Jackson <ethan@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-23bridge: Refactor bridge_reconfigure().Ethan Jackson
The existing bridge_reconfigure() implementation is suboptimal. When adding lots of new ports, on every pass through the run loop it allocates a bunch of "struct iface"s and "struct port"s, only to destroy them when out of time. Additionally, when there are errors adding or deleting ports, it can fail to converge. Instead it will attempt and fail to add the same set of ports forever. This patch rewrites bridge_reconfigure() using a new strategy. Whenever the database changes, some initial bookkeeping is done, and a list of future work is compiled. The bridge begins whittling down this list, and stops processing database changes until finished. Bug #10902. Signed-off-by: Ethan Jackson <ethan@nicira.com>
2012-04-23vswitchd: Remove unused 'tag' from 'struct iface'.Ethan Jackson
Signed-off-by: Ethan Jackson <ethan@nicira.com>
2012-04-23ofproto: Fix use-after-free error when ports disappear.Ben Pfaff
update_port() can delete the port for which it is called, if the underlying network device has been destroyed, so HMAP_FOR_EACH is unsafe in ofproto_run(). Less obviously, update_port() can delete unrelated ports. For example, suppose that initially device A is port 1 and device B is port 2. If update_port("A") runs just after this, then it will ofport_remove() both ports, then ofport_install() A as the new port 2. So this commit first assembles a list of ports to update, then updates them in a separate loop. Without this commit, running "ovs-dpctl del-dp" while ovs-vswitchd is running consistently causes a crash for me within a few seconds. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-20vswitchd: Make "cfm_fault_status" column ephemeral.Ben Pfaff
There's no need to log this to the on-disk database. Spotted while examining "ovsdb-tool show-log" output. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-12stream: By default disable probing on unix sockets.Ethan Jackson
There isn't a lot of value in sending inactivity probes on unix sockets. This patch changes the default to disable them. Signed-off-by: Ethan Jackson <ethan@nicira.com>
2012-04-12python: Honor zero probe interval in reconnect.pyEthan Jackson
The python reconnect library attempted to send a probe every 0 milliseconds instead of disabling probing when the probe_interval was zero. Signed-off-by: Ethan Jackson <ethan@nicira.com>
2012-04-13learn: Make it possible to parse "load" actions wider than 64 bits.Ben Pfaff
The implementation of the "learn" action now properly implements specifications such as 0x20010db885a308d313198a2e03707348->NXM_NX_IPV6_DST but the parser used in ovs-ofctl and elsewhere could not generate such specifications. This commit adds that support. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-13learn: Fix bugs when learn actions use subfields wider than 64 bits.Ben Pfaff
Bug #10576. Reported-by: James Schmidt <jschmidt@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-13meta-flow: New functions for reading and writing generalized subfields.Ben Pfaff
The existing functions for reading and writing the values of subfields only handle subfields up to 64 bits wide. These new functions handle subfields of any width. Also update some existing comments. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-13util: New function bitwise_is_all_zeros().Ben Pfaff
Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-13util: New function bitwise_one().Ben Pfaff
It's the obvious counterpart to bitwise_zero(). Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-04-11bridge: Rate limit port creations and deletions.Ethan Jackson
In some datapaths, adding or deleting OpenFlow ports can take quite a bit of time. If there are lots of OpenFlow ports which needed to be added in a run loop, this can cause Open vSwitch to lock up and stop setting up flows while trying to catch up. This patch lessons the severity of the problem by only doing a few OpenFlow port adds or deletions per run loop allowing other work to be done in between. Bug #10672. Signed-off-by: Ethan Jackson <ethan@nicira.com>
2012-04-11bridge: Rate limit default address warnings.Ethan Jackson
This information is typically not more useful if displayed more often. Signed-off-by: Ethan Jackson <ethan@nicira.com>
2012-04-09vswitchd: Remove port from datapath if it becomes non-operationalAnsis Atteka
If kernel module rejects config changes then vswitchd sets the ofport column to -1, but does not remove the non-operational port from the datapath. This patch fixes this problem. ovs-vsctl add-br ovsbr ovs-vsctl add-port ovsbr p1 ovs-vsctl add-port ovsbr p2 ovs-vsctl set Interface p1 options:remote_ip=2.1.1.1 options:key=123 type=gre ovs-vsctl set Interface p2 options:remote_ip=1.1.1.1 options:key=123 type=gre ovs-vsctl set Interface p2 options:remote_ip=2.1.1.1 options:key=123 type=gre ovs-dpctl show #observe that p2 does not appear here anymore Signed-off-by: Ansis Atteka <aatteka@nicira.com>
2012-04-09datapath: Do not send notification if ovs_vport_set_options() failedAnsis Atteka
There is no need to send a notification if ovs_vport_set_options() failed and ovs_vport_cmd_set() did not change anything. Issue#10285 Acked-by: Jesse Gross <jesse@nicira.com> Signed-off-by: Ansis Atteka <aatteka@nicira.com>
2012-03-28ovsdb-idl: Fix memory leak writing synthetic rows in ovsdb_idl_txn_write().Ben Pfaff
This could cause a slow but steady memory leak in ovs-vswitchd. Found by valgrind. Signed-off-by: Ben Pfaff <blp@nicira.com>
2012-03-26packet: Add additional TCP flags extraction on IPv6.Jesse Gross
Commit 11460e2316b88f0bd0ea0005d94338d800ea16bd (flow: Enable retrieval of TCP flags from IPv6 traffic.) updated one of the TCP flags extraction functions in userspace but missed the other. This updates that function and converts the other to use it to reduce duplication. Bug #10194 Signed-off-by: Jesse Gross <jesse@nicira.com>