PERFORCE change 132305 for review
John Baldwin
jhb at FreeBSD.org
Wed Jan 2 08:58:07 PST 2008
http://perforce.freebsd.org/chv.cgi?CH=132305
Change 132305 by jhb at jhb_tool on 2008/01/02 16:57:28
Create a spin lock instead of abusing sched_lock.
Affected files ...
.. //depot/projects/smpng/sys/modules/crash/crash.c#39 edit
Differences ...
==== //depot/projects/smpng/sys/modules/crash/crash.c#39 (text+ko) ====
@@ -830,7 +830,9 @@
{
printf("Should panic\n");
- if (mtx_trylock(&sched_lock))
+ bzero(&test1_mtx, sizeof(test1_mtx));
+ mtx_init(&test1_mtx, "test1", NULL, MTX_SPIN | MTX_RECURSE);
+ if (mtx_trylock(&test1_mtx))
printf("Hmm, locked!\n");
else
printf("Not locked\n");
More information about the p4-projects
mailing list