[BACK]Return to ip_input.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / netinet

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/sys/netinet/ip_input.c between version 1.349 and 1.352

version 1.349, 2017/02/07 02:38:08 version 1.352, 2017/03/06 07:31:15
Line 353  ip_init(void)
Line 353  ip_init(void)
         ipforward_rt_percpu = percpu_alloc(sizeof(struct route));          ipforward_rt_percpu = percpu_alloc(sizeof(struct route));
         if (ipforward_rt_percpu == NULL)          if (ipforward_rt_percpu == NULL)
                 panic("failed to allocate ipforward_rt_percpu");                  panic("failed to allocate ipforward_rt_percpu");
   
           ip_mtudisc_timeout_q = rt_timer_queue_create(ip_mtudisc_timeout);
 }  }
   
 static struct in_ifaddr *  static struct in_ifaddr *
Line 1601  sysctl_net_inet_ip_pmtudto(SYSCTLFN_ARGS
Line 1603  sysctl_net_inet_ip_pmtudto(SYSCTLFN_ARGS
         int error, tmp;          int error, tmp;
         struct sysctlnode node;          struct sysctlnode node;
   
           icmp_mtudisc_lock();
   
         node = *rnode;          node = *rnode;
         tmp = ip_mtudisc_timeout;          tmp = ip_mtudisc_timeout;
         node.sysctl_data = &tmp;          node.sysctl_data = &tmp;
         error = sysctl_lookup(SYSCTLFN_CALL(&node));          error = sysctl_lookup(SYSCTLFN_CALL(&node));
         if (error || newp == NULL)          if (error || newp == NULL)
                 return (error);                  goto out;
         if (tmp < 0)          if (tmp < 0) {
                 return (EINVAL);                  error = EINVAL;
                   goto out;
         /* XXX NOMPSAFE still need softnet_lock */          }
         mutex_enter(softnet_lock);  
   
         ip_mtudisc_timeout = tmp;          ip_mtudisc_timeout = tmp;
         rt_timer_queue_change(ip_mtudisc_timeout_q, ip_mtudisc_timeout);          rt_timer_queue_change(ip_mtudisc_timeout_q, ip_mtudisc_timeout);
           error = 0;
         mutex_exit(softnet_lock);  out:
           icmp_mtudisc_unlock();
         return (0);          return error;
 }  }
   
 static int  static int

Legend:
Removed from v.1.349  
changed lines
  Added in v.1.352

CVSweb <webmaster@jp.NetBSD.org>