lkml.org 
[lkml]   [2011]   [May]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH] sched: fix need_resched() when checking peempt
From
On Tue, May 24, 2011 at 9:50 PM, Hillf Danton <dhillf@gmail.com> wrote:
> On Tue, May 24, 2011 at 9:39 PM, Steven Rostedt <rostedt@goodmis.org> wrote:
>> On Tue, 2011-05-24 at 21:27 +0800, Hillf Danton wrote:
>>> When checking if current task could be preempted by a newly woken task,
>>> further check could be bypassed if the current thread is different from
>>> the current task of run-queue, and it is corrected accordingly.
>>
>> Ug, that change log is an obfuscated mess. But looking at the actual
>> patch, I figured what you wanted to say. How about this:
>>
>> ----
>> The RT preempt check tests the wrong task if NEED_RESCHED is set. It
>> currently checks the local CPU task. It is suppose to check the task
>> that is running on the run queue we are about to wake another task on.
>> ----
>>
> Thanks, it is great changelog:)

Good catch.

Reviewed-by: Yong Zhang <yong.zhang0@gmail.com>

BTW, this may be the reason for we could trigger
WARN_ON_ONCE(test_tsk_need_resched(next));
https://lkml.org/lkml/2010/12/20/28

Peter, Mike, how do you think about it?

Thanks,
Yong


--
Only stand for myself


\
 
 \ /
  Last update: 2011-05-25 05:27    [W:0.340 / U:0.220 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site