Re: [patch net-next 09/26] team: fill-up LAG changeupper info struct and pass it along

Or Gerlitz
2015-12-02T05:36:17Z

On Tue, Dec 1, 2015 at 3:48 PM, Jiri Pirko <jiri@resnulli.us> wrote:
> Initialize netdev_lag_upper_info structure by TX type according to
> current team mode and pass it along via netdev_master_upper_dev_link.
[...]
> --- a/drivers/net/team/team.c
> +++ b/drivers/net/team/team.c
> @@ -1078,23 +1078,24 @@ static void team_port_disable_netpoll(struct team_port *port)
> }
> #endif
>
> -static int team_upper_dev_link(struct net_device *dev,
> - struct net_device *port_dev)
> +static int team_upper_dev_link(struct team *team, struct team_port *port)
> {
> + struct netdev_lag_upper_info lag_upper_info;
> int err;
>
> - err = netdev_master_upper_dev_link(port_dev, dev, NULL, NULL);
> + lag_upper_info.tx_type = team->mode->lag_tx_type;
> + err = netdev_master_upper_dev_link(port->dev, team->dev, NULL,
> + &lag_upper_info);
> if (err)
> return err;
> - port_dev->priv_flags |= IFF_TEAM_PORT;
> + port->dev->priv_flags |= IFF_TEAM_PORT;
> return 0;
> }

you also added into this patch moving

from struct netdevice *dev_port->xxx

to struct team_port *port->dev->xxx

which goes beyond the logical change / functionality this patch
introduces... maybe
better put it in a separate patch?

Or.