[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <e10da452-c04a-b519-6c30-c94e60101f92@alliedtelesis.co.nz>
Date: Thu, 23 Jul 2020 20:50:27 +0000
From: Chris Packham <Chris.Packham@...iedtelesis.co.nz>
To: Andrew Lunn <andrew@...n.ch>
CC: "vivien.didelot@...il.com" <vivien.didelot@...il.com>,
"f.fainelli@...il.com" <f.fainelli@...il.com>,
"davem@...emloft.net" <davem@...emloft.net>,
"kuba@...nel.org" <kuba@...nel.org>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 3/4] net: dsa: mv88e6xxx: Implement
.port_change_mtu/.port_max_mtu
On 24/07/20 1:31 am, Andrew Lunn wrote:
> On Thu, Jul 23, 2020 at 03:59:41PM +1200, Chris Packham wrote:
>> Add implementations for the mv88e6xxx switches to connect with the
>> generic dsa operations for configuring the port MTU.
> Hi Chris
>
> What tree is this against?
$ git config remote.origin.url
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
$ git describe `git merge-base HEAD origin/master`
v5.8-rc6-3-g4fa640dc5230
> commit 2a550aec36543b20f087e4b3063882e9465f7175
> Author: Andrew Lunn <andrew@...n.ch>
> Date: Sat Jul 11 22:32:05 2020 +0200
>
> net: dsa: mv88e6xxx: Implement MTU change
>
> The Marvell Switches support jumbo packages. So implement the
> callbacks needed for changing the MTU.
>
> Signed-off-by: Andrew Lunn <andrew@...n.ch>
> Signed-off-by: David S. Miller <davem@...emloft.net>
>
> diff --git a/drivers/net/dsa/mv88e6xxx/chip.c b/drivers/net/dsa/mv88e6xxx/chip.c
> index d995f5bf0d40..6f019955ae42 100644
> --- a/drivers/net/dsa/mv88e6xxx/chip.c
> +++ b/drivers/net/dsa/mv88e6xxx/chip.c
> @@ -2693,6 +2693,31 @@ static int mv88e6xxx_setup_port(struct mv88e6xxx_chip *chip, int port)
> return mv88e6xxx_port_write(chip, port, MV88E6XXX_PORT_DEFAULT_VLAN, 0);
> }
>
> +static int mv88e6xxx_get_max_mtu(struct dsa_switch *ds, int port)
> +{
> + struct mv88e6xxx_chip *chip = ds->priv;
> +
> + if (chip->info->ops->port_set_jumbo_size)
> + return 10240;
> + return 1522;
> +}
> +
> +static int mv88e6xxx_change_mtu(struct dsa_switch *ds, int port, int new_mtu)
> +{
> ...
Snap. I created my series because I need it on an internal 5.7 based
kernel. So I'm happy to drop mine and back-port your implementation.
Powered by blists - more mailing lists