mbox series

[net-next,0/2] net: dsa: lan9303: IGMP handling

Message ID 20171110115435.4261-1-privat@egil-hjelmeland.no
Headers show
Series net: dsa: lan9303: IGMP handling | expand

Message

Egil Hjelmeland Nov. 10, 2017, 11:54 a.m. UTC
Set up the HW switch to trap IGMP packets to CPU port. 
And make sure skb->offload_fwd_mark is cleared for incoming IGMP packets.

skb->offload_fwd_mark calculation is a candidate for consolidation into the
DSA core. The calculation can probably be more polished when done at a point
where DSA has updated skb.  


Egil Hjelmeland (2):
  net: dsa: lan9303: Set up trapping of IGMP to CPU port
  net: dsa: lan9303: Clear offload_fwd_mark for IGMP

 drivers/net/dsa/lan9303-core.c | 26 ++++++++++++++++++++++++++
 net/dsa/tag_lan9303.c          | 13 +++++++++++++
 2 files changed, 39 insertions(+)

Comments

Andrew Lunn Nov. 10, 2017, 2:07 p.m. UTC | #1
> skb->offload_fwd_mark calculation is a candidate for consolidation into the
> DSA core. The calculation can probably be more polished when done at a point
> where DSA has updated skb.  

Hi Egil

Yes, at some point we should do this. But at the moment it is too
early. We don't have enough experience with what the different
switches need. I would like to see 4 or more devices doing it before
we consolidate the code into the core.

	    Andrew
Egil Hjelmeland Nov. 10, 2017, 6:22 p.m. UTC | #2
Den 10. nov. 2017 15:07, skrev Andrew Lunn:
>> skb->offload_fwd_mark calculation is a candidate for consolidation into the
>> DSA core. The calculation can probably be more polished when done at a point
>> where DSA has updated skb.
> 
> Hi Egil
> 
> Yes, at some point we should do this. But at the moment it is too
> early. We don't have enough experience with what the different
> switches need. I would like to see 4 or more devices doing it before
> we consolidate the code into the core.
> 

Absolutely. My point was rather I prefer not spend time polishing this 
snippet right now, because it will probably be refactored later anyway.

One steppingstone could be to make reusable helper-functions in 
net/dsa/dsa_priv.h. But I leave that to device #2 that implement this ;-)

> 	    Andrew
> 

Egil
David Miller Nov. 11, 2017, 12:50 p.m. UTC | #3
From: Egil Hjelmeland <privat@egil-hjelmeland.no>
Date: Fri, 10 Nov 2017 12:54:33 +0100

> Set up the HW switch to trap IGMP packets to CPU port. 
> And make sure skb->offload_fwd_mark is cleared for incoming IGMP packets.
> 
> skb->offload_fwd_mark calculation is a candidate for consolidation into the
> DSA core. The calculation can probably be more polished when done at a point
> where DSA has updated skb.  

Series applied, thank you.