]> www.infradead.org Git - users/jedix/linux-maple.git/commit
mptcp: pm: drop match in userspace_pm_append_new_local_addr
authorGeliang Tang <tanggeliang@kylinos.cn>
Fri, 21 Feb 2025 15:43:58 +0000 (16:43 +0100)
committerJakub Kicinski <kuba@kernel.org>
Tue, 25 Feb 2025 02:23:43 +0000 (18:23 -0800)
commit640e3d69d0bc70d7d3de34800a1640793262bd08
treeb14049f9b6b188dabcce99df0ec38b0169e6c381
parentf8fe8174657329609a80f66da1d3dd80a80de76b
mptcp: pm: drop match in userspace_pm_append_new_local_addr

The variable 'match' in mptcp_userspace_pm_append_new_local_addr() is a
redundant one, and this patch drops it.

No need to define 'match' as 'struct mptcp_pm_addr_entry *' type. In this
function, it's only used to check whether it's NULL. It can be defined as
a Boolean one.

Also other variables 'addr_match' and 'id_match' make 'match' a redundant
one, which can be replaced by directly checking 'addr_match && id_match'.

Signed-off-by: Geliang Tang <tanggeliang@kylinos.cn>
Reviewed-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Signed-off-by: Matthieu Baerts (NGI0) <matttbe@kernel.org>
Link: https://patch.msgid.link/20250221-net-next-mptcp-pm-misc-cleanup-3-v1-5-2b70ab1cee79@kernel.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/mptcp/pm_userspace.c