From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E268DC04EBF for ; Mon, 23 Sep 2019 10:27:54 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id ACD71206C2 for ; Mon, 23 Sep 2019 10:27:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729805AbfIWK1y (ORCPT ); Mon, 23 Sep 2019 06:27:54 -0400 Received: from Galois.linutronix.de ([193.142.43.55]:57851 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728126AbfIWK1y (ORCPT ); Mon, 23 Sep 2019 06:27:54 -0400 Received: from [5.158.153.52] (helo=nanos.tec.linutronix.de) by Galois.linutronix.de with esmtpsa (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1iCLZM-00021F-1I; Mon, 23 Sep 2019 12:27:48 +0200 Date: Mon, 23 Sep 2019 12:27:47 +0200 (CEST) From: Thomas Gleixner To: Peter Zijlstra cc: LKML , x86@kernel.org, Andy Lutomirski , Catalin Marinas , Will Deacon , Mark Rutland , Marc Zyngier , Paolo Bonzini , kvm@vger.kernel.org, linux-arch@vger.kernel.org Subject: Re: [RFC patch 10/15] x86/entry: Move irq tracing to C code In-Reply-To: <20190923084718.GG2349@hirez.programming.kicks-ass.net> Message-ID: References: <20190919150314.054351477@linutronix.de> <20190919150809.446771597@linutronix.de> <20190923084718.GG2349@hirez.programming.kicks-ass.net> User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 23 Sep 2019, Peter Zijlstra wrote: > On Thu, Sep 19, 2019 at 05:03:24PM +0200, Thomas Gleixner wrote: > > To prepare for converting the exit to usermode code to the generic version, > > move the irqflags tracing into C code. > > > > Signed-off-by: Thomas Gleixner > > --- > > arch/x86/entry/common.c | 10 ++++++++++ > > arch/x86/entry/entry_32.S | 11 +---------- > > arch/x86/entry/entry_64.S | 10 ++-------- > > arch/x86/entry/entry_64_compat.S | 21 --------------------- > > 4 files changed, 13 insertions(+), 39 deletions(-) > > > > --- a/arch/x86/entry/common.c > > +++ b/arch/x86/entry/common.c > > @@ -102,6 +102,8 @@ static void exit_to_usermode_loop(struct > > struct thread_info *ti = current_thread_info(); > > u32 cached_flags; > > > > + trace_hardirqs_off(); > > Bah.. so this gets called from: > > - C code, with IRQs disabled > - entry_64.S:error_exit > - entry_32.S:resume_userspace > > The first obviously doesn't need this annotation, but this patch doesn't > remove the TRACE_IRQS_OFF from entry_64.S and only the 32bit case is > changed. > > Is that entry_64.S case an oversight, or do we need an extensive comment > on this one? Lemme stare at that again. At some point I probably lost track in that maze. Thanks, tglx