Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 19 Jun 2002 18:18:06 -0700 (PDT)
From:      Peter Wemm <peter@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 13180 for review
Message-ID:  <200206200118.g5K1I6H46486@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://people.freebsd.org/~peter/p4db/chv.cgi?CH=13180

Change 13180 by peter@peter_ia64 on 2002/06/19 18:17:24

	GRRRRR.  I've had it with this and the people that ask about it.
	(I'll commit it shortly, but I can test it here easiest)

Affected files ...

... //depot/projects/ia64/sys/netinet/if_ether.c#9 edit

Differences ...

==== //depot/projects/ia64/sys/netinet/if_ether.c#9 (text+ko) ====

@@ -102,7 +102,7 @@
 static	LIST_HEAD(, llinfo_arp) llinfo_arp;
 
 struct	ifqueue arpintrq;
-static int	arp_inuse, arp_allocated;
+static int	arp_inuse, arp_allocated, arpinit_done;
 
 static int	arp_maxtries = 5;
 static int	useloopback = 1; /* use loopback interface for local traffic */
@@ -162,13 +162,10 @@
 	register struct sockaddr *gate = rt->rt_gateway;
 	register struct llinfo_arp *la = (struct llinfo_arp *)rt->rt_llinfo;
 	static struct sockaddr_dl null_sdl = {sizeof(null_sdl), AF_LINK};
-	static int arpinit_done;
 
 	if (!arpinit_done) {
 		arpinit_done = 1;
-		LIST_INIT(&llinfo_arp);
 		timeout(arptimer, (caddr_t)0, hz);
-		register_netisr(NETISR_ARP, arpintr);
 	}
 	if (rt->rt_flags & RTF_GATEWAY)
 		return;
@@ -494,6 +491,10 @@
 	register struct arphdr *ar;
 	int s;
 
+	if (!arpinit_done) {
+		arpinit_done = 1;
+		timeout(arptimer, (caddr_t)0, hz);
+	}
 	while (arpintrq.ifq_head) {
 		s = splimp();
 		IF_DEQUEUE(&arpintrq, m);
@@ -943,6 +944,8 @@
 
 	arpintrq.ifq_maxlen = 50;
 	mtx_init(&arpintrq.ifq_mtx, "arp_inq", NULL, MTX_DEF);
+	LIST_INIT(&llinfo_arp);
+	register_netisr(NETISR_ARP, arpintr);
 }
 
 SYSINIT(arp, SI_SUB_PROTO_DOMAIN, SI_ORDER_ANY, arp_init, 0);

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe p4-projects" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200206200118.g5K1I6H46486>