Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753287AbbG2NBw (ORCPT ); Wed, 29 Jul 2015 09:01:52 -0400 Received: from mail-wi0-f176.google.com ([209.85.212.176]:35212 "EHLO mail-wi0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751228AbbG2NBv (ORCPT ); Wed, 29 Jul 2015 09:01:51 -0400 Date: Wed, 29 Jul 2015 15:01:48 +0200 From: Frederic Weisbecker To: Chris Metcalf Cc: LKML , Peter Zijlstra , Thomas Gleixner , Preeti U Murthy , Christoph Lameter , Ingo Molnar , Viresh Kumar , Rik van Riel Subject: Re: [PATCH 07/10] sched: Migrate sched to use new tick dependency mask model Message-ID: <20150729130147.GB11554@lerouge> References: <1437669735-8786-1-git-send-email-fweisbec@gmail.com> <1437669735-8786-8-git-send-email-fweisbec@gmail.com> <55B26E4A.80209@ezchip.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <55B26E4A.80209@ezchip.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 986 Lines: 31 On Fri, Jul 24, 2015 at 12:56:42PM -0400, Chris Metcalf wrote: > On 07/23/2015 12:42 PM, Frederic Weisbecker wrote: > >+static inline void sched_update_tick_dependency(struct rq *rq) > >+{ > >+ int cpu; > >+ > >+ if (!tick_nohz_full_enabled()) > >+ return; > >+ > >+ cpu = cpu_of(rq); > >+ > >+ if (!tick_nohz_full_cpu(rq->cpu)) > >+ return; > >+ > >+ if (sched_can_stop_tick(rq)) > >+ tick_nohz_clear_tick_dependency_cpu(TICK_SCHED_BIT, cpu); > >+ else > >+ tick_nohz_set_tick_dependency_cpu(TICK_SCHED_BIT, cpu); > >+} > > Is it worth asserting that the rq is locked at this point? Presumably that's > a requirement so that the cpu can't change out from under you. Indeed it has become a requirement here. I'll add a check. Thanks. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/