diff options
-rw-r--r-- | sys/net/if_gre.c | 4 | ||||
-rw-r--r-- | sys/net/if_gre.h | 18 | ||||
-rw-r--r-- | sys/netinet/ip_gre.c | 6 |
3 files changed, 14 insertions, 14 deletions
diff --git a/sys/net/if_gre.c b/sys/net/if_gre.c index 47a74a3..7eb1732 100644 --- a/sys/net/if_gre.c +++ b/sys/net/if_gre.c @@ -398,7 +398,7 @@ gre_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data) case SIOCSIFADDR: ifp->if_flags |= IFF_UP; break; - case SIOCSIFDSTADDR: + case SIOCSIFDSTADDR: break; case SIOCSIFFLAGS: if ((error = suser(curthread)) != 0) @@ -489,7 +489,7 @@ gre_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data) dm.sin_family = AF_INET; sp.sin_addr = sc->g_src; dp.sin_addr = sc->g_dst; - sm.sin_addr.s_addr = dm.sin_addr.s_addr = + sm.sin_addr.s_addr = dm.sin_addr.s_addr = INADDR_BROADCAST; #ifdef INET sc->encap = encap_attach(AF_INET, sc->g_proto, diff --git a/sys/net/if_gre.h b/sys/net/if_gre.h index 5f8f373..73fed0b 100644 --- a/sys/net/if_gre.h +++ b/sys/net/if_gre.h @@ -23,7 +23,7 @@ * 4. Neither the name of The NetBSD Foundation nor the names of its * contributors may be used to endorse or promote products derived * from this software without specific prior written permission. - * + * * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR @@ -58,15 +58,15 @@ struct gre_softc { const struct encaptab *encap; /* encapsulation cookie */ int called; /* infinite recursion preventer */ -}; +}; struct gre_h { u_int16_t flags; /* GRE flags */ - u_int16_t ptype; /* protocol type of payload typically + u_int16_t ptype; /* protocol type of payload typically Ether protocol type*/ -/* - * from here on: fields are optional, presence indicated by flags +/* + * from here on: fields are optional, presence indicated by flags * u_int_16 checksum checksum (one-complements of GRE header and payload @@ -118,7 +118,7 @@ struct greip { struct gre_sre { u_int16_t sre_family; /* address family */ u_char sre_offset; /* offset to first octet of active entry */ - u_char sre_length; /* number of octets in the SRE. + u_char sre_length; /* number of octets in the SRE. sre_lengthl==0 -> last entry. */ u_char *sre_rtinfo; /* the routing information */ }; @@ -151,12 +151,12 @@ struct mobip_h { #endif /* _KERNEL */ -/* - * ioctls needed to manipulate the interface +/* + * ioctls needed to manipulate the interface */ #define GRESADDRS _IOW('i', 101, struct ifreq) -#define GRESADDRD _IOW('i', 102, struct ifreq) +#define GRESADDRD _IOW('i', 102, struct ifreq) #define GREGADDRS _IOWR('i', 103, struct ifreq) #define GREGADDRD _IOWR('i', 104, struct ifreq) #define GRESPROTO _IOW('i' , 105, struct ifreq) diff --git a/sys/netinet/ip_gre.c b/sys/netinet/ip_gre.c index a2fdb9f..1abef16 100644 --- a/sys/netinet/ip_gre.c +++ b/sys/netinet/ip_gre.c @@ -119,7 +119,7 @@ gre_input(m, va_alist) ret = gre_input2(m, off, proto); /* - * ret == 0 : packet not processed, meaning that + * ret == 0 : packet not processed, meaning that * no matching tunnel that is up is found. * we inject it to raw ip socket to see if anyone picks it up. */ @@ -179,7 +179,7 @@ gre_input2(struct mbuf *m ,int hlen, u_char proto) switch (ntohs(gip->gi_ptype)) { /* ethertypes */ case ETHERTYPE_IP: /* shouldn't need a schednetisr(), as */ case WCCP_PROTOCOL_TYPE: /* we are in ip_input */ - isr = NETISR_IP; + isr = NETISR_IP; break; #ifdef NETATALK case ETHERTYPE_ATALK: @@ -295,7 +295,7 @@ gre_mobile_input(m, va_alist) * and full size of IP packet), so that adjust accordingly. */ ip->ip_len = htons(ip->ip_len + sizeof(struct ip) - msiz); - + ip->ip_sum = 0; ip->ip_sum = in_cksum(m, (ip->ip_hl << 2)); |