lkml.org 
[lkml]   [2015]   [Sep]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC][PATCH 02/11] sched: Create preempt_count invariant
On Tue, 29 Sep 2015, Peter Zijlstra wrote:
> + /*
> + * Still have preempt_count() == 2, from:
> + *
> + * schedule()
> + * preempt_disable(); // 1
> + * __schedule()
> + * raw_spin_lock_irq(&rq->lock) // 2
> + */
> + rq = finish_task_switch(prev); /* drops rq->lock, preempt_count() == 1 */
> balance_callback(rq);
> - preempt_enable();
> + preempt_enable(); /* preempt_count() == 0 */

Bah. I so hate tail comments. What's wrong with

+ /* preempt_count() ==> 0 */
preempt_enable();

Hmm?

tglx


\
 
 \ /
  Last update: 2015-09-29 15:21    [W:0.242 / U:0.052 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site