]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
netpoll: Extract IPv6 address retrieval function
authorBreno Leitao <leitao@debian.org>
Wed, 18 Jun 2025 09:32:47 +0000 (02:32 -0700)
committerJakub Kicinski <kuba@kernel.org>
Thu, 19 Jun 2025 23:15:35 +0000 (16:15 -0700)
commit6ad7969a361cbec5822285fb39203678ff462b64
tree2996919be163a77ed55c10f50a8ab05a6e57841e
parent3699f992e8c22d3ce54d2c1a5774e2c49028f99c
netpoll: Extract IPv6 address retrieval function

Extract the IPv6 address retrieval logic from netpoll_setup() into
a dedicated helper function netpoll_take_ipv6() to improve code
organization and readability.

The function handles obtaining the local IPv6 address from the
network device, including proper address type matching between
local and remote addresses (link-local vs global), and includes
appropriate error handling when IPv6 is not supported or no
suitable address is available.

Signed-off-by: Breno Leitao <leitao@debian.org>
Reviewed-by: Simon Horman <horms@kernel.org>
Link: https://patch.msgid.link/20250618-netpoll_ip_ref-v1-3-c2ac00fe558f@debian.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/core/netpoll.c