Messages in this thread | | | From | David Mosberger <> | Date | Wed, 14 Jan 2004 14:23:29 -0800 | Subject | Re: [PATCH][RFC] 2.6 && module + -g && kernel w/o -g |
| |
>>>>> On Wed, 14 Jan 2004 14:09:37 -0700, Tom Rini <trini@kernel.crashing.org> said:
Tom> The following patch fixes the problem for me on PPC32:
Tom> --- 1.96/kernel/module.c Wed Jan 7 22:46:59 2004 Tom> +++ edited/kernel/module.c Wed Jan 14 14:05:12 2004 Tom> @@ -1439,6 +1439,13 @@ Tom> strindex = sechdrs[i].sh_link; Tom> strtab = (char *)hdr + sechdrs[strindex].sh_offset; Tom> } Tom> + Tom> + /* If we find any debug RELAs, frob these away now. */ Tom> + if (sechdrs[i].sh_type == SHT_RELA && Tom> + (strstr(secstrings+sechdrs[i].sh_name, ".debug") Tom> + != 0)) Tom> + sechdrs[i].sh_type = SHT_NULL; Tom> + Tom> #ifndef CONFIG_MODULE_UNLOAD Tom> /* Don't load .exit sections */ Tom> if (strncmp(secstrings+sechdrs[i].sh_name, ".exit", 5) == 0)
Tom> IMHO, this shouldn't be covered under a PPC32 test since at Tom> least PPC32, PPC64 and Alpha have this issue, and I suspect Tom> that ia64, parisc, s390 and v850 have the problem as well Tom> (based on what their module_arch_frob bits look to be doing).
As far as ia64 is concerned, adding a check for .debug should be OK, but since the debug sections do not have any relocs anyhow, it shouldn't make much of a difference one way or another (addresses in the debug section a segment-relative).
--david - 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/
| |