lkml.org 
[lkml]   [2015]   [Jun]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 01/10] cpumask: Introduce cpumask_any_online_but
On Mon, 15 Jun 2015, Vikas Shivappa wrote:
> On Mon, 15 Jun 2015, Peter Zijlstra wrote:
> > On Fri, Jun 12, 2015 at 11:17:08AM -0700, Vikas Shivappa wrote:
> > > + cpumask_and(&tmp, cpu_online_mask, mask);
> > > + cpumask_clear_cpu(cpu, &tmp);
> > > + return cpumask_any(&tmp);
> > > +}
> >
> > You had a good example in cpumask_any_but() copy that.
>
> I saw the cpumask_any_but but wanted to avoid the for loop in the
> cpumask_any_but , but now i see why from your previous comment. Without the
> cpumask_t I will have to use the cpumask_any_but .. the two were related.

It can be done w/o a loop. Hint, you need a static cpumask in your
code anyway.

Thanks

tglx


\
 
 \ /
  Last update: 2015-06-16 10:41    [W:0.066 / U:24.672 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site