Date: Sat, 29 Apr 2006 02:16:10 GMT From: John Birrell <jb@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 96348 for review Message-ID: <200604290216.k3T2GAre053975@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=96348 Change 96348 by jb@jb_freebsd2 on 2006/04/29 02:15:29 Change the way the unload works. If we reject the unload while there are providers and leave the module loaded, we want to keep the event callback registered. Affected files ... .. //depot/projects/dtrace/src/sys/cddl/dev/dtrace/dtrace_modevent.c#6 edit Differences ... ==== //depot/projects/dtrace/src/sys/cddl/dev/dtrace/dtrace_modevent.c#6 (text+ko) ==== @@ -30,7 +30,7 @@ switch (type) { case MOD_LOAD: - printf("--------------------------------------------------------\n"); + printf("dtrace -------------------------------------------------\n"); if ((error = dtrace_load()) == 0) { /* Enable device cloning. */ clone_setup(&dtrace_clones); @@ -41,6 +41,9 @@ break; case MOD_UNLOAD: + if ((error = dtrace_unload()) != 0) + return (error); + /* * Check if there is still an event handler callback * registered. @@ -53,9 +56,6 @@ /* Stop device cloning. */ clone_cleanup(&dtrace_clones); } - - error = dtrace_unload(); -if (error != 0) printf("dtrace_modevent: error %d\n",error); break; case MOD_SHUTDOWN:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200604290216.k3T2GAre053975>