fragment
This commit is contained in:
12
README.md
12
README.md
@@ -53,6 +53,18 @@ The transmit path permits local IPv6 fragmentation for encapsulated EtherIP
|
|||||||
packets that exceed the outer path MTU. This lets a larger inner Ethernet
|
packets that exceed the outer path MTU. This lets a larger inner Ethernet
|
||||||
frame be split into multiple outer IPv6 fragments by the local host.
|
frame be split into multiple outer IPv6 fragments by the local host.
|
||||||
|
|
||||||
|
The device default MTU is 1500, but the module allows an overlay MTU up to
|
||||||
|
9000. For example, with a 1500-byte underlay and a 9000-byte overlay:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
sudo ip link set eip0 mtu 9000
|
||||||
|
```
|
||||||
|
|
||||||
|
An inner 9000-byte payload is carried as a 9014-byte Ethernet frame, plus the
|
||||||
|
2-byte EtherIP header and 40-byte outer IPv6 header. The local IPv6 stack
|
||||||
|
fragments that outer packet before transmission, and the peer must reassemble
|
||||||
|
the IPv6 fragments before EtherIP decapsulation.
|
||||||
|
|
||||||
You can still set a smaller tunnel MTU when you want to avoid IPv6 fragments:
|
You can still set a smaller tunnel MTU when you want to avoid IPv6 fragments:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
|
|||||||
13
build
Executable file
13
build
Executable file
@@ -0,0 +1,13 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
KVER="$(uname -r)"
|
||||||
|
KDIR="/lib/modules/$KVER/build"
|
||||||
|
|
||||||
|
if [ ! -d "$KDIR" ]; then
|
||||||
|
echo "error: kernel headers for running kernel $KVER were not found at $KDIR" >&2
|
||||||
|
echo "install matching Arch headers or reboot into the kernel that matches installed headers" >&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
make KDIR="$KDIR"
|
||||||
@@ -31,6 +31,7 @@
|
|||||||
#define ETHERIP6_HDR htons(ETHERIP6_VERSION << 12)
|
#define ETHERIP6_HDR htons(ETHERIP6_VERSION << 12)
|
||||||
#define ETHERIP6_HLEN 2
|
#define ETHERIP6_HLEN 2
|
||||||
#define ETHERIP6_DEFAULT_HOP_LIMIT 64
|
#define ETHERIP6_DEFAULT_HOP_LIMIT 64
|
||||||
|
#define ETHERIP6_MAX_MTU 9000
|
||||||
|
|
||||||
struct etherip6_tunnel {
|
struct etherip6_tunnel {
|
||||||
struct list_head list;
|
struct list_head list;
|
||||||
@@ -250,7 +251,7 @@ static void etherip6_setup(struct net_device *dev)
|
|||||||
dev->hw_features = 0;
|
dev->hw_features = 0;
|
||||||
dev->vlan_features = 0;
|
dev->vlan_features = 0;
|
||||||
dev->min_mtu = ETH_MIN_MTU;
|
dev->min_mtu = ETH_MIN_MTU;
|
||||||
dev->max_mtu = ETH_DATA_LEN;
|
dev->max_mtu = ETHERIP6_MAX_MTU;
|
||||||
eth_hw_addr_random(dev);
|
eth_hw_addr_random(dev);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
1291
rfc8900.txt
Normal file
1291
rfc8900.txt
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user