On Tue, 10 Nov 2015 14:23:24 +0100 Peter Zijlstra <pet...@infradead.org> wrote:
> > +/* protect injection parameters from runtime changes */ > > +static DEFINE_SPINLOCK(idle_inject_lock); > > A global lock, yay :-), I think you want this to be a RAW_SPINLOCK > though. As on -RT this would want to actually run from IRQ context > too. > I am not using this lock in per cpu timer handler, I guess it would not be in IRQ context? > > + if (bitmap_weight(idle_inject_cpumask, > > num_possible_cpus())) { > > I don't get the point of this bitmap; with the cpu notifier you > basically ensure this is equal to online_mask. > > Also, this weight test is pointless, if the bitmap is empty the > for_each_set_bit() should be of equal cost -- and afaict nothing > calling this is performance critical in the first place. Agreed, I will remove that. I was planning on a subset of CPUs but not for now, e.g. a socket or domain. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/