• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.5.8/xnu-1228.15.4/bsd/netinet6/

Lines Matching defs:icmp6

1 /*	$FreeBSD: src/sys/netinet6/icmp6.c,v 1.6.2.6 2001/07/10 09:44:16 ume Exp $	*/
2 /* $KAME: icmp6.c,v 1.211 2001/04/04 05:56:20 itojun Exp $ */
91 #include <netinet/icmp6.h>
222 struct icmp6_hdr *icmp6;
293 * informational) we must not send icmp6 error.
337 icmp6 = (struct icmp6_hdr *)(nip6 + 1);
338 icmp6->icmp6_type = type;
339 icmp6->icmp6_code = code;
340 icmp6->icmp6_pptr = htonl((u_int32_t)param);
373 struct icmp6_hdr *icmp6, *nicmp6;
384 * Locate icmp6 structure in mbuf, and check
398 icmp6 = (struct icmp6_hdr *)((caddr_t)ip6 + off);
400 IP6_EXTHDR_GET(icmp6, struct icmp6_hdr *, m, off, sizeof(*icmp6));
401 if (icmp6 == NULL) {
406 code = icmp6->icmp6_code;
411 icmp6->icmp6_type, sum, ip6_sprintf(&ip6->ip6_src)));
423 switch (icmp6->icmp6_type) {
434 icmp6stat.icp6s_inhist[icmp6->icmp6_type]++;
436 if (icmp6->icmp6_type < ICMP6_INFOMSG_MASK)
439 switch (icmp6->icmp6_type) {
520 if (icmp6_ratelimit(&ip6->ip6_dst, icmp6->icmp6_type, code)) {
566 bcopy(icmp6, nicmp6, sizeof(struct icmp6_hdr));
604 if (icmp6->icmp6_type == MLD6_LISTENER_QUERY) /* XXX: ugly... */
609 if (icmp6_ratelimit(&ip6->ip6_dst, icmp6->icmp6_type, code)) {
652 if (icmp6_ratelimit(&ip6->ip6_dst, icmp6->icmp6_type, code)) {
681 if (icmp6_ratelimit(&ip6->ip6_dst, icmp6->icmp6_type, code)) {
704 if (icmp6_ratelimit(&ip6->ip6_dst, icmp6->icmp6_type, code)) {
727 if (icmp6_ratelimit(&ip6->ip6_dst, icmp6->icmp6_type, code)) {
750 if (icmp6_ratelimit(&ip6->ip6_dst, icmp6->icmp6_type, code)) {
773 if (icmp6_ratelimit(&ip6->ip6_dst, icmp6->icmp6_type, code)) {
798 if (icmp6_ratelimit(&ip6->ip6_dst, icmp6->icmp6_type, code)) {
805 icmp6->icmp6_type, ip6_sprintf(&ip6->ip6_src),
808 if (icmp6->icmp6_type < ICMP6_ECHO_REQUEST) {
818 if (icmp6_ratelimit(&ip6->ip6_dst, icmp6->icmp6_type, code)) {
838 if (icmp6_ratelimit(&ip6->ip6_dst, icmp6->icmp6_type, code)) {
858 struct icmp6_hdr *icmp6;
871 icmp6 = (struct icmp6_hdr *)(mtod(m, caddr_t) + off);
873 IP6_EXTHDR_GET(icmp6, struct icmp6_hdr *, m, off,
874 sizeof(*icmp6) + sizeof(struct ip6_hdr));
875 if (icmp6 == NULL) {
880 eip6 = (struct ip6_hdr *)(icmp6 + 1);
890 int icmp6type = icmp6->icmp6_type;
1021 icmp6 = (struct icmp6_hdr *)(mtod(m, caddr_t) + off);
1023 IP6_EXTHDR_GET(icmp6, struct icmp6_hdr *, m, off,
1024 sizeof(*icmp6) + sizeof(struct ip6_hdr));
1025 if (icmp6 == NULL) {
1031 eip6 = (struct ip6_hdr *)(icmp6 + 1);
1076 ip6cp.ip6c_icmp6 = icmp6;
1077 ip6cp.ip6c_ip6 = (struct ip6_hdr *)(icmp6 + 1);
1084 notifymtu = ntohl(icmp6->icmp6_mtu);
1109 struct icmp6_hdr *icmp6 = ip6cp->ip6c_icmp6;
1111 u_int mtu = ntohl(icmp6->icmp6_mtu);
1913 struct icmp6_hdr *icmp6;
1918 icmp6 = (struct icmp6_hdr *)((caddr_t)ip6 + off);
1920 IP6_EXTHDR_GET(icmp6, struct icmp6_hdr *, m, off, sizeof(*icmp6));
1921 if (icmp6 == NULL) {
1951 && ICMP6_FILTER_WILLBLOCK(icmp6->icmp6_type,
1990 * OFF points to the icmp6 header, counted from the top of the mbuf.
1998 struct icmp6_hdr *icmp6;
2051 icmp6 = (struct icmp6_hdr *)(ip6 + 1);
2052 type = icmp6->icmp6_type; /* keep type for statistics */
2053 code = icmp6->icmp6_code; /* ditto. */
2174 icmp6->icmp6_cksum = 0;
2175 icmp6->icmp6_cksum = in6_cksum(m, IPPROTO_ICMPV6,
2247 /* XXX if we are router, we don't update route by icmp6 redirect */
2286 /* ip6->ip6_src must be equal to gw for icmp6->icmp6_reddst */
2372 "(if %d, icmp6 packet %d): %s\n",
2456 /* if we are not router, we don't send icmp6 redirect */
2614 * compute the maximum size for icmp6 redirect header option.
2862 struct icmp6_hdr *icmp6;
2898 icmp6 = mtod(m, struct icmp6_hdr *);
2904 if (icmp6->icmp6_type != 128 || icmp6->icmp6_code != 0) {
3027 * Returns 0 if it is okay to send the icmp6 packet.
3028 * Returns 1 if the router SHOULD NOT send this icmp6 packet due to rate