Download raw body.
ppp(4) : Add IPv6 support
On Mon, Feb 26, 2024 at 08:49:34PM +0100, Denis Fondras wrote:
> Here is a diff to add IPv6 support to ppp(4).
> With this diff, I can send and receive IPv6 packets over a PPP connection.
>
> Anyone confortable to get this in ?
Looks good to me. OK claudio@
How does this interact with the various compression methods? Did you look
into that?
> +#ifdef INET6
> + case PPP_IPV6:
> + /*
> + * IPv6 packet - take off the ppp header and pass it up to IPv6.
> + */
> + if ((ifp->if_flags & IFF_UP) == 0 ||
> + sc->sc_npmode[NP_IPV6] != NPMODE_PASS) {
> + /* interface is down - drop the packet. */
> + m_freem(m);
> + return;
> + }
> + m->m_pkthdr.len -= PPP_HDRLEN;
> + m->m_data += PPP_HDRLEN;
> + m->m_len -= PPP_HDRLEN;
I know this is a copy of the PPP_IP case but isn't that above normally
spelled 'm_adj(m, PPP_HDRLEN);' ?
> + ipv6_input(ifp, m);
> + rv = 1;
> + break;
> +#endif
--
:wq Claudio
ppp(4) : Add IPv6 support