]> git.baikalelectronics.ru Git - kernel.git/commit
net: openvswitch: fix TTL decrement exception action execution
authorEelco Chaudron <echaudro@redhat.com>
Mon, 7 Dec 2020 10:08:39 +0000 (05:08 -0500)
committerJakub Kicinski <kuba@kernel.org>
Tue, 15 Dec 2020 01:18:25 +0000 (17:18 -0800)
commite8a5ebed6a39e9428765acc189d062df702c3641
tree0faaf1e2e9ac3a14acd967672f7da9df45bdb825
parent3cb7e6c2a2eaba432c181d9c42f701f7257bc0cd
net: openvswitch: fix TTL decrement exception action execution

Currently, the exception actions are not processed correctly as the wrong
dataset is passed. This change fixes this, including the misleading
comment.

In addition, a check was added to make sure we work on an IPv4 packet,
and not just assume if it's not IPv6 it's IPv4.

This was all tested using OVS with patch,
https://patchwork.ozlabs.org/project/openvswitch/list/?series=21639,
applied and sending packets with a TTL of 1 (and 0), both with IPv4
and IPv6.

Fixes: 4af693f8a909 ("net: openvswitch: fix TTL decrement action netlink message format")
Signed-off-by: Eelco Chaudron <echaudro@redhat.com>
Link: https://lore.kernel.org/r/160733569860.3007.12938188180387116741.stgit@wsfd-netdev64.ntdv.lab.eng.bos.redhat.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/openvswitch/actions.c