Re: [PATCH net] rtnetlink: fix possible deadlock in team_port_change_check

From: Jakub Kicinski
Date: Tue Jul 30 2024 - 19:59:21 EST


On Wed, 31 Jul 2024 00:22:10 +0900 Jeongjun Park wrote:
> do_setlink() changes the flag of the device and then enslaves it. However,
> in this case, if the IFF_UP flag is set, the enslavement process calls
> team_add_slave() to acquire 'team->lock', but when dev_open() opens the
> newly enslaved device, the NETDEV_UP event occurs, and as a result,
> a deadlock occurs when team_port_change_check() tries to acquire
> 'team->lock' again.

You can't change behavior like this, see ec4ffd100ffb396ec
--
pw-bot: reject