[patch x86] e820_64: fix section mismatch warning - Kernel

This is a discussion on [patch x86] e820_64: fix section mismatch warning - Kernel ; Hi Ingo, this patch (against x86/latest) fixes section mismatch warnings which occurs on my x86_64 box while compiling linux-next-20080410. Warning messages: WARNING: arch/x86/kernel/built-in.o(.text+0x7bc2): Section mismatch in reference from the function bad_addr() to the variable .init.data:early_res The function bad_addr() references the ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: [patch x86] e820_64: fix section mismatch warning

  1. [patch x86] e820_64: fix section mismatch warning

    Hi Ingo,

    this patch (against x86/latest) fixes section mismatch warnings which occurs on my x86_64 box while compiling
    linux-next-20080410.

    Warning messages:

    WARNING: arch/x86/kernel/built-in.o(.text+0x7bc2): Section mismatch in reference from the function bad_addr() to the
    variable .init.data:early_res
    The function bad_addr() references
    the variable __initdata early_res.
    This is often because bad_addr lacks a __initdata
    annotation or the annotation of early_res is wrong.

    WARNING: arch/x86/kernel/built-in.o(.text+0x7c3b): Section mismatch in reference from the function bad_addr_size() to
    the variable .init.data:early_res
    The function bad_addr_size() references
    the variable __initdata early_res.
    This is often because bad_addr_size lacks a __initdata
    annotation or the annotation of early_res is wrong.

    Signed-off-by: Jacek Luczak

    ---
    e820_64.c | 4 ++--
    1 file changed, 2 insertions(+), 2 deletions(-)


    diff --git a/arch/x86/kernel/e820_64.c b/arch/x86/kernel/e820_64.c
    index 4f4b690..645ee5e 100644
    --- a/arch/x86/kernel/e820_64.c
    +++ b/arch/x86/kernel/e820_64.c
    @@ -123,7 +123,7 @@ void __init early_res_to_bootmem(unsigned long start, unsigned long end)
    }

    /* Check for already reserved areas */
    -static inline int
    +static inline int __init
    bad_addr(unsigned long *addrp, unsigned long size, unsigned long align)
    {
    int i;
    @@ -143,7 +143,7 @@ again:
    }

    /* Check for already reserved areas */
    -static inline int
    +static inline int __init
    bad_addr_size(unsigned long *addrp, unsigned long *sizep, unsigned long align)
    {
    int i;

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

  2. Re: [patch x86] e820_64: fix section mismatch warning


    * Jacek Luczak wrote:

    > Hi Ingo,
    >
    > this patch (against x86/latest) fixes section mismatch warnings which
    > occurs on my x86_64 box while compiling linux-next-20080410.


    thanks Jacek, applied.

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

+ Reply to Thread