]> git.hungrycats.org Git - linux/commit
ipv4: properly combine dev_base_seq and ipv4.dev_addr_genid
authorEric Dumazet <edumazet@google.com>
Thu, 15 Feb 2024 17:21:06 +0000 (17:21 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 1 Mar 2024 12:26:36 +0000 (13:26 +0100)
commitb43a4fb42fefa69b00a4bc697c59b8107d9293cb
treebf46201f8cfddd3616089d35207315b35a009b96
parent8e29f988ad32e87fbfe263d7d22d24c6a9eaba05
ipv4: properly combine dev_base_seq and ipv4.dev_addr_genid

[ Upstream commit 081a0e3b0d4c061419d3f4679dec9f68725b17e4 ]

net->dev_base_seq and ipv4.dev_addr_genid are monotonically increasing.

If we XOR their values, we could miss to detect if both values
were changed with the same amount.

Fixes: 0465277f6b3f ("ipv4: provide addr and netconf dump consistency info")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Acked-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
net/ipv4/devinet.c