Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 19 Jan 2004 09:57:13 -0800 (PST)
From:      Sam Leffler <sam@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 45602 for review
Message-ID:  <200401191757.i0JHvDH7086854@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=45602

Change 45602 by sam@sam_ebb on 2004/01/19 09:56:28

	remove debugging stuff unintentionally brought in during merge

Affected files ...

.. //depot/projects/netperf_socket/sys/netinet/ip_mroute.c#3 edit

Differences ...

==== //depot/projects/netperf_socket/sys/netinet/ip_mroute.c#3 (text+ko) ====

@@ -74,8 +74,6 @@
 #define		DEBUG_EXPIRE	0x08
 #define		DEBUG_XMIT	0x10
 #define		DEBUG_PIM	0x20
-SYSCTL_INT(_net_inet_ip, OID_AUTO, mrtdebug, CTLFLAG_RW,
-	&mrtdebug, 0, "multicast routing debug control");
 
 #define		VIFI_INVALID	((vifi_t) -1)
 
@@ -614,27 +612,17 @@
 ip_mrouter_init(struct socket *so, int version)
 {
     if (mrtdebug)
-	log(LOG_DEBUG, "%s: so_type = %d, pr_protocol = %d\n", __func__,
+	log(LOG_DEBUG, "ip_mrouter_init: so_type = %d, pr_protocol = %d\n",
 	    so->so_type, so->so_proto->pr_protocol);
 
-    if (so->so_type != SOCK_RAW || so->so_proto->pr_protocol != IPPROTO_IGMP) {
-	if (mrtdebug)
-	    log(LOG_DEBUG, "%s: invalid socket, type %u protocol %u\n",
-		__func__, so->so_type, so->so_proto->pr_protocol);
+    if (so->so_type != SOCK_RAW || so->so_proto->pr_protocol != IPPROTO_IGMP)
 	return EOPNOTSUPP;
-    }
 
-    if (version != 1) {
-	if (mrtdebug)
-	    log(LOG_DEBUG, "%s: bad version %u, expecting 1\n",
-		__func__, version);
+    if (version != 1)
 	return ENOPROTOOPT;
-    }
 
     mtx_lock(&mrouter_mtx);
 
-    mtx_lock(&mrouter_mtx);
-
     if (ip_mrouter != NULL) {
 	mtx_unlock(&mrouter_mtx);
 	return EADDRINUSE;
@@ -651,7 +639,7 @@
     mtx_unlock(&mrouter_mtx);
 
     if (mrtdebug)
-	log(LOG_DEBUG, "%s: done\n", __func__);
+	log(LOG_DEBUG, "ip_mrouter_init\n");
 
     return 0;
 }
@@ -757,7 +745,7 @@
     mtx_unlock(&mrouter_mtx);
 
     if (mrtdebug)
-	log(LOG_DEBUG, "%s: end\n", __func__);
+	log(LOG_DEBUG, "ip_mrouter_done\n");
 
     return 0;
 }



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