Commit 4998ab3e authored by Takamitsu Iwai's avatar Takamitsu Iwai Committed by Greg Kroah-Hartman
Browse files

net: rose: split remove and free operations in rose_remove_neigh()



[ Upstream commit dcb34659 ]

The current rose_remove_neigh() performs two distinct operations:
1. Removes rose_neigh from rose_neigh_list
2. Frees the rose_neigh structure

Split these operations into separate functions to improve maintainability
and prepare for upcoming refcount_t conversion. The timer cleanup remains
in rose_remove_neigh() because free operations can be called from timer
itself.

This patch introduce rose_neigh_put() to handle the freeing of rose_neigh
structures and modify rose_remove_neigh() to handle removal only.

Signed-off-by: default avatarTakamitsu Iwai <takamitz@amazon.co.jp>
Reviewed-by: default avatarKuniyuki Iwashima <kuniyu@google.com>
Link: https://patch.msgid.link/20250823085857.47674-2-takamitz@amazon.co.jp


Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
Stable-dep-of: d860d1fa ("net: rose: convert 'use' field to refcount_t")
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent b0f87251
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment