lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150127141551.GA24151@twins.programming.kicks-ass.net>
Date:	Tue, 27 Jan 2015 15:15:51 +0100
From:	Peter Zijlstra <peterz@...radead.org>
To:	Xunlei Pang <pang.xunlei@...aro.org>
Cc:	linux-kernel@...r.kernel.org, Juri Lelli <juri.lelli@...il.com>
Subject: Re: [PATCH 3/5] sched/deadline: Fix wrong cpudl_find() in
 check_preempt_equal_dl()

On Tue, Jan 27, 2015 at 01:48:15PM +0100, Peter Zijlstra wrote:
> On Mon, Jan 19, 2015 at 04:49:38AM +0000, Xunlei Pang wrote:
> > +++ b/kernel/sched/deadline.c
> > @@ -943,14 +943,23 @@ out:
> >  	return cpu;
> >  }
> >  
> > +static DEFINE_PER_CPU(cpumask_var_t, local_cpu_mask_dl);
> > +
> >  static void check_preempt_equal_dl(struct rq *rq, struct task_struct *p)
> >  {
> > +	struct cpumask *later_mask =
> > +			this_cpu_cpumask_var_ptr(local_cpu_mask_dl);
> > +
> > +	/* Make sure the mask is initialized first */
> > +	if (unlikely(!later_mask))
> > +		return;
> > +
> >  	/*
> >  	 * Current can't be migrated, useless to reschedule,
> >  	 * let's hope p can move out.
> >  	 */
> >  	if (rq->curr->nr_cpus_allowed == 1 ||
> > -	    cpudl_find(&rq->rd->cpudl, rq->curr, NULL) == -1)
> > +	    cpudl_find(&rq->rd->cpudl, rq->curr, later_mask) == -1)
> >  		return;
> >  
> >  	/*
> 
> But but, should you not put something in that mask before you use it?

N/M I can't read.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ