Project

General

Profile

Bug #1023 ยป if_ether.txt

sepherosa, 05/28/2008 01:40 AM

 
Index: if_ether.c
===================================================================
RCS file: /dcvs/src/sys/netinet/if_ether.c,v
retrieving revision 1.46
diff -u -r1.46 if_ether.c
--- if_ether.c 14 May 2008 11:59:24 -0000 1.46
+++ if_ether.c 28 May 2008 01:28:02 -0000
@@ -953,9 +953,14 @@
void
arp_ifinit(struct ifnet *ifp, struct ifaddr *ifa)
{
- if (IA_SIN(ifa)->sin_addr.s_addr != INADDR_ANY)
+ ASSERT_SERIALIZED(ifp->if_serializer);
+
+ if (IA_SIN(ifa)->sin_addr.s_addr != INADDR_ANY) {
+ lwkt_serialize_exit(ifp->if_serializer);
arprequest(ifp, &IA_SIN(ifa)->sin_addr, &IA_SIN(ifa)->sin_addr,
IF_LLADDR(ifp));
+ lwkt_serialize_enter(ifp->if_serializer);
+ }
ifa->ifa_rtrequest = arp_rtrequest;
ifa->ifa_flags |= RTF_CLONING;
}
    (1-1/1)