From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932893AbcIBQas (ORCPT ); Fri, 2 Sep 2016 12:30:48 -0400 Received: from merlin.infradead.org ([205.233.59.134]:52260 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932338AbcIBQaq (ORCPT ); Fri, 2 Sep 2016 12:30:46 -0400 Date: Fri, 2 Sep 2016 18:30:40 +0200 From: Peter Zijlstra To: Paolo Bonzini Cc: Frederic Weisbecker , LKML , Wanpeng Li , Eric Dumazet , Ingo Molnar , Mike Galbraith , Rik van Riel Subject: Re: [PATCH 2/5] irqtime: Remove needless IRQs disablement on kcpustat update Message-ID: <20160902163040.GI10153@twins.programming.kicks-ass.net> References: <1472824985-22947-1-git-send-email-fweisbec@gmail.com> <1472824985-22947-3-git-send-email-fweisbec@gmail.com> <6c9a4f26-0b0a-ccd1-7125-b15ceed2f2c0@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <6c9a4f26-0b0a-ccd1-7125-b15ceed2f2c0@redhat.com> User-Agent: Mutt/1.5.23.1 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Sep 02, 2016 at 04:53:47PM +0200, Paolo Bonzini wrote: > > > On 02/09/2016 16:03, Frederic Weisbecker wrote: > > The callers of the functions performing irqtime kcpustat updates have > > IRQS disabled, no need to disable them again. > > They do, but perhaps this should be annotated through some sparse magic. > It's starting to be hairy, with the requirement spanning many separate > files. Sparse sucks for those things... maybe just add something like lockdep_assert_irqsoff(). Such a call both documents the requirement and validates at runtime when CONFIG_LOCKDEP.