Re: team_change_rx flags sleeping with bh disabled

From: syzbot
Date: Sun Jul 27 2025 - 13:37:08 EST


> #syz test

This crash does not have a reproducer. I cannot test it.

>
> diff --git a/drivers/net/team/team_core.c b/drivers/net/team/team_core.c
> index 8bc56186b2a3..4568075fea6e 100644
> --- a/drivers/net/team/team_core.c
> +++ b/drivers/net/team/team_core.c
> @@ -1778,7 +1778,7 @@ static void team_change_rx_flags(struct
> net_device *dev, int change)
> struct team_port *port;
> int inc;
>
> - mutex_lock(&team->lock);
> + spin_lock(&team->lock);
> list_for_each_entry(port, &team->port_list, list) {
> if (change & IFF_PROMISC) {
> inc = dev->flags & IFF_PROMISC ? 1 : -1;
> @@ -1789,7 +1789,7 @@ static void team_change_rx_flags(struct
> net_device *dev, int change)
> dev_set_allmulti(port->dev, inc);
> }
> }
> - mutex_unlock(&team->lock);
> + spin_unlock(&team->lock);
> }
>
> static void team_set_rx_mode(struct net_device *dev)
> --
> 2.30.2