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=-13.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable 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 B391AC433F5 for ; Mon, 6 Sep 2021 14:23:41 +0000 (UTC) Received: from lists.ozlabs.org (lists.ozlabs.org [112.213.38.117]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 96A156056C for ; Mon, 6 Sep 2021 14:23:40 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 96A156056C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=ellerman.id.au Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.ozlabs.org Received: from boromir.ozlabs.org (localhost [IPv6:::1]) by lists.ozlabs.org (Postfix) with ESMTP id 4H39cV4yvqz2yY7 for ; Tue, 7 Sep 2021 00:23:38 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=ellerman.id.au header.i=@ellerman.id.au header.a=rsa-sha256 header.s=201909 header.b=gPDFVvcg; dkim-atps=neutral Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=ellerman.id.au (client-ip=203.11.71.1; helo=ozlabs.org; envelope-from=mpe@ellerman.id.au; receiver=) Authentication-Results: lists.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=ellerman.id.au header.i=@ellerman.id.au header.a=rsa-sha256 header.s=201909 header.b=gPDFVvcg; dkim-atps=neutral Received: from ozlabs.org (bilbo.ozlabs.org [203.11.71.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 4H39bn3Q0vz2yHW for ; Tue, 7 Sep 2021 00:23:00 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ellerman.id.au; s=201909; t=1630938178; bh=a1ig8YTFMn8o0S8xZRd6vor5m3Cp6vgqt+R8f3Aaqr8=; h=From:To:Cc:Subject:In-Reply-To:References:Date:From; b=gPDFVvcgFKVCtnnFcqifi3/U7sQu2oKLjlWmQLo9QKNWq1U2MACHRnqyFWKrnad56 uL+i5BVZJzimDdNdOdWWL97qyY3vQEru4eOyRsCgGll1qxWgWbklqZekpDGcAGKuCf 7DC9/fmleSs/J6PLf3UKelktEfEUDK/VqMn/+w368Z5+i7rKCZizeZ9JNKFm1pNAA5 h4LY2z9lptO/oPnnmWr1502XTFsZvG+pEmckwN3k0Ifrq04O0itioFFI4oF6PBSbWI occtjlLIAW9X8Cbc98/3bwK1W8QWf6J3uswp0ONhi5bpMTYeu0fzaFaimB7DadN/5M jHul5fcpFPOCA== Received: from authenticated.ozlabs.org (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mail.ozlabs.org (Postfix) with ESMTPSA id 4H39bX6gcYz9sW4; Tue, 7 Sep 2021 00:22:48 +1000 (AEST) From: Michael Ellerman To: Weizhao Ouyang , Steven Rostedt , Ingo Molnar Subject: Re: [PATCH v2] ftrace: Cleanup ftrace_dyn_arch_init() In-Reply-To: <20210906111626.1259867-1-o451686892@gmail.com> References: <20210906111626.1259867-1-o451686892@gmail.com> Date: Tue, 07 Sep 2021 00:22:46 +1000 Message-ID: <87v93dn5qh.fsf@mpe.ellerman.id.au> MIME-Version: 1.0 Content-Type: text/plain X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Rich Felker , linux-ia64@vger.kernel.org, linux-sh@vger.kernel.org, Catalin Marinas , linux-mips@vger.kernel.org, "James E.J. Bottomley" , Guo Ren , "H. Peter Anvin" , sparclinux@vger.kernel.org, linux-riscv@lists.infradead.org, Vincent Chen , Will Deacon , linux-s390@vger.kernel.org, Yoshinori Sato , Helge Deller , x86@kernel.org, Russell King , linux-csky@vger.kernel.org, Christian Borntraeger , Albert Ou , Weizhao Ouyang , Vasily Gorbik , Heiko Carstens , Borislav Petkov , Greentime Hu , Paul Walmsley , Thomas Gleixner , linux-arm-kernel@lists.infradead.org, Michal Simek , Thomas Bogendoerfer , linux-parisc@vger.kernel.org, Nick Hu , linux-kernel@vger.kernel.org, Palmer Dabbelt , Paul Mackerras , linuxppc-dev@lists.ozlabs.org, "David S. Miller" Errors-To: linuxppc-dev-bounces+linuxppc-dev=archiver.kernel.org@lists.ozlabs.org Sender: "Linuxppc-dev" Weizhao Ouyang writes: > Most of ARCHs use empty ftrace_dyn_arch_init(), introduce a weak common > ftrace_dyn_arch_init() to cleanup them. > > Signed-off-by: Weizhao Ouyang > Acked-by: Heiko Carstens (s390) > > --- > > Changes in v2: > -- correct CONFIG_DYNAMIC_FTRACE on PowerPC > -- add Acked-by tag > diff --git a/arch/powerpc/include/asm/ftrace.h b/arch/powerpc/include/asm/ftrace.h > index debe8c4f7062..d59f67c0225f 100644 > --- a/arch/powerpc/include/asm/ftrace.h > +++ b/arch/powerpc/include/asm/ftrace.h > @@ -61,6 +61,10 @@ struct dyn_arch_ftrace { > }; > #endif /* __ASSEMBLY__ */ > > +#ifdef CONFIG_DYNAMIC_FTRACE > +int __init ftrace_dyn_arch_init(void); > +#endif /* CONFIG_DYNAMIC_FTRACE */ > + > #ifdef CONFIG_DYNAMIC_FTRACE_WITH_REGS > #define ARCH_SUPPORTS_FTRACE_OPS 1 > #endif That breaks the build for powerpc: /linux/arch/powerpc/include/asm/ftrace.h: Assembler messages: /linux/arch/powerpc/include/asm/ftrace.h:65: Error: unrecognized opcode: `int' make[4]: *** [/linux/scripts/Makefile.build:352: arch/powerpc/kernel/trace/ftrace_64.o] Error 1 make[3]: *** [/linux/scripts/Makefile.build:514: arch/powerpc/kernel/trace] Error 2 make[2]: *** [/linux/scripts/Makefile.build:514: arch/powerpc/kernel] Error 2 make[1]: *** [/linux/Makefile:1861: arch/powerpc] Error 2 make[1]: *** Waiting for unfinished jobs.... It needs to be inside an #ifndef __ASSEMBLY__ section. cheers