Re: [PATCH 59/74] lto: Handle LTO common symbols in module loader

2012-08-19 Thread Andi Kleen
On Sun, Aug 19, 2012 at 09:53:02AM +0100, Jan Beulich wrote: > >>> Andi Kleen 08/19/12 4:59 AM >>> > >@@ -1904,6 +1904,10 @@ static int simplify_symbols(struct module *mod, const > >struct load_info *info) > > > >switch (sym[i].st_shndx) { > >case SHN_COMMON: > >+/* I

Re: [PATCH 59/74] lto: Handle LTO common symbols in module loader

2012-08-19 Thread Jan Beulich
>>> Andi Kleen 08/19/12 4:59 AM >>> >@@ -1904,6 +1904,10 @@ static int simplify_symbols(struct module *mod, const >struct load_info *info) > >switch (sym[i].st_shndx) { >case SHN_COMMON: >+/* Ignore common symbols */ >+if (!strncmp(name, "__gnu_lto", 9)) >

[PATCH 59/74] lto: Handle LTO common symbols in module loader

2012-08-18 Thread Andi Kleen
From: Joe Mario Here is the workaround I made for having the kernel not reject modules built with -flto. The clean solution would be to get the compiler to not emit the symbol. Or if it has to emit the symbol, then emit it as initialized data but put it into a comdat/linkonce section. Minor tw