mbox series

[net-next,0/3] net: ethernet: ti: cpsw/emac: switch to use skb_put_padto()

Message ID 20210805145555.12182-1-grygorii.strashko@ti.com
Headers show
Series net: ethernet: ti: cpsw/emac: switch to use skb_put_padto() | expand

Message

Grygorii Strashko Aug. 5, 2021, 2:55 p.m. UTC
hi 

Now frame padding in TI TI CPSW/EMAC is implemented in a bit of entangled way as
frame SKB padded in drivers (without skb->len) while frame length fixed in CPDMA.
Things became even more confusing hence CPSW switcdev driver need to perform min
TX frame length correction in switch mode [1].

To avoid further confusion, make xmit path more clear and linear, and avoid
updating CPDMA configuration interface for min TX frame length correction
(which is not CPDMA job in general) this series switches TI CPSW/EMAC
drivers to skb_put_padto() instead of skb_padto() in their xmit path, so 
skb->len also got updated properly and then removes TX frame length
fixup from CPDMA code.

[1] https://patchwork.kernel.org/project/netdevbpf/patch/20210611132732.10690-1-grygorii.strashko@ti.com/

Grygorii Strashko (3):
  net: ethernet: ti: cpsw: switch to use skb_put_padto()
  net: ethernet: ti: davinci_emac: switch to use skb_put_padto()
  net: ethernet: ti: davinci_cpdma: drop frame padding

 drivers/net/ethernet/ti/cpsw.c          | 2 +-
 drivers/net/ethernet/ti/cpsw_priv.c     | 1 -
 drivers/net/ethernet/ti/davinci_cpdma.c | 5 -----
 drivers/net/ethernet/ti/davinci_cpdma.h | 1 -
 drivers/net/ethernet/ti/davinci_emac.c  | 3 +--
 5 files changed, 2 insertions(+), 10 deletions(-)

Comments

patchwork-bot+netdevbpf@kernel.org Aug. 6, 2021, 9:30 a.m. UTC | #1
Hello:

This series was applied to netdev/net-next.git (refs/heads/master):

On Thu, 5 Aug 2021 17:55:52 +0300 you wrote:
> hi

> 

> Now frame padding in TI TI CPSW/EMAC is implemented in a bit of entangled way as

> frame SKB padded in drivers (without skb->len) while frame length fixed in CPDMA.

> Things became even more confusing hence CPSW switcdev driver need to perform min

> TX frame length correction in switch mode [1].

> 

> [...]


Here is the summary with links:
  - [net-next,1/3] net: ethernet: ti: cpsw: switch to use skb_put_padto()
    https://git.kernel.org/netdev/net-next/c/1f88d5d566b8
  - [net-next,2/3] net: ethernet: ti: davinci_emac: switch to use skb_put_padto()
    https://git.kernel.org/netdev/net-next/c/61e7a22da75b
  - [net-next,3/3] net: ethernet: ti: davinci_cpdma: drop frame padding
    https://git.kernel.org/netdev/net-next/c/9ffc513f95ee

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
Grygorii Strashko Aug. 6, 2021, 10 a.m. UTC | #2
hi Jakub, David,

On 06/08/2021 12:30, patchwork-bot+netdevbpf@kernel.org wrote:
> Hello:

> 

> This series was applied to netdev/net-next.git (refs/heads/master):

> 

> On Thu, 5 Aug 2021 17:55:52 +0300 you wrote:

>> hi

>>

>> Now frame padding in TI TI CPSW/EMAC is implemented in a bit of entangled way as

>> frame SKB padded in drivers (without skb->len) while frame length fixed in CPDMA.

>> Things became even more confusing hence CPSW switcdev driver need to perform min

>> TX frame length correction in switch mode [1].

>>

>> [...]

> 

> Here is the summary with links:

>    - [net-next,1/3] net: ethernet: ti: cpsw: switch to use skb_put_padto()

>      https://git.kernel.org/netdev/net-next/c/1f88d5d566b8

>    - [net-next,2/3] net: ethernet: ti: davinci_emac: switch to use skb_put_padto()

>      https://git.kernel.org/netdev/net-next/c/61e7a22da75b

>    - [net-next,3/3] net: ethernet: ti: davinci_cpdma: drop frame padding

>      https://git.kernel.org/netdev/net-next/c/9ffc513f95ee


I'm terribly sorry for the mess here - this series depends from patch
"net: ethernet: ti: cpsw: fix min eth packet size for non-switch use-cases" [1]

Not sure what I've being thinking about I've had to note it or include in this series :(

I'm very sorry again - can it be dropped?

[1] https://patchwork.kernel.org/project/netdevbpf/patch/20210805145511.12016-1-grygorii.strashko@ti.com/

-- 
Best regards,
grygorii
David Miller Aug. 6, 2021, 10:04 a.m. UTC | #3
From: Grygorii Strashko <grygorii.strashko@ti.com>

Date: Fri, 6 Aug 2021 13:00:30 +0300

> 

> I'm very sorry again - can it be dropped?


Easiest is for you to send a fixup or a revert to the list, thanks.
Grygorii Strashko Aug. 6, 2021, 10:07 a.m. UTC | #4
On 06/08/2021 13:04, David Miller wrote:
> From: Grygorii Strashko <grygorii.strashko@ti.com>

> Date: Fri, 6 Aug 2021 13:00:30 +0300

> 

>>

>> I'm very sorry again - can it be dropped?

> 

> Easiest is for you to send a fixup or a revert to the list, thanks.

> 

> 


Only Patch 3 need to be reverted - i'll send revert. Thank you.

-- 
Best regards,
grygorii