On Fri, Jul 31, 2009 at 12:33 PM, er krishna <erkris...@gmail.com> wrote:
> > > On Fri, Jul 31, 2009 at 11:21 AM, Vivek Subbarao <viv...@chelsio.com>wrote: > >> >weather the second process has its priority must be higher than the >> running one ? >> >> Yes. Only a process of higher or same priority can pre-empt a process of >> lower priority. >> >> >> >> If pre-empt_count is +ve means that i can be pre-empted then you are >> right. >> > > > If a lower process has taken a lock & its preempt_count value is +ve , can > it be preempted by higher priority process ? > positive value of preempt_count means that kernel preemption is disabled, in that case even high priority process will not be able to preempt low priority process, people please CMIIW > > > > >> >> >> *From:* kernelnewbies-bou...@nl.linux.org [mailto: >> kernelnewbies-bou...@nl.linux.org] *On Behalf Of *er krishna >> *Sent:* 30 July 2009 14:32 >> *To:* kernelnewbies@nl.linux.org >> *Subject:* preemption >> >> >> >> Dear All, >> >> I have some confusion about preemption. Can anybody please clear my query >> : >> >> 1) If there are two process running in kernel space & one of them has a >> lock & its preempt_count value is +ve , can the other process preempt it ? >> If it preempt the first process ( which is in running state with a lock ) , >> then how ( weather the second process has its priority must be higher than >> the running one ? )? >> >> Thanks & Best Regards, >> Krishna >> > > Thanks, Chetan Nanda