Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 13 Dec 2001 11:27:57 -0800 (PST)
From:      John Baldwin <jhb@FreeBSD.org>
To:        Jake Burkholder <jake@locore.ca>
Cc:        cvs-all@FreeBSD.org, cvs-committers@FreeBSD.org
Subject:   Re: cvs commit: src/sys/kern kern_ktr.c src/sys/sys proc.h
Message-ID:  <XFMail.011213112757.jhb@FreeBSD.org>
In-Reply-To: <20011213104749.A12719@locore.ca>

next in thread | previous in thread | raw e-mail | index | archive | help

On 13-Dec-01 Jake Burkholder wrote:
> Apparently, On Thu, Dec 13, 2001 at 02:33:20AM -0800,
>       John Baldwin said words to the effect of;
> 
>> jhb         2001/12/13 02:33:20 PST
>> 
>>   Modified files:
>>     sys/kern             kern_ktr.c 
>>     sys/sys              proc.h 
>>   Log:
>>   Use a per-thread variable for keeping state when a thread is processing
>>   a KTR log entry.  Any KTR requests made while working on an entry are
>>   ignored/discarded to prevent recursion.  This is a better fix for the
>>   hack to futz with the CPU mask and call getnanotime() if KTR_LOCK or
>>   KTR_WITNESS was on.  It also covers the actual formatting of the log entry
>>   including dumping it to the display which the earlier hacks did not.
> 
> This wouldn't be necessary if ktr was still inline and didn't call other
> functions.

No.  Remember the problem we had with nanotime() locking the clock lock and
thus recursing if KTR_LOCK was on on x86?  Even when KTR is inline, it still
calls other functions and you can build up stack and recurse that way.

-- 

John Baldwin <jhb@FreeBSD.org>  <><  http://www.FreeBSD.org/~jhb/
"Power Users Use the Power to Serve!"  -  http://www.FreeBSD.org/

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




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