From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755306AbbBTQ05 (ORCPT ); Fri, 20 Feb 2015 11:26:57 -0500 Received: from bombadil.infradead.org ([198.137.202.9]:58982 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755081AbbBTQ04 (ORCPT ); Fri, 20 Feb 2015 11:26:56 -0500 Date: Fri, 20 Feb 2015 17:26:41 +0100 From: Peter Zijlstra To: Vincent Guittot Cc: Ingo Molnar , linux-kernel , Preeti U Murthy , Morten Rasmussen , Kamalesh Babulal , Rik van Riel , Mike Galbraith , Nicolas Pitre , Dietmar Eggemann , Linaro Kernel Mailman List Subject: Re: [PATCH RESEND v9 10/10] sched: move cfs task on a CPU with higher capacity Message-ID: <20150220162641.GS5029@twins.programming.kicks-ass.net> References: <1421316570-23097-1-git-send-email-vincent.guittot@linaro.org> <1421316570-23097-11-git-send-email-vincent.guittot@linaro.org> <20150220112743.GN5029@twins.programming.kicks-ass.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2012-12-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Feb 20, 2015 at 02:54:09PM +0100, Vincent Guittot wrote: > >> if (rq->nr_running >= 2) > >> + return true; > > > > So this, > >> + sd = rcu_dereference(rq->sd); > >> + if (sd) { > >> + if ((rq->cfs.h_nr_running >= 1) && > >> + check_cpu_capacity(rq, sd)) { > >> + kick = true; > >> + goto unlock; > >> + } > >> + } > > > > vs this: how would we ever get here? > > > > If h_nr_running > 1, must then not nr_running > 1 as well? > > you're right, > but the test above can trig a kick with h_nr_running == 1 whereas the > other tests may not Duh, clearly I cannot read today.