From patchwork Mon Jan 14 16:22:55 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vladimir Murzin X-Patchwork-Id: 10763027 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 28209746 for ; Mon, 14 Jan 2019 16:23:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 17C4429505 for ; Mon, 14 Jan 2019 16:23:25 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 0B05429546; Mon, 14 Jan 2019 16:23:25 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id AB83729505 for ; Mon, 14 Jan 2019 16:23:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:List-Subscribe:List-Help: List-Post:List-Archive:List-Unsubscribe:List-Id:Message-Id:Date:Subject:To: From:Reply-To:Cc:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=hNP7LzJZSt0aQ/DMTJCa7jR89H3QWBkVQIRV3BM74As=; b=Ia19rlVlvsIGiu Pvgupf1E75i+ef71cbiF1M6CI9IJ3RuMVHljLRvwQm7Zg5ODbG/JmOXxkOL+cjOrcsgXvGu7eLpF7 NkGdz2h5HaxOniluRuQxk4nMUvvPYLU1GnOKN7qw5V/STLF4sL+pgxwprbEvVvyZHjLKffyoCKqxp omyh42JW5PBI0pKN41bUMQSYlqVnyIO/49lv+KbGXOSI3E7+1Pt1E4i6+PchnVbekawd6EMZKQD9i FfShXjO+e0Xa9kSlDiZRutqGRZlsqgm/bQriu4tOvzGARH0b6+sUKig8uIoUL4SI+REcbiHXX/Mt8 TKs8OQMJRNfW9Xbt4W2w==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gj51C-0004nI-2c; Mon, 14 Jan 2019 16:23:18 +0000 Received: from foss.arm.com ([217.140.101.70]) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gj511-0004bw-BZ for linux-arm-kernel@lists.infradead.org; Mon, 14 Jan 2019 16:23:12 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id CA63C80D for ; Mon, 14 Jan 2019 08:23:06 -0800 (PST) Received: from login2.euhpc.arm.com (login2.euhpc.arm.com [10.6.27.34]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 54D9C3F5BD for ; Mon, 14 Jan 2019 08:23:06 -0800 (PST) From: Vladimir Murzin To: linux-arm-kernel@lists.infradead.org Subject: [PATCH] arm64: init: inline empty stubs Date: Mon, 14 Jan 2019 16:22:55 +0000 Message-Id: <1547482975-24059-1-git-send-email-vladimir.murzin@arm.com> X-Mailer: git-send-email 2.0.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190114_082307_687044_0E518086 X-CRM114-Status: GOOD ( 10.93 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP It looks like compiler is smart enough to eliminate empty __init stubs, yet inlining stubs is a common and recognisable idiom. Signed-off-by: Vladimir Murzin Acked-by: Mark Rutland --- arch/arm64/mm/init.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/arm64/mm/init.c b/arch/arm64/mm/init.c index 7205a90..ab4df62 100644 --- a/arch/arm64/mm/init.c +++ b/arch/arm64/mm/init.c @@ -140,11 +140,11 @@ static void __init kexec_reserve_crashkres_pages(void) #endif } #else -static void __init reserve_crashkernel(void) +static inline void reserve_crashkernel(void) { } -static void __init kexec_reserve_crashkres_pages(void) +static inline void kexec_reserve_crashkres_pages(void) { } #endif /* CONFIG_KEXEC_CORE */ @@ -195,7 +195,7 @@ static void __init reserve_elfcorehdr(void) elfcorehdr_size >> 10, elfcorehdr_addr); } #else -static void __init reserve_elfcorehdr(void) +static inline void reserve_elfcorehdr(void) { } #endif /* CONFIG_CRASH_DUMP */