From: Chris Packham <Chris.Packham@alliedtelesis.co.nz>
To: Andrew Lunn <andrew@lunn.ch>
Cc: "vivien.didelot@gmail.com" <vivien.didelot@gmail.com>,
"f.fainelli@gmail.com" <f.fainelli@gmail.com>,
"davem@davemloft.net" <davem@davemloft.net>,
"kuba@kernel.org" <kuba@kernel.org>,
"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH 3/4] net: dsa: mv88e6xxx: Implement .port_change_mtu/.port_max_mtu
Date: Thu, 23 Jul 2020 20:50:27 +0000 [thread overview]
Message-ID: <e10da452-c04a-b519-6c30-c94e60101f92@alliedtelesis.co.nz> (raw)
In-Reply-To: <20200723133122.GB1553578@lunn.ch>
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@lunn.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@lunn.ch>
> Signed-off-by: David S. Miller <davem@davemloft.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.
next prev parent reply other threads:[~2020-07-23 20:50 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-23 3:59 [PATCH 0/4] net: dsa: mv88e6xxx: port mtu support Chris Packham
2020-07-23 3:59 ` [PATCH 1/4] net: dsa: mv88e6xxx: MV88E6097 does not support jumbo configuration Chris Packham
2020-07-23 13:31 ` Andrew Lunn
2020-07-23 3:59 ` [PATCH 2/4] net: dsa: mv88e6xxx: Support jumbo configuration on 6190/6190X Chris Packham
2020-07-23 13:32 ` Andrew Lunn
2020-07-23 3:59 ` [PATCH 3/4] net: dsa: mv88e6xxx: Implement .port_change_mtu/.port_max_mtu Chris Packham
2020-07-23 13:31 ` Andrew Lunn
2020-07-23 20:50 ` Chris Packham [this message]
2020-07-23 21:02 ` Andrew Lunn
2020-07-23 21:16 ` Chris Packham
2020-07-23 3:59 ` [PATCH 4/4] net: dsa: mv88e6xxx: Use chip-wide max frame size for MTU Chris Packham
2020-07-23 13:34 ` Andrew Lunn
2020-07-23 20:54 ` Chris Packham
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=e10da452-c04a-b519-6c30-c94e60101f92@alliedtelesis.co.nz \
--to=chris.packham@alliedtelesis.co.nz \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=f.fainelli@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=vivien.didelot@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).