From patchwork Tue Apr 23 03:21:03 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahiro Yamada X-Patchwork-Id: 162635 Delivered-To: patch@linaro.org Received: by 2002:a02:c6d8:0:0:0:0:0 with SMTP id r24csp3305620jan; Mon, 22 Apr 2019 20:23:24 -0700 (PDT) X-Google-Smtp-Source: APXvYqwrxtDxvRU7smW7pEz7tv5KsFu6qbp3dfIG2Boeo+qVjaHKZN0B9KMqmV/fIzK+/UXSkFwB X-Received: by 2002:a17:902:848d:: with SMTP id c13mr22675858plo.279.1555989804162; Mon, 22 Apr 2019 20:23:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555989804; cv=none; d=google.com; s=arc-20160816; b=q1h4k8ZI96QijsUtZWJZEw38b85ozU5M5c+pwQ8bNGqxep+hvwV+rqBkCee6nd9UZm u2klLKL6TXJIWjemQFg32EGvqBhryG/7L1/RFU5ACz+5SaX2ZIrhHgLYghvbYYnob08I a0IM6SCLTRI/N52tGe2IUwjGOpbf9xnxeKzKGxBFdgjeGhAvHDX0IITeyTNpd1mq5U0O RcptxwmylRatoXiaXvTW916R0jOS9Py1c0BezmsLkbRXW3tYVCABCI2LfB6EhHy1TTS3 mqjZ2rwvKu5W5hg17FT+WcCGgrIs0eguPEa08MDaJZLomYFQPesyfgdJvaFh8UfHoibp 2YiQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:dkim-filter; bh=7qo1vbhArO2n/LZF4sYuHYL1/6J0V//9VqfNxacUkeY=; b=CQp66bPFZoF/8esMX+Yp/aggfgM8lTC/YnaVl8S+nVqTxGW2fR7nR/bEsM4G1z6xtB t5yq3+CH0P2qRjPZ3mVEl8r/DIPfm67EKsrFZGj3d05eNe9THFBqP4QRxcu50/SDNdf4 rfCZXx30RA1iwi21gPSWjpm2uuiu2ssq+DYd3rG2jjd/jcGP7Y9fvNmypJaFvR5ZuuP6 PmdtUSPpJFUhMqhKs9g3NjLHexUfp4OIeQho1i4h4QY/k40P6CCRYYrUvrf+ldWfukqI pS82inziwDAnK9FdaxYDoNzNQ+WPagUQqXALSn6ttFjH1k4RLb+SRsbNqLiS+uF1fDcn MLLg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=ByF3Wmdm; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q190si16119121pfc.215.2019.04.22.20.23.23; Mon, 22 Apr 2019 20:23:24 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@nifty.com header.s=dec2015msa header.b=ByF3Wmdm; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731558AbfDWDXW (ORCPT + 30 others); Mon, 22 Apr 2019 23:23:22 -0400 Received: from conuserg-09.nifty.com ([210.131.2.76]:57997 "EHLO conuserg-09.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731386AbfDWDW5 (ORCPT ); Mon, 22 Apr 2019 23:22:57 -0400 Received: from localhost.localdomain (p14092-ipngnfx01kyoto.kyoto.ocn.ne.jp [153.142.97.92]) (authenticated) by conuserg-09.nifty.com with ESMTP id x3N3L8LI031384; Tue, 23 Apr 2019 12:21:16 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conuserg-09.nifty.com x3N3L8LI031384 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1555989677; bh=7qo1vbhArO2n/LZF4sYuHYL1/6J0V//9VqfNxacUkeY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ByF3Wmdmakc6HLxf+7sO4AecDTjocpMpuNC8cuKlErGY2yh/dUHLMuh9zSFWEGTqW q+KiAI+xFh2t24Ab9m1yrPP17Cyl+UhoxHAxcgFKNrCZCdOQN3cso9Mb/EXfi2daGR hlvySMMI/+wVS1osaiozGonKjB5tKKgqQoKy+9b/ap9neqJLqr1tga0RknQmdLF5JK mrAbzkbvLcAzZ1NxGJ9dZS3STvmHdygjzqiMUFvx18/R69eytCCnyKXuaz6EFMKoqG qZ0UXSQUDTS36O4kuT/WHJOuuDNS3UAjjBtSEpPsRvPp7tR/lkpLgjI9bHexOD5AsD z+jiwwsUH5rGA== X-Nifty-SrcIP: [153.142.97.92] From: Masahiro Yamada To: Andrew Morton , linux-arch Cc: linux-s390@vger.kernel.org, Heiko Carstens , Arnd Bergmann , linuxppc-dev@lists.ozlabs.org, x86@kernel.org, linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, Ingo Molnar , linux-mtd@lists.infradead.org, linux-arm-kernel@lists.infradead.org, Christophe Leroy , Mathieu Malaterre , Masahiro Yamada Subject: [PATCH v3 07/10] powerpc/prom_init: mark prom_getprop() and prom_getproplen() as __init Date: Tue, 23 Apr 2019 12:21:03 +0900 Message-Id: <20190423032106.11960-8-yamada.masahiro@socionext.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190423032106.11960-1-yamada.masahiro@socionext.com> References: <20190423032106.11960-1-yamada.masahiro@socionext.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This prepares to move CONFIG_OPTIMIZE_INLINING from x86 to a common place. We need to eliminate potential issues beforehand. If it is enabled for powerpc, the following modpost warnings are reported: WARNING: vmlinux.o(.text.unlikely+0x20): Section mismatch in reference from the function .prom_getprop() to the function .init.text:.call_prom() The function .prom_getprop() references the function __init .call_prom(). This is often because .prom_getprop lacks a __init annotation or the annotation of .call_prom is wrong. WARNING: vmlinux.o(.text.unlikely+0x3c): Section mismatch in reference from the function .prom_getproplen() to the function .init.text:.call_prom() The function .prom_getproplen() references the function __init .call_prom(). This is often because .prom_getproplen lacks a __init annotation or the annotation of .call_prom is wrong. Signed-off-by: Masahiro Yamada --- Changes in v3: None Changes in v2: - split into a separate patch arch/powerpc/kernel/prom_init.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) -- 2.17.1 diff --git a/arch/powerpc/kernel/prom_init.c b/arch/powerpc/kernel/prom_init.c index f33ff4163a51..241fe6b7a8cc 100644 --- a/arch/powerpc/kernel/prom_init.c +++ b/arch/powerpc/kernel/prom_init.c @@ -501,14 +501,14 @@ static int __init prom_next_node(phandle *nodep) } } -static inline int prom_getprop(phandle node, const char *pname, - void *value, size_t valuelen) +static inline int __init prom_getprop(phandle node, const char *pname, + void *value, size_t valuelen) { return call_prom("getprop", 4, 1, node, ADDR(pname), (u32)(unsigned long) value, (u32) valuelen); } -static inline int prom_getproplen(phandle node, const char *pname) +static inline int __init prom_getproplen(phandle node, const char *pname) { return call_prom("getproplen", 2, 1, node, ADDR(pname)); }