Skip to contentSkip to conversation

Patch "openvswitch: use flow protocol when recalculating ipv6 checksums" has been added to the 4.5-stable tree

PATCH [email protected] 1 participant 1 message May 16, 2016

Subsystems (3)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

openvswitch: use flow protocol when recalculating ipv6 checksums

to the 4.5-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
openvswitch-use-flow-protocol-when-recalculating-ipv6-checksums.patch
and it can be found in the queue-4.5 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From foo@baz Mon May 16 11:20:33 PDT 2016

From: Simon Horman <[email protected]>
Date: Thu, 21 Apr 2016 11:49:15 +1000
Subject: openvswitch: use flow protocol when recalculating ipv6 checksums

From: Simon Horman <[email protected]>

[ Upstream commit b4f70527f052b0c00be4d7cac562baa75b212df5 ]

When using masked actions the ipv6_proto field of an action to set IPv6 fields may be zero rather than the prevailing protocol which will result in skipping checksum recalculation.

This patch resolves the problem by relying on the protocol in the flow key rather than that in the set field action.

Fixes 83d2b9ba1abc ("net: openvswitch: Support masked set actions.")
Cc Jarno Rajahalme <[email protected]>
---
 net/openvswitch/actions.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
net/openvswitch/actions.c +2 -2
@@ -461,7 +461,7 @@ static int set_ipv6(struct sk_buff *skb,
 		mask_ipv6_addr(saddr, key->ipv6_src, mask->ipv6_src, masked);
 
 		if (unlikely(memcmp(saddr, masked, sizeof(masked)))) {
-			set_ipv6_addr(skb, key->ipv6_proto, saddr, masked,
+			set_ipv6_addr(skb, flow_key->ip.proto, saddr, masked,
 				      true);
 			memcpy(&flow_key->ipv6.addr.src, masked,
 			       sizeof(flow_key->ipv6.addr.src));
@@ -483,7 +483,7 @@ static int set_ipv6(struct sk_buff *skb,
 							     NULL, &flags)
 					       != NEXTHDR_ROUTING);
 
-			set_ipv6_addr(skb, key->ipv6_proto, daddr, masked,
+			set_ipv6_addr(skb, flow_key->ip.proto, daddr, masked,
 				      recalc_csum);
 			memcpy(&flow_key->ipv6.addr.dst, masked,
 			       sizeof(flow_key->ipv6.addr.dst));

Patches currently in stable-queue which might be from [email protected] are

queue-4.5/openvswitch-use-flow-protocol-when-recalculating-ipv6-checksums.patch