Re: Will p_priority be broken?
Re: Will p_priority be broken?
- Subject: Re: Will p_priority be broken?
- From: Godfrey van der Linden <email@hidden>
- Date: Tue, 24 May 2005 13:25:56 -0700
Yup, this would be a problem indeed and thanks for pointing it out.
It turns out, as Sam, pointed out the p_priority field in the struct
proc isn't used at all anymore. We use a similar fields in the
thread schedule stuff.
Godfrey
On 05/23/2005, at 16:32 , Sam Vaughan wrote:
The useless splhigh() and friends have been removed from Darwin 8
so I'm assuming you're referring to Darwin 7 xnu's kern_synch.c here.
As far as I can tell, the p_priority flag isn't used anywhere else
in the kernel, so this is a non-issue. Did you point this out just
from code inspection or are you seeing odd behaviour when kernel
network and file system threads sleep at the same time as each other?
Sam
On 24/05/2005, at 5:05 AM, email@hidden wrote:
_sleep()
{
...
...
s = splhigh();
...
p->p_priority = pri & PRIMASK;
...
}
looks like splhigh() cannot protect p->p_priority from
broken if current_proc() has two threads running in
two different funnels, and they try to change priority
at same time.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden