if_stf.c (f0ffb944d259efbe7c4e223b4068be440c1a51cf) if_stf.c (ff265614c166724356a66c341ff3bb9c4ee3c260)
1/* $FreeBSD$ */
2/* $KAME: if_stf.c,v 1.62 2001/06/07 22:32:16 itojun Exp $ */
3
4/*
5 * Copyright (C) 2000 WIDE Project.
6 * All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 516 unchanged lines hidden (view full) ---

525 */
526 if (IN6_IS_ADDR_V4COMPAT(in6) || IN6_IS_ADDR_V4MAPPED(in6))
527 return -1;
528
529 return 0;
530}
531
532void
1/* $FreeBSD$ */
2/* $KAME: if_stf.c,v 1.62 2001/06/07 22:32:16 itojun Exp $ */
3
4/*
5 * Copyright (C) 2000 WIDE Project.
6 * All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 516 unchanged lines hidden (view full) ---

525 */
526 if (IN6_IS_ADDR_V4COMPAT(in6) || IN6_IS_ADDR_V4MAPPED(in6))
527 return -1;
528
529 return 0;
530}
531
532void
533#if __STDC__
534in_stf_input(struct mbuf *m, ...)
535#else
536in_stf_input(m, va_alist)
533in_stf_input(m, off)
537 struct mbuf *m;
534 struct mbuf *m;
538#endif
535 int off;
539{
536{
540 int off, proto;
537 int proto;
541 struct stf_softc *sc;
542 struct ip *ip;
543 struct ip6_hdr *ip6;
544 u_int8_t otos, itos;
545 int len, isr;
546 struct ifqueue *ifq = NULL;
547 struct ifnet *ifp;
538 struct stf_softc *sc;
539 struct ip *ip;
540 struct ip6_hdr *ip6;
541 u_int8_t otos, itos;
542 int len, isr;
543 struct ifqueue *ifq = NULL;
544 struct ifnet *ifp;
548 va_list ap;
549
545
550 va_start(ap, m);
551 off = va_arg(ap, int);
552 proto = mtod(m, struct ip *)->ip_p;
546 proto = mtod(m, struct ip *)->ip_p;
553 va_end(ap);
554
555 if (proto != IPPROTO_IPV6) {
556 m_freem(m);
557 return;
558 }
559
560 ip = mtod(m, struct ip *);
561

--- 143 unchanged lines hidden ---
547
548 if (proto != IPPROTO_IPV6) {
549 m_freem(m);
550 return;
551 }
552
553 ip = mtod(m, struct ip *);
554

--- 143 unchanged lines hidden ---