linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] clk: mediatek: mark mtk_infrasys_init_early __init
@ 2017-09-15 19:28 Arnd Bergmann
  2017-11-02  8:06 ` Stephen Boyd
  0 siblings, 1 reply; 2+ messages in thread
From: Arnd Bergmann @ 2017-09-15 19:28 UTC (permalink / raw)
  To: Michael Turquette, Stephen Boyd, Matthias Brugger
  Cc: Arnd Bergmann, Shunli Wang, James Liao, Erin Lo, Philipp Zabel,
	Sean Wang, linux-clk, linux-kernel, linux-arm-kernel,
	linux-mediatek

On gcc-4.6, we get a harmless link-time warning:

WARNING: vmlinux.o(.text.unlikely+0x196a0): Section mismatch in reference from the function mtk_infrasys_init_early() to the function .init.text:mtk_clk_register_cpumuxes()
The function mtk_infrasys_init_early() references
the function __init mtk_clk_register_cpumuxes().
This is often because mtk_infrasys_init_early lacks a __init
annotation or the annotation of mtk_clk_register_cpumuxes is wrong.

Newer compilers inline this function so they don't warn, but
marking it __init is the right solution for all versions.

Fixes: e9862118272a ("clk: mediatek: Add MT2701 clock support")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
---
 drivers/clk/mediatek/clk-mt2701.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/clk/mediatek/clk-mt2701.c b/drivers/clk/mediatek/clk-mt2701.c
index 9598889f972b..8e7f16fd87c9 100644
--- a/drivers/clk/mediatek/clk-mt2701.c
+++ b/drivers/clk/mediatek/clk-mt2701.c
@@ -750,7 +750,7 @@ static const struct mtk_fixed_factor infra_fixed_divs[] = {
 
 static struct clk_onecell_data *infra_clk_data;
 
-static void mtk_infrasys_init_early(struct device_node *node)
+static void __init mtk_infrasys_init_early(struct device_node *node)
 {
 	int r, i;
 
-- 
2.9.0

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] clk: mediatek: mark mtk_infrasys_init_early __init
  2017-09-15 19:28 [PATCH] clk: mediatek: mark mtk_infrasys_init_early __init Arnd Bergmann
@ 2017-11-02  8:06 ` Stephen Boyd
  0 siblings, 0 replies; 2+ messages in thread
From: Stephen Boyd @ 2017-11-02  8:06 UTC (permalink / raw)
  To: Arnd Bergmann
  Cc: Michael Turquette, Matthias Brugger, Shunli Wang, James Liao,
	Erin Lo, Philipp Zabel, Sean Wang, linux-clk, linux-kernel,
	linux-arm-kernel, linux-mediatek

On 09/15, Arnd Bergmann wrote:
> On gcc-4.6, we get a harmless link-time warning:
> 
> WARNING: vmlinux.o(.text.unlikely+0x196a0): Section mismatch in reference from the function mtk_infrasys_init_early() to the function .init.text:mtk_clk_register_cpumuxes()
> The function mtk_infrasys_init_early() references
> the function __init mtk_clk_register_cpumuxes().
> This is often because mtk_infrasys_init_early lacks a __init
> annotation or the annotation of mtk_clk_register_cpumuxes is wrong.
> 
> Newer compilers inline this function so they don't warn, but
> marking it __init is the right solution for all versions.
> 
> Fixes: e9862118272a ("clk: mediatek: Add MT2701 clock support")
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---

Applied to clk-next

-- 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-11-02  8:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-09-15 19:28 [PATCH] clk: mediatek: mark mtk_infrasys_init_early __init Arnd Bergmann
2017-11-02  8:06 ` Stephen Boyd

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).