PERFORCE change 132129 for review

John Birrell jb at FreeBSD.org
Sun Dec 30 13:48:09 PST 2007


http://perforce.freebsd.org/chv.cgi?CH=132129

Change 132129 by jb at jb_freebsd1 on 2007/12/30 21:48:05

	Move the cloning code to dtrace_load/dtrace_unload so that it is
	driven by SYSINIT and SYSUNINIT.

Affected files ...

.. //depot/projects/dtrace/src/sys/cddl/dev/dtrace/dtrace_modevent.c#8 edit

Differences ...

==== //depot/projects/dtrace/src/sys/cddl/dev/dtrace/dtrace_modevent.c#8 (text+ko) ====

@@ -30,30 +30,9 @@
 
 	switch (type) {
 	case MOD_LOAD:
-
-		/* Enable device cloning. */
-		clone_setup(&dtrace_clones);
-
-		/* Setup device cloning events. */
-		eh_tag = EVENTHANDLER_REGISTER(dev_clone, dtrace_clone, 0, 1000);
 		break;
 
 	case MOD_UNLOAD:
-		if ((error = dtrace_unload()) != 0)
-			return (error);
-
-		/*
-		 * Check if there is still an event handler callback
-		 * registered.
-		 */
-		if (eh_tag != 0) {
-			/* De-register the device cloning event handler. */
-			EVENTHANDLER_DEREGISTER(dev_clone, eh_tag);
-			eh_tag = 0;
-
-			/* Stop device cloning. */
-			clone_cleanup(&dtrace_clones);
-		}
 		break;
 
 	case MOD_SHUTDOWN:


More information about the p4-projects mailing list