Searched hist:"35 b72beac967240c0a942a008284475b09440db9" (Results 1 – 2 of 2) sorted by relevance
/openbmc/linux/include/net/ |
H A D | rtnetlink.h | diff 35b72beac967240c0a942a008284475b09440db9 Tue Oct 08 13:47:32 CDT 2024 Kuniyuki Iwashima <kuniyu@amazon.com> rtnetlink: Add bulk registration helpers for rtnetlink message handlers.
[ Upstream commit 07cc7b0b942bf55ef1a471470ecda8d2a6a6541f ]
Before commit addf9b90de22 ("net: rtnetlink: use rcu to free rtnl message handlers"), once rtnl_msg_handlers[protocol] was allocated, the following rtnl_register_module() for the same protocol never failed.
However, after the commit, rtnl_msg_handler[protocol][msgtype] needs to be allocated in each rtnl_register_module(), so each call could fail.
Many callers of rtnl_register_module() do not handle the returned error, and we need to add many error handlings.
To handle that easily, let's add wrapper functions for bulk registration of rtnetlink message handlers.
Signed-off-by: Kuniyuki Iwashima <kuniyu@amazon.com> Signed-off-by: Paolo Abeni <pabeni@redhat.com> Stable-dep-of: 78b7b991838a ("vxlan: Handle error of rtnl_register_module().") Signed-off-by: Sasha Levin <sashal@kernel.org>
|
/openbmc/linux/net/core/ |
H A D | rtnetlink.c | diff 35b72beac967240c0a942a008284475b09440db9 Tue Oct 08 13:47:32 CDT 2024 Kuniyuki Iwashima <kuniyu@amazon.com> rtnetlink: Add bulk registration helpers for rtnetlink message handlers.
[ Upstream commit 07cc7b0b942bf55ef1a471470ecda8d2a6a6541f ]
Before commit addf9b90de22 ("net: rtnetlink: use rcu to free rtnl message handlers"), once rtnl_msg_handlers[protocol] was allocated, the following rtnl_register_module() for the same protocol never failed.
However, after the commit, rtnl_msg_handler[protocol][msgtype] needs to be allocated in each rtnl_register_module(), so each call could fail.
Many callers of rtnl_register_module() do not handle the returned error, and we need to add many error handlings.
To handle that easily, let's add wrapper functions for bulk registration of rtnetlink message handlers.
Signed-off-by: Kuniyuki Iwashima <kuniyu@amazon.com> Signed-off-by: Paolo Abeni <pabeni@redhat.com> Stable-dep-of: 78b7b991838a ("vxlan: Handle error of rtnl_register_module().") Signed-off-by: Sasha Levin <sashal@kernel.org>
|