summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorwollman <wollman@FreeBSD.org>1995-12-20 21:53:53 +0000
committerwollman <wollman@FreeBSD.org>1995-12-20 21:53:53 +0000
commit3bc72fd2150906e2400079d7a0a69c55eb69bc64 (patch)
tree9608e4a13c02893d6405aad4abe15ae32a37101a /sys
parent19914706e411f628cfd36b7f46094cb62d6b815e (diff)
downloadFreeBSD-src-3bc72fd2150906e2400079d7a0a69c55eb69bc64.zip
FreeBSD-src-3bc72fd2150906e2400079d7a0a69c55eb69bc64.tar.gz
in_proto.c: spell ``Internet'' right and put whitespace after commas.
others: start to populate the link-layer branch of the net mib, by moving ARP to its proper place. (ARP is not a protocol family, it's an interface layer between a medium-access layer and a protocol family.) sysctl(8) needs to be taught about the structure of this branch, unless Poul-Henning implements dynamic MIB exploration soon.
Diffstat (limited to 'sys')
-rw-r--r--sys/net/if.c5
-rw-r--r--sys/net/if_ethersubr.c5
-rw-r--r--sys/netinet/if_ether.c38
-rw-r--r--sys/netinet/in_proto.c15
4 files changed, 35 insertions, 28 deletions
diff --git a/sys/net/if.c b/sys/net/if.c
index bcebdb2..4525600 100644
--- a/sys/net/if.c
+++ b/sys/net/if.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)if.c 8.3 (Berkeley) 1/4/94
- * $Id: if.c,v 1.23 1995/12/05 02:01:36 davidg Exp $
+ * $Id: if.c,v 1.24 1995/12/09 20:47:08 phk Exp $
*/
#include <sys/param.h>
@@ -45,6 +45,7 @@
#include <sys/ioctl.h>
#include <sys/errno.h>
#include <sys/syslog.h>
+#include <sys/sysctl.h>
#include <net/if.h>
#include <net/if_dl.h>
@@ -756,3 +757,5 @@ sprint_d(n, buf, buflen)
} while (n != 0);
return (cp);
}
+
+SYSCTL_NODE(_net, PF_LINK, link, CTLFLAG_RW, 0, "Link layers");
diff --git a/sys/net/if_ethersubr.c b/sys/net/if_ethersubr.c
index b349efa..c4e5dbc 100644
--- a/sys/net/if_ethersubr.c
+++ b/sys/net/if_ethersubr.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)if_ethersubr.c 8.1 (Berkeley) 6/10/93
- * $Id: if_ethersubr.c,v 1.11 1995/10/29 15:32:03 phk Exp $
+ * $Id: if_ethersubr.c,v 1.12 1995/12/09 20:47:11 phk Exp $
*/
#include <sys/param.h>
@@ -44,6 +44,7 @@
#include <sys/ioctl.h>
#include <sys/errno.h>
#include <sys/syslog.h>
+#include <sys/sysctl.h>
#include <machine/cpu.h>
@@ -712,3 +713,5 @@ ether_delmulti(ifr, ac)
*/
return (ENETRESET);
}
+
+SYSCTL_NODE(_net_link, IFT_ETHER, ether, CTLFLAG_RW, 0, "Ethernet");
diff --git a/sys/netinet/if_ether.c b/sys/netinet/if_ether.c
index d938547..a0ce6cf 100644
--- a/sys/netinet/if_ether.c
+++ b/sys/netinet/if_ether.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)if_ether.c 8.1 (Berkeley) 6/10/93
- * $Id: if_ether.c,v 1.23 1995/12/14 09:53:37 phk Exp $
+ * $Id: if_ether.c,v 1.24 1995/12/16 00:05:40 bde Exp $
*/
/*
@@ -61,20 +61,19 @@
#define SIN(s) ((struct sockaddr_in *)s)
#define SDL(s) ((struct sockaddr_dl *)s)
-SYSCTL_NODE(_net, OID_AUTO, arp, CTLFLAG_RW, 0, "");
+SYSCTL_NODE(_net_link_ether, PF_INET, inet, CTLFLAG_RW, 0, "");
/* timer values */
-static int arpt_prune = (5*60*1);
- /* walk list every 5 minutes */
-SYSCTL_INT(_net_arp, OID_AUTO, t_prune, CTLFLAG_RW, &arpt_prune, 0, "");
+static int arpt_prune = (5*60*1); /* walk list every 5 minutes */
+static int arpt_keep = (20*60); /* once resolved, good for 20 more minutes */
+static int arpt_down = 20; /* once declared down, don't send for 20 sec */
-static int arpt_keep = (20*60);
- /* once resolved, good for 20 more minutes */
-SYSCTL_INT(_net_arp, OID_AUTO, t_keep, CTLFLAG_RW, &arpt_keep, 0, "");
-
-static int arpt_down = 20;
- /* once declared down, don't send for 20 secs */
-SYSCTL_INT(_net_arp, OID_AUTO, t_down, CTLFLAG_RW, &arpt_down, 0, "");
+SYSCTL_INT(_net_link_ether_inet, OID_AUTO, prune_intvl, CTLFLAG_RW,
+ &arpt_prune, 0, "");
+SYSCTL_INT(_net_link_ether_inet, OID_AUTO, max_age, CTLFLAG_RW,
+ &arpt_keep, 0, "");
+SYSCTL_INT(_net_link_ether_inet, OID_AUTO, host_down_time, CTLFLAG_RW,
+ &arpt_down, 0, "");
#define rt_expire rt_rmx.rmx_expire
@@ -92,14 +91,15 @@ struct ifqueue arpintrq = {0, 0, 0, 50};
static int arp_inuse, arp_allocated;
static int arp_maxtries = 5;
-SYSCTL_INT(_net_arp, OID_AUTO, maxtries, CTLFLAG_RW, &arp_maxtries, 0, "");
-
-static int useloopback = 1;
- /* use loopback interface for local traffic */
-SYSCTL_INT(_net_arp, OID_AUTO, useloopback, CTLFLAG_RW, &useloopback, 0, "");
-
+static int useloopback = 1; /* use loopback interface for local traffic */
static int arp_proxyall = 0;
-SYSCTL_INT(_net_arp, OID_AUTO, proxyall, CTLFLAG_RW, &arp_proxyall, 0, "");
+
+SYSCTL_INT(_net_link_ether_inet, OID_AUTO, maxtries, CTLFLAG_RW,
+ &arp_maxtries, 0, "");
+SYSCTL_INT(_net_link_ether_inet, OID_AUTO, useloopback, CTLFLAG_RW,
+ &useloopback, 0, "");
+SYSCTL_INT(_net_link_ether_inet, OID_AUTO, proxyall, CTLFLAG_RW,
+ &arp_proxyall, 0, "");
static void arp_rtrequest __P((int, struct rtentry *, struct sockaddr *));
static void arprequest __P((struct arpcom *, u_long *, u_long *, u_char *));
diff --git a/sys/netinet/in_proto.c b/sys/netinet/in_proto.c
index 802b580..8826fa7 100644
--- a/sys/netinet/in_proto.c
+++ b/sys/netinet/in_proto.c
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)in_proto.c 8.2 (Berkeley) 2/9/95
- * $Id: in_proto.c,v 1.22 1995/11/20 12:28:16 phk Exp $
+ * $Id: in_proto.c,v 1.23 1995/12/02 19:37:53 bde Exp $
*/
#include <sys/param.h>
@@ -182,13 +182,14 @@ struct domain inetdomain =
DOMAIN_SET(inet);
-SYSCTL_NODE(_net,PF_INET, inet,CTLFLAG_RW,0, "InterNet Protocols");
+SYSCTL_NODE(_net, PF_INET, inet, CTLFLAG_RW, 0,
+ "Internet Family");
-SYSCTL_NODE(_net_inet,IPPROTO_IP, ip, CTLFLAG_RW,0, "IP");
-SYSCTL_NODE(_net_inet,IPPROTO_ICMP,icmp,CTLFLAG_RW,0, "ICMP");
-SYSCTL_NODE(_net_inet,IPPROTO_UDP, udp, CTLFLAG_RW,0, "UDP");
-SYSCTL_NODE(_net_inet,IPPROTO_TCP, tcp, CTLFLAG_RW,0, "TCP");
-SYSCTL_NODE(_net_inet,IPPROTO_IGMP,igmp,CTLFLAG_RW,0, "IGMP");
+SYSCTL_NODE(_net_inet, IPPROTO_IP, ip, CTLFLAG_RW, 0, "IP");
+SYSCTL_NODE(_net_inet, IPPROTO_ICMP, icmp, CTLFLAG_RW, 0, "ICMP");
+SYSCTL_NODE(_net_inet, IPPROTO_UDP, udp, CTLFLAG_RW, 0, "UDP");
+SYSCTL_NODE(_net_inet, IPPROTO_TCP, tcp, CTLFLAG_RW, 0, "TCP");
+SYSCTL_NODE(_net_inet, IPPROTO_IGMP, igmp, CTLFLAG_RW, 0, "IGMP");
#include "imp.h"
#if NIMP > 0
OpenPOWER on IntegriCloud