]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
amt: fix return value of amt_update_handler()
authorTaehee Yoo <ap420073@gmail.com>
Mon, 23 May 2022 16:17:07 +0000 (16:17 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 14 Jun 2022 16:41:20 +0000 (18:41 +0200)
[ Upstream commit ac1dbf55981b88d64312858ea06e3e63001f085d ]

If a relay receives an update message, it lookup a tunnel.
and if there is no tunnel for that message, it should be treated
as an error, not a success.
But amt_update_handler() returns false, which means success.

Fixes: cbc21dc1cfe9 ("amt: add data plane of amt interface")
Signed-off-by: Taehee Yoo <ap420073@gmail.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/amt.c

index fb774d568baab6f96f7830087c0ed773463f6171..6205282a09e59454c8dfcd0a7c23de2b1187d2a9 100644 (file)
@@ -2423,7 +2423,7 @@ static bool amt_update_handler(struct amt_dev *amt, struct sk_buff *skb)
                }
        }
 
-       return false;
+       return true;
 
 report:
        iph = ip_hdr(skb);