Skip to content

RFC macvlan: allow source mode devices along with passthru

Thomas Martitz lkml netdev syzbot 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest1 patch 3 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/1macvlan: allow source mode devices along with passthrudrivers/net/macvlan.c+28 -130 replies
1/1macvlan: allow source mode devices along with passthrudrivers/net/macvlan.c+28 -133 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH RFC 0/1] macvlan: allow source mode devices along with passthru

Hello,

we're trying to solve a use case on our devices where two SoC are connected on the same board, using the only available high-speed.

One SoC runs the main Linux system including the full routing stack (FRITZ!OS) and the other SoC implements most of the GPON ONT side.

The high-speed interface is of course also used for the user traffic. Therefore we must tell the inter-SoC traffic apart from the user traffic.

We achieve this by matching the well-known MAC address of the ONT SoC. The user traffic passes through the ONT SoC without modifying MAC headers. Now we would like to use macvlan (with source mode devices) on the main SoC side for this but our routing stack requires the rx_handler to be available. Therefore macvlan is currently not an option.

With this patch macvlan becomes an option because the current limitation of either "one passthru device" or "any other configuration" is relaxed for the combination of passthru and any number of source mode devices.

This allows us to configure a source mode device for the other SoC and register an rx_handler for further processing on the passthru device.

The patch is still in an RFC state. I am not 100% confident that all the cases where the code checks "macvlan_passthru(port)" are handled appropriately. I hope you can guide me a little bit and provide feedback on the general approach.

Thanks in advance!

Thomas Martitz (1):
macvlan: allow source mode devices along with passthru

 drivers/net/macvlan.c | 41 ++++++++++++++++++++++++++++-------------
 1 file changed, 28 insertions(+), 13 deletions(-)
Signature · 1 line
2.54.0