<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/net/openvswitch, branch v4.0</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v4.0</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v4.0'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2015-03-31T19:59:50Z</updated>
<entry>
<title>openvswitch: Return vport module ref before destruction</title>
<updated>2015-03-31T19:59:50Z</updated>
<author>
<name>Thomas Graf</name>
<email>tgraf@suug.ch</email>
</author>
<published>2015-03-30T11:57:41Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=fa2d8ff4e3522b4e05f590575d3eb8087f3a8cdc'/>
<id>urn:sha1:fa2d8ff4e3522b4e05f590575d3eb8087f3a8cdc</id>
<content type='text'>
Return module reference before invoking the respective vport
-&gt;destroy() function. This is needed as ovs_vport_del() is not
invoked inside an RCU read side critical section so the kfree
can occur immediately before returning to ovs_vport_del().

Returning the module reference before -&gt;destroy() is safe because
the module unregistration is blocked on ovs_lock which we hold
while destroying the datapath.

Fixes: 62b9c8d0372d ("ovs: Turn vports with dependencies into separate modules")
Reported-by: Pravin Shelar &lt;pshelar@nicira.com&gt;
Signed-off-by: Thomas Graf &lt;tgraf@suug.ch&gt;
Acked-by: Pravin B Shelar &lt;pshelar@nicira.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>openvswitch: Fix serialization of non-masked set actions.</title>
<updated>2015-03-03T19:38:57Z</updated>
<author>
<name>Joe Stringer</name>
<email>joestringer@nicira.com</email>
</author>
<published>2015-03-03T02:49:56Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=f4f8e73850589008095b1da3c8c17cf68bd1c62a'/>
<id>urn:sha1:f4f8e73850589008095b1da3c8c17cf68bd1c62a</id>
<content type='text'>
Set actions consist of a regular OVS_KEY_ATTR_* attribute nested inside
of a OVS_ACTION_ATTR_SET action attribute. When converting masked actions
back to regular set actions, the inner attribute length was not changed,
ie, double the length being serialized. This patch fixes the bug.

Fixes: 83d2b9b ("net: openvswitch: Support masked set actions.")
Signed-off-by: Joe Stringer &lt;joestringer@nicira.com&gt;
Acked-by: Jarno Rajahalme &lt;jrajahalme@nicira.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>openvswitch: Fix net exit.</title>
<updated>2015-02-20T20:32:08Z</updated>
<author>
<name>Pravin B Shelar</name>
<email>pshelar@nicira.com</email>
</author>
<published>2015-02-17T19:23:10Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=7b4577a9da3702049650f7095506e9afd9f68849'/>
<id>urn:sha1:7b4577a9da3702049650f7095506e9afd9f68849</id>
<content type='text'>
Open vSwitch allows moving internal vport to different namespace
while still connected to the bridge. But when namespace deleted
OVS does not detach these vports, that results in dangling
pointer to netdevice which causes kernel panic as follows.
This issue is fixed by detaching all ovs ports from the deleted
namespace at net-exit.

BUG: unable to handle kernel NULL pointer dereference at 0000000000000028
IP: [&lt;ffffffffa0aadaa5&gt;] ovs_vport_locate+0x35/0x80 [openvswitch]
Oops: 0000 [#1] SMP
Call Trace:
 [&lt;ffffffffa0aa6391&gt;] lookup_vport+0x21/0xd0 [openvswitch]
 [&lt;ffffffffa0aa65f9&gt;] ovs_vport_cmd_get+0x59/0xf0 [openvswitch]
 [&lt;ffffffff8167e07c&gt;] genl_family_rcv_msg+0x1bc/0x3e0
 [&lt;ffffffff8167e319&gt;] genl_rcv_msg+0x79/0xc0
 [&lt;ffffffff8167d919&gt;] netlink_rcv_skb+0xb9/0xe0
 [&lt;ffffffff8167deac&gt;] genl_rcv+0x2c/0x40
 [&lt;ffffffff8167cffd&gt;] netlink_unicast+0x12d/0x1c0
 [&lt;ffffffff8167d3da&gt;] netlink_sendmsg+0x34a/0x6b0
 [&lt;ffffffff8162e140&gt;] sock_sendmsg+0xa0/0xe0
 [&lt;ffffffff8162e5e8&gt;] ___sys_sendmsg+0x408/0x420
 [&lt;ffffffff8162f541&gt;] __sys_sendmsg+0x51/0x90
 [&lt;ffffffff8162f592&gt;] SyS_sendmsg+0x12/0x20
 [&lt;ffffffff81764ee9&gt;] system_call_fastpath+0x12/0x17

Reported-by: Assaf Muller &lt;amuller@redhat.com&gt;
Fixes: 46df7b81454("openvswitch: Add support for network namespaces.")
Signed-off-by: Pravin B Shelar &lt;pshelar@nicira.com&gt;
Reviewed-by: Thomas Graf &lt;tgraf@noironetworks.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>openvswitch: Fix key serialization.</title>
<updated>2015-02-15T04:20:40Z</updated>
<author>
<name>Pravin B Shelar</name>
<email>pshelar@nicira.com</email>
</author>
<published>2015-02-12T17:58:48Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=26ad0b83587fb6e9a20eef388b0587ada3da5d06'/>
<id>urn:sha1:26ad0b83587fb6e9a20eef388b0587ada3da5d06</id>
<content type='text'>
Fix typo where mask is used rather than key.

Fixes: 74ed7ab9264("openvswitch: Add support for unique flow IDs.")
Reported-by: Joe Stringer &lt;joestringer@nicira.com&gt;
Signed-off-by: Pravin B Shelar &lt;pshelar@nicira.com&gt;
Acked-by: Joe Stringer &lt;joestringer@nicira.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>openvswitch: Add missing initialization in validate_and_copy_set_tun()</title>
<updated>2015-02-11T22:40:15Z</updated>
<author>
<name>Geert Uytterhoeven</name>
<email>geert@linux-m68k.org</email>
</author>
<published>2015-02-11T10:23:38Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=13101602c4a9f653d59af9469040797bc5b361ca'/>
<id>urn:sha1:13101602c4a9f653d59af9469040797bc5b361ca</id>
<content type='text'>
net/openvswitch/flow_netlink.c: In function ‘validate_and_copy_set_tun’:
net/openvswitch/flow_netlink.c:1749: warning: ‘err’ may be used uninitialized in this function

If ipv4_tun_from_nlattr() returns a different positive value than
OVS_TUNNEL_KEY_ATTR_GENEVE_OPTS, err will be uninitialized, and
validate_and_copy_set_tun() may return an undefined value instead of a
zero success indicator. Initialize err to zero to fix this.

Fixes: 1dd144cf5b4b47e1 ("openvswitch: Support VXLAN Group Policy extension")
Signed-off-by: Geert Uytterhoeven &lt;geert@linux-m68k.org&gt;
Acked-by: Thomas Graf &lt;tgraf@suug.ch&gt;
Acked-by: Pravin B Shelar &lt;pshelar@nicira.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>openvswitch: Reset key metadata for packet execution.</title>
<updated>2015-02-11T22:40:15Z</updated>
<author>
<name>Pravin B Shelar</name>
<email>pshelar@nicira.com</email>
</author>
<published>2015-02-10T21:35:16Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=b35725a285768d85b5ba1be7fe5002654a65ce88'/>
<id>urn:sha1:b35725a285768d85b5ba1be7fe5002654a65ce88</id>
<content type='text'>
Userspace packet execute command pass down flow key for given
packet. But userspace can skip some parameter with zero value.
Therefore kernel needs to initialize key metadata to zero.

Fixes: 0714812134 ("openvswitch: Eliminate memset() from flow_extract.")
Signed-off-by: Pravin B Shelar &lt;pshelar@nicira.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>openvswitch: Only set TUNNEL_VXLAN_OPT if VXLAN-GBP metadata is set</title>
<updated>2015-02-09T22:25:52Z</updated>
<author>
<name>Thomas Graf</name>
<email>tgraf@suug.ch</email>
</author>
<published>2015-02-09T15:56:37Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=fd3137cd33ae5590c45c81e9a46fe53b6ab5f66e'/>
<id>urn:sha1:fd3137cd33ae5590c45c81e9a46fe53b6ab5f66e</id>
<content type='text'>
This avoids setting TUNNEL_VXLAN_OPT for VXLAN frames which don't
have any GBP metadata set. It is not invalid to set it but unnecessary.

Signed-off-by: Thomas Graf &lt;tgraf@suug.ch&gt;
Acked-by: Pravin B Shelar &lt;pshelar@nicira.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>openvswitch: Initialize unmasked key and uid len</title>
<updated>2015-02-08T08:51:14Z</updated>
<author>
<name>Pravin B Shelar</name>
<email>pshelar@nicira.com</email>
</author>
<published>2015-02-06T19:17:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=ca539345f8767cca221b5aa77bf4329c725d0d7e'/>
<id>urn:sha1:ca539345f8767cca221b5aa77bf4329c725d0d7e</id>
<content type='text'>
Flow alloc needs to initialize unmasked key pointer. Otherwise
it can crash kernel trying to free random unmasked-key pointer.

general protection fault: 0000 [#1] SMP
3.19.0-rc6-net-next+ #457
Hardware name: Supermicro X7DWU/X7DWU, BIOS  1.1 04/30/2008
RIP: 0010:[&lt;ffffffff8111df0e&gt;] [&lt;ffffffff8111df0e&gt;] kfree+0xac/0x196
Call Trace:
 [&lt;ffffffffa060bd87&gt;] flow_free+0x21/0x59 [openvswitch]
 [&lt;ffffffffa060bde0&gt;] ovs_flow_free+0x21/0x23 [openvswitch]
 [&lt;ffffffffa0605b4a&gt;] ovs_packet_cmd_execute+0x2f3/0x35f [openvswitch]
 [&lt;ffffffffa0605995&gt;] ? ovs_packet_cmd_execute+0x13e/0x35f [openvswitch]
 [&lt;ffffffff811fe6fb&gt;] ? nla_parse+0x4f/0xec
 [&lt;ffffffff8139a2fc&gt;] genl_family_rcv_msg+0x26d/0x2c9
 [&lt;ffffffff8107620f&gt;] ? __lock_acquire+0x90e/0x9aa
 [&lt;ffffffff8139a3be&gt;] genl_rcv_msg+0x66/0x89
 [&lt;ffffffff8139a358&gt;] ? genl_family_rcv_msg+0x2c9/0x2c9
 [&lt;ffffffff81399591&gt;] netlink_rcv_skb+0x3e/0x95
 [&lt;ffffffff81399898&gt;] ? genl_rcv+0x18/0x37
 [&lt;ffffffff813998a7&gt;] genl_rcv+0x27/0x37
 [&lt;ffffffff81399033&gt;] netlink_unicast+0x103/0x191
 [&lt;ffffffff81399382&gt;] netlink_sendmsg+0x2c1/0x310
 [&lt;ffffffff811007ad&gt;] ? might_fault+0x50/0xa0
 [&lt;ffffffff8135c773&gt;] do_sock_sendmsg+0x5f/0x7a
 [&lt;ffffffff8135c799&gt;] sock_sendmsg+0xb/0xd
 [&lt;ffffffff8135cacf&gt;] ___sys_sendmsg+0x1a3/0x218
 [&lt;ffffffff8113e54b&gt;] ? get_close_on_exec+0x86/0x86
 [&lt;ffffffff8115a9d0&gt;] ? fsnotify+0x32c/0x348
 [&lt;ffffffff8115a720&gt;] ? fsnotify+0x7c/0x348
 [&lt;ffffffff8113e5f5&gt;] ? __fget+0xaa/0xbf
 [&lt;ffffffff8113e54b&gt;] ? get_close_on_exec+0x86/0x86
 [&lt;ffffffff8135cccd&gt;] __sys_sendmsg+0x3d/0x5e
 [&lt;ffffffff8135cd02&gt;] SyS_sendmsg+0x14/0x16
 [&lt;ffffffff81411852&gt;] system_call_fastpath+0x12/0x17

Fixes: 74ed7ab9264("openvswitch: Add support for unique flow IDs.")
CC: Joe Stringer &lt;joestringer@nicira.com&gt;
Reported-by: Or Gerlitz &lt;ogerlitz@mellanox.com&gt;
Signed-off-by: Pravin B Shelar &lt;pshelar@nicira.com&gt;
Acked-by: Eric Dumazet &lt;edumazet@google.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>net: openvswitch: Support masked set actions.</title>
<updated>2015-02-08T06:40:17Z</updated>
<author>
<name>Jarno Rajahalme</name>
<email>jrajahalme@nicira.com</email>
</author>
<published>2015-02-05T21:40:49Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=83d2b9ba1abca241df44a502b6da950a25856b5b'/>
<id>urn:sha1:83d2b9ba1abca241df44a502b6da950a25856b5b</id>
<content type='text'>
OVS userspace already probes the openvswitch kernel module for
OVS_ACTION_ATTR_SET_MASKED support.  This patch adds the kernel module
implementation of masked set actions.

The existing set action sets many fields at once.  When only a subset
of the IP header fields, for example, should be modified, all the IP
fields need to be exact matched so that the other field values can be
copied to the set action.  A masked set action allows modification of
an arbitrary subset of the supported header bits without requiring the
rest to be matched.

Masked set action is now supported for all writeable key types, except
for the tunnel key.  The set tunnel action is an exception as any
input tunnel info is cleared before action processing starts, so there
is no tunnel info to mask.

The kernel module converts all (non-tunnel) set actions to masked set
actions.  This makes action processing more uniform, and results in
less branching and duplicating the action processing code.  When
returning actions to userspace, the fully masked set actions are
converted back to normal set actions.  We use a kernel internal action
code to be able to tell the userspace provided and converted masked
set actions apart.

Signed-off-by: Jarno Rajahalme &lt;jrajahalme@nicira.com&gt;
Acked-by: Pravin B Shelar &lt;pshelar@nicira.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
<entry>
<title>openvswitch: Add support for checksums on UDP tunnels.</title>
<updated>2015-01-29T07:04:15Z</updated>
<author>
<name>Jesse Gross</name>
<email>jesse@nicira.com</email>
</author>
<published>2015-01-29T00:32:46Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=b8693877ae016ac525d674d5d7a84ea0ea68ba60'/>
<id>urn:sha1:b8693877ae016ac525d674d5d7a84ea0ea68ba60</id>
<content type='text'>
Currently, it isn't possible to request checksums on the outer UDP
header of tunnels - the TUNNEL_CSUM flag is ignored. This adds
support for requesting that UDP checksums be computed on transmit
and properly reported if they are present on receive.

Signed-off-by: Jesse Gross &lt;jesse@nicira.com&gt;
Signed-off-by: David S. Miller &lt;davem@davemloft.net&gt;
</content>
</entry>
</feed>
