Skip to content

amt: add initial driver for Automatic Multicast Tunneling (AMT)

Taehee Yoo netdev 7 versions – Applied

Status from this message: This series was applied to netdev/net-next.git (master)

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v7 Latest5 patches 0 repliesApplied 5/5
  2. v65 patches 0 repliesSuperseded
  3. v55 patches 0 repliesSuperseded
Earlier versions · 4
VersionPostedPatchesRepliesStatus
v44 patches8 repliesSuperseded
v31 patch2 repliesSuperseded
v21 patch1 replySuperseded
v11 patch2 repliesSuperseded

Changes in v7 from the cover letter

- Fix compile error.

Patches in v7 All 5 applied

#Subject and filesSizeRepliesApplied
1/5amt: add control plane of amt interfaceMAINTAINERS drivers/net/Kconfig drivers/net/Makefile +3 more+815 -00 repliesApplied
2/5amt: add data plane of amt interfacedrivers/net/amt.c include/net/amt.h+1288 -10 repliesApplied
3/5amt: add multicast(IGMP) report message handlerdrivers/net/amt.c include/net/amt.h+1234 -20 repliesApplied
4/5amt: add mld report message handlerdrivers/net/amt.c include/net/amt.h+441 -70 repliesApplied
5/5selftests: add amt interface selftest scripttools/testing/selftests/net/Makefile tools/testing/selftests/net/amt.sh tools/testing/selftests/net/config+286 -00 repliesApplied

Reviews trailers per patch

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

Read the v7 thread

Cover letter [PATCH net-next v7 0/5] amt: add initial driver for Automatic Multicast Tunneling (AMT)

This is an implementation of AMT(Automatic Multicast Tunneling), RFC 7450.
https://datatracker.ietf.org/doc/html/rfc7450

This implementation supports IGMPv2, IGMPv3, MLDv1, MLDv2, and IPv4 underlay.

Summary of RFC 7450
The purpose of this protocol is to provide multicast tunneling. The main use-case of this protocol is to provide delivery multicast traffic from a multicast-enabled network to sites that lack multicast connectivity to the source network.
There are two roles in AMT protocol, Gateway, and Relay.
The main purpose of Gateway mode is to forward multicast listening information(IGMP, MLD) to the source.
The main purpose of Relay mode is to forward multicast data to listeners. These multicast traffics(IGMP, MLD, multicast data packets) are tunneled.

Listeners are located behind Gateway endpoint.
But gateway itself can be a listener too.
Senders are located behind Relay endpoint.

    ___________       _________       _______       ________
   |           |     |         |     |       |     |        |
   | Listeners <-----> Gateway <-----> Relay <-----> Source |
   |___________|     |_________|     |_______|     |________|
      IGMP/MLD---------(encap)----------->
         <-------------(decap)--------(encap)------Multicast Data

Usage of AMT interface
1. Create gateway interface
ip link add amtg type amt mode gateway local 10.0.0.1 discovery 10.0.0.2 \
dev gw1_rt gateway_port 2268 relay_port 2268

2. Create Relay interface
ip link add amtr type amt mode relay local 10.0.0.2 dev relay_rt \
relay_port 2268 max_tunnels 4

v1 -> v2:
- Eliminate sparse warnings.
- Use bool type instead of __be16 for identifying v4/v6 protocol.

v2 -> v3:
- Fix compile warning due to unsed variable.
- Add missing spinlock comment.
- Update help message of amt in Kconfig.

v3 -> v4:
- Split patch.
- Use CHECKSUM_NONE instead of CHECKSUM_UNNECESSARY.
- Fix compile error.

v4 -> v5:
- Remove unnecessary rcu_read_lock().
- Remove unnecessary amt_change_mtu().
- Change netlink error message.
- Add validation for IFLA_AMT_LOCAL_IP and IFLA_AMT_DISCOVERY_IP.
- Add comments in amt.h.
- Add missing dev_put() in error path of amt_newlink().
- Fix typo.
- Add BUILD_BUG_ON() in amt_smb_cb().
- Use macro instead of magic values.
- Use kzalloc() instead of kmalloc().
- Add selftest script.

v5 -> v6:
- Reset remote_ip in amt_dev_stop().

v6 -> v7:
- Fix compile error.

Taehee Yoo (5):
amt: add control plane of amt interface
amt: add data plane of amt interface
amt: add multicast(IGMP) report message handler
amt: add mld report message handler
selftests: add amt interface selftest script

 MAINTAINERS                          |    8 +
 drivers/net/Kconfig                  |   16 +
 drivers/net/Makefile                 |    1 +
 drivers/net/amt.c                    | 3296 ++++++++++++++++++++++++++
 include/net/amt.h                    |  385 +++
 include/uapi/linux/amt.h             |   62 +
 tools/testing/selftests/net/Makefile |    1 +
 tools/testing/selftests/net/amt.sh   |  284 +++
 tools/testing/selftests/net/config   |    1 +
 9 files changed, 4054 insertions(+)
 create mode 100644 drivers/net/amt.c
 create mode 100644 include/net/amt.h
 create mode 100644 include/uapi/linux/amt.h
 create mode 100644 tools/testing/selftests/net/amt.sh
Signature · 1 line
2.17.1