Module Name:    src
Committed By:   ozaki-r
Date:           Thu Dec 22 03:46:51 UTC 2016

Modified Files:
        src/sys/net: if.h
        src/sys/netinet6: nd6.c

Log Message:
Remove assertion that the lock isn't held

It's useless in this case, because without it we can know that
the lock is held or not on a next lock acquisition and even more
if LOCKDEBUG is enabled a failure on the acquisition will provide
useful information for debugging while an assertion failure will
provide just the fact that the assertion failed.


To generate a diff of this commit:
cvs rdiff -u -r1.232 -r1.233 src/sys/net/if.h
cvs rdiff -u -r1.222 -r1.223 src/sys/netinet6/nd6.c

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

Modified files:

Index: src/sys/net/if.h
diff -u src/sys/net/if.h:1.232 src/sys/net/if.h:1.233
--- src/sys/net/if.h:1.232	Tue Dec 13 02:05:48 2016
+++ src/sys/net/if.h	Thu Dec 22 03:46:51 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: if.h,v 1.232 2016/12/13 02:05:48 ozaki-r Exp $	*/
+/*	$NetBSD: if.h,v 1.233 2016/12/22 03:46:51 ozaki-r Exp $	*/
 
 /*-
  * Copyright (c) 1999, 2000, 2001 The NetBSD Foundation, Inc.
@@ -510,8 +510,6 @@ if_is_link_state_changeable(struct ifnet
 	KASSERT(rw_read_held((ifp)->if_afdata_lock))
 #define	IF_AFDATA_WLOCK_ASSERT(ifp)	\
 	KASSERT(rw_write_held((ifp)->if_afdata_lock))
-#define	IF_AFDATA_UNLOCK_ASSERT(ifp)	\
-	KASSERT(!rw_lock_held((ifp)->if_afdata_lock))
 
 /*
  * Output queues (ifp->if_snd) and internetwork datagram level (pup level 1)

Index: src/sys/netinet6/nd6.c
diff -u src/sys/netinet6/nd6.c:1.222 src/sys/netinet6/nd6.c:1.223
--- src/sys/netinet6/nd6.c:1.222	Wed Dec 21 08:47:02 2016
+++ src/sys/netinet6/nd6.c	Thu Dec 22 03:46:51 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: nd6.c,v 1.222 2016/12/21 08:47:02 ozaki-r Exp $	*/
+/*	$NetBSD: nd6.c,v 1.223 2016/12/22 03:46:51 ozaki-r Exp $	*/
 /*	$KAME: nd6.c,v 1.279 2002/06/08 11:16:51 itojun Exp $	*/
 
 /*
@@ -31,7 +31,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: nd6.c,v 1.222 2016/12/21 08:47:02 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: nd6.c,v 1.223 2016/12/22 03:46:51 ozaki-r Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_net_mpsafe.h"
@@ -1146,7 +1146,6 @@ nd6_is_addr_neighbor(const struct sockad
 	}
 	ND6_UNLOCK();
 
-	IF_AFDATA_UNLOCK_ASSERT(ifp);
 	if (nd6_is_new_addr_neighbor(addr, ifp))
 		return 1;
 

Reply via email to