Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 15 Jul 2013 01:41:34 +0000 (UTC)
From:      Craig Rodrigues <rodrigc@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r253347 - head/sys/netgraph/bluetooth/drivers/ubt
Message-ID:  <201307150141.r6F1fYvN084092@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: rodrigc
Date: Mon Jul 15 01:41:34 2013
New Revision: 253347
URL: http://svnweb.freebsd.org/changeset/base/253347

Log:
  PR: kern/168520
  
  Revert GRN 253255.  It is not needed now that GRN 253346 is committed.

Modified:
  head/sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c

Modified: head/sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c
==============================================================================
--- head/sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c	Mon Jul 15 01:32:55 2013	(r253346)
+++ head/sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c	Mon Jul 15 01:41:34 2013	(r253347)
@@ -109,9 +109,7 @@
 #include <sys/unistd.h>
 #include <sys/callout.h>
 #include <sys/malloc.h>
-#include <sys/jail.h>
 #include <sys/priv.h>
-#include <sys/proc.h>
 
 #include "usbdevs.h"
 #include <dev/usb/usb.h>
@@ -125,7 +123,6 @@
 #include <sys/mbuf.h>
 #include <sys/taskqueue.h>
 
-#include <net/vnet.h>
 #include <netgraph/ng_message.h>
 #include <netgraph/netgraph.h>
 #include <netgraph/ng_parse.h>
@@ -490,14 +487,13 @@ ubt_attach(device_t dev)
 
 	sc->sc_dev = dev;
 	sc->sc_debug = NG_UBT_WARN_LEVEL;
-	CURVNET_SET(TD_TO_VNET(curthread));
+
 	/* 
 	 * Create Netgraph node
 	 */
 
 	if (ng_make_node_common(&typestruct, &sc->sc_node) != 0) {
 		UBT_ALERT(sc, "could not create Netgraph node\n");
-		CURVNET_RESTORE();
 		return (ENXIO);
 	}
 
@@ -505,12 +501,10 @@ ubt_attach(device_t dev)
 	if (ng_name_node(sc->sc_node, device_get_nameunit(dev)) != 0) {
 		UBT_ALERT(sc, "could not name Netgraph node\n");
 		NG_NODE_UNREF(sc->sc_node);
-		CURVNET_RESTORE();
 		return (ENXIO);
 	}
 	NG_NODE_SET_PRIVATE(sc->sc_node, sc);
 	NG_NODE_FORCE_WRITER(sc->sc_node);
-	CURVNET_RESTORE();
 
 	/*
 	 * Initialize device softc structure
@@ -637,10 +631,8 @@ ubt_detach(device_t dev)
 	/* Destroy Netgraph node */
 	if (node != NULL) {
 		sc->sc_node = NULL;
-		CURVNET_SET(node->nd_vnet);
 		NG_NODE_REALLY_DIE(node);
 		ng_rmnode_self(node);
-		CURVNET_RESTORE();
 	}
 
 	/* Make sure ubt_task in gone */



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