[PATCH 2/7] x86: fix section mismatch warning - reserve_region_with_split

From: Marcin Slusarz
Date: Sun Oct 12 2008 - 05:44:46 EST


reserve_region_with_split calls __init function (__reserve_region_with_split)
and is called only from __init function (e820_reserve_resources_late),
so mark it __init

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

Signed-off-by: Marcin Slusarz <marcin.slusarz@xxxxxxxxx>
Cc: Yinghai Lu <yhlu.kernel@xxxxxxxxx>
Cc: Ingo Molnar <mingo@xxxxxxx>
---
kernel/resource.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/kernel/resource.c b/kernel/resource.c
index 414d6fc..914cea6 100644
--- a/kernel/resource.c
+++ b/kernel/resource.c
@@ -575,7 +575,7 @@ static void __init __reserve_region_with_split(struct resource *root,

}

-void reserve_region_with_split(struct resource *root,
+void __init reserve_region_with_split(struct resource *root,
resource_size_t start, resource_size_t end,
const char *name)
{
--
1.5.6.4

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/