netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] net: macb: Adding support for Jumbo Frames up to 10240 Bytes in SAMA5D2
@ 2024-10-03 17:19 Aleksander Jan Bajkowski
  2024-10-04 11:13 ` Simon Horman
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Aleksander Jan Bajkowski @ 2024-10-03 17:19 UTC (permalink / raw)
  To: nicolas.ferre, claudiu.beznea, davem, edumazet, kuba, pabeni,
	netdev, linux-kernel
  Cc: Aleksander Jan Bajkowski

As per the SAMA5D2 device specification it supports Jumbo frames.
But the suggested flag and length of bytes it supports was not updated
in this driver config_structure.
The maximum jumbo frames the device supports:
10240 bytes as per the device spec.

While changing the MTU value greater than 1500, it threw error:
sudo ifconfig eth1 mtu 9000
SIOCSIFMTU: Invalid argument

Add this support to driver so that it works as expected and designed.

Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
---
 drivers/net/ethernet/cadence/macb_main.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/cadence/macb_main.c b/drivers/net/ethernet/cadence/macb_main.c
index f06babec04a0..9fda16557509 100644
--- a/drivers/net/ethernet/cadence/macb_main.c
+++ b/drivers/net/ethernet/cadence/macb_main.c
@@ -4841,10 +4841,11 @@ static const struct macb_config pc302gem_config = {
 };
 
 static const struct macb_config sama5d2_config = {
-	.caps = MACB_CAPS_USRIO_DEFAULT_IS_MII_GMII,
+	.caps = MACB_CAPS_USRIO_DEFAULT_IS_MII_GMII | MACB_CAPS_JUMBO,
 	.dma_burst_length = 16,
 	.clk_init = macb_clk_init,
 	.init = macb_init,
+	.jumbo_max_len = 10240,
 	.usrio = &macb_default_usrio,
 };
 
-- 
2.39.5


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH net-next] net: macb: Adding support for Jumbo Frames up to 10240 Bytes in SAMA5D2
  2024-10-03 17:19 [PATCH net-next] net: macb: Adding support for Jumbo Frames up to 10240 Bytes in SAMA5D2 Aleksander Jan Bajkowski
@ 2024-10-04 11:13 ` Simon Horman
  2024-10-04 14:19 ` Nicolas Ferre
  2024-10-04 18:30 ` patchwork-bot+netdevbpf
  2 siblings, 0 replies; 4+ messages in thread
From: Simon Horman @ 2024-10-04 11:13 UTC (permalink / raw)
  To: Aleksander Jan Bajkowski
  Cc: nicolas.ferre, claudiu.beznea, davem, edumazet, kuba, pabeni,
	netdev, linux-kernel

On Thu, Oct 03, 2024 at 07:19:41PM +0200, Aleksander Jan Bajkowski wrote:
> As per the SAMA5D2 device specification it supports Jumbo frames.
> But the suggested flag and length of bytes it supports was not updated
> in this driver config_structure.
> The maximum jumbo frames the device supports:
> 10240 bytes as per the device spec.
> 
> While changing the MTU value greater than 1500, it threw error:
> sudo ifconfig eth1 mtu 9000
> SIOCSIFMTU: Invalid argument
> 
> Add this support to driver so that it works as expected and designed.
> 
> Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>

Thanks Aleksander,

This appears to be consistent with:

233a15875396 ("net: macb: Adding Support for Jumbo Frames up to 10240 Bytes in SAMA5D3")

Reviewed-by: Simon Horman <horms@kernel.org>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH net-next] net: macb: Adding support for Jumbo Frames up to 10240 Bytes in SAMA5D2
  2024-10-03 17:19 [PATCH net-next] net: macb: Adding support for Jumbo Frames up to 10240 Bytes in SAMA5D2 Aleksander Jan Bajkowski
  2024-10-04 11:13 ` Simon Horman
@ 2024-10-04 14:19 ` Nicolas Ferre
  2024-10-04 18:30 ` patchwork-bot+netdevbpf
  2 siblings, 0 replies; 4+ messages in thread
From: Nicolas Ferre @ 2024-10-04 14:19 UTC (permalink / raw)
  To: Aleksander Jan Bajkowski, claudiu.beznea, davem, edumazet, kuba,
	pabeni, netdev, linux-kernel, linux-arm-kernel

On 03/10/2024 at 19:19, Aleksander Jan Bajkowski wrote:
> As per the SAMA5D2 device specification it supports Jumbo frames.
> But the suggested flag and length of bytes it supports was not updated
> in this driver config_structure.
> The maximum jumbo frames the device supports:
> 10240 bytes as per the device spec.
> 
> While changing the MTU value greater than 1500, it threw error:
> sudo ifconfig eth1 mtu 9000
> SIOCSIFMTU: Invalid argument
> 
> Add this support to driver so that it works as expected and designed.
> 
> Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>

Looks good indeed:
Acked-by: Nicolas Ferre <nicolas.ferre@microchip.com>

Thanks, best regards,
   Nicolas

> ---
>   drivers/net/ethernet/cadence/macb_main.c | 3 ++-
>   1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/net/ethernet/cadence/macb_main.c b/drivers/net/ethernet/cadence/macb_main.c
> index f06babec04a0..9fda16557509 100644
> --- a/drivers/net/ethernet/cadence/macb_main.c
> +++ b/drivers/net/ethernet/cadence/macb_main.c
> @@ -4841,10 +4841,11 @@ static const struct macb_config pc302gem_config = {
>   };
> 
>   static const struct macb_config sama5d2_config = {
> -       .caps = MACB_CAPS_USRIO_DEFAULT_IS_MII_GMII,
> +       .caps = MACB_CAPS_USRIO_DEFAULT_IS_MII_GMII | MACB_CAPS_JUMBO,
>          .dma_burst_length = 16,
>          .clk_init = macb_clk_init,
>          .init = macb_init,
> +       .jumbo_max_len = 10240,
>          .usrio = &macb_default_usrio,
>   };
> 
> --
> 2.39.5
> 


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH net-next] net: macb: Adding support for Jumbo Frames up to 10240 Bytes in SAMA5D2
  2024-10-03 17:19 [PATCH net-next] net: macb: Adding support for Jumbo Frames up to 10240 Bytes in SAMA5D2 Aleksander Jan Bajkowski
  2024-10-04 11:13 ` Simon Horman
  2024-10-04 14:19 ` Nicolas Ferre
@ 2024-10-04 18:30 ` patchwork-bot+netdevbpf
  2 siblings, 0 replies; 4+ messages in thread
From: patchwork-bot+netdevbpf @ 2024-10-04 18:30 UTC (permalink / raw)
  To: Aleksander Jan Bajkowski
  Cc: nicolas.ferre, claudiu.beznea, davem, edumazet, kuba, pabeni,
	netdev, linux-kernel

Hello:

This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Thu,  3 Oct 2024 19:19:41 +0200 you wrote:
> As per the SAMA5D2 device specification it supports Jumbo frames.
> But the suggested flag and length of bytes it supports was not updated
> in this driver config_structure.
> The maximum jumbo frames the device supports:
> 10240 bytes as per the device spec.
> 
> While changing the MTU value greater than 1500, it threw error:
> sudo ifconfig eth1 mtu 9000
> SIOCSIFMTU: Invalid argument
> 
> [...]

Here is the summary with links:
  - [net-next] net: macb: Adding support for Jumbo Frames up to 10240 Bytes in SAMA5D2
    https://git.kernel.org/netdev/net-next/c/8389cdb5c192

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-10-04 18:30 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-03 17:19 [PATCH net-next] net: macb: Adding support for Jumbo Frames up to 10240 Bytes in SAMA5D2 Aleksander Jan Bajkowski
2024-10-04 11:13 ` Simon Horman
2024-10-04 14:19 ` Nicolas Ferre
2024-10-04 18:30 ` patchwork-bot+netdevbpf

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).