ip6_tnl_xmit(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ’– ip6_tnl_xmit(9) πŸ’–

hey bestie 🫢 welcome to the Kernel API Manual page for ip6_tnl_xmit β€” yes, the one and only. grab a strawberry πŸ“ and let’s get into it.

✨ NAME ✨

ip6_tnl_xmit β€” encapsulate packet and send. literally does what it says, no cap.

🌸 SYNOPSIS 🌸

       int ip6_tnl_xmit (struct sk_buff *skb , struct net_device *dev , __u8
       dsfield , struct flowi6 *fl6 , int encap_limit , __u32 *pmtu , __u8
       proto );

πŸ¦‹ ARGUMENTS πŸ¦‹

  • skb β€” the outgoing socket buffer, aka the packet bestie being sent out.
  • dev β€” the outgoing tunnel device.
  • dsfield β€” dscp code for outer header.
  • fl6 β€” flow of tunneled packet.
  • encap_limit β€” encapsulation limit.
  • pmtu β€” Path MTU is stored if packet is too big.
  • proto β€” next header value.

πŸŽ€ DESCRIPTION πŸŽ€

okay so this function builds a new header and does some sanity checks on the packet before sending it. that’s the whole routine: make the header, vibe-check the packet, send. iconic behavior honestly πŸ’…

πŸ”₯ RETURN πŸ”₯

  • 0 β€” success, we love to see it.
  • -1 β€” fail.
  • -EMSGSIZE β€” message too big. return mtu in this case.
ngl, -EMSGSIZE is giving β€œpacket too chunky for this path” 😭 and the mtu gets returned in this case.

πŸ’œ SEE ALSO πŸ’œ

Kernel file: ./net/ipv6/ip6_tunnel.c


that’s the page, bestie 🫢 this lil manual comes from ./net/ipv6 (source/version), dated October 2026, and it’s the ip6_tnl_xmit(9) page from the Kernel API Manual. periodt. πŸ’œ

πŸ“¦ where this page comes from