diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2016-01-14 19:38:02 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2016-01-14 19:38:02 -0500 |
commit | 0f0836b7eb1b9d14862ee40c7856227a3ead70db (patch) | |
tree | c85b530eec7098a1230709ab43a05447e0cd3c89 /arch/avr32 | |
parent | c2848f2eef4dd08b0fd2a8eba1694fd8e77ddb67 (diff) | |
parent | b56b36ee6751abe7fb3890681e86fc8de2122953 (diff) |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/livepatching
Pull livepatching updates from Jiri Kosina:
- RO/NX attribute fixes for patch module relocations from Josh
Poimboeuf. As part of this effort, module.c has been cleaned up as
well and livepatching is piggy-backing on this cleanup. Rusty is OK
with this whole lot going through livepatching tree.
- symbol disambiguation support from Chris J Arges. That series is
also
Reviewed-by: Miroslav Benes <mbenes@suse.cz>
but this came in only after I've alredy pushed out. Didn't want to
rebase because of that, hence I am mentioning it here.
- symbol lookup fix from Miroslav Benes
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/livepatching:
livepatch: Cleanup module page permission changes
module: keep percpu symbols in module's symtab
module: clean up RO/NX handling.
module: use a structure to encapsulate layout.
gcov: use within_module() helper.
module: Use the same logic for setting and unsetting RO/NX
livepatch: function,sympos scheme in livepatch sysfs directory
livepatch: add sympos as disambiguator field to klp_reloc
livepatch: add old_sympos as disambiguator field to klp_func
Diffstat (limited to 'arch/avr32')
-rw-r--r-- | arch/avr32/kernel/module.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/arch/avr32/kernel/module.c b/arch/avr32/kernel/module.c index 164efa009e5b..2b4c54c04cb6 100644 --- a/arch/avr32/kernel/module.c +++ b/arch/avr32/kernel/module.c | |||
@@ -118,9 +118,9 @@ int module_frob_arch_sections(Elf_Ehdr *hdr, Elf_Shdr *sechdrs, | |||
118 | * Increase core size to make room for GOT and set start | 118 | * Increase core size to make room for GOT and set start |
119 | * offset for GOT. | 119 | * offset for GOT. |
120 | */ | 120 | */ |
121 | module->core_size = ALIGN(module->core_size, 4); | 121 | module->core_layout.size = ALIGN(module->core_layout.size, 4); |
122 | module->arch.got_offset = module->core_size; | 122 | module->arch.got_offset = module->core_layout.size; |
123 | module->core_size += module->arch.got_size; | 123 | module->core_layout.size += module->arch.got_size; |
124 | 124 | ||
125 | return 0; | 125 | return 0; |
126 | 126 | ||
@@ -177,7 +177,7 @@ int apply_relocate_add(Elf32_Shdr *sechdrs, const char *strtab, | |||
177 | if (!info->got_initialized) { | 177 | if (!info->got_initialized) { |
178 | Elf32_Addr *gotent; | 178 | Elf32_Addr *gotent; |
179 | 179 | ||
180 | gotent = (module->module_core | 180 | gotent = (module->core_layout.base |
181 | + module->arch.got_offset | 181 | + module->arch.got_offset |
182 | + info->got_offset); | 182 | + info->got_offset); |
183 | *gotent = relocation; | 183 | *gotent = relocation; |
@@ -255,8 +255,8 @@ int apply_relocate_add(Elf32_Shdr *sechdrs, const char *strtab, | |||
255 | */ | 255 | */ |
256 | pr_debug("GOTPC: PC=0x%x, got_offset=0x%lx, core=0x%p\n", | 256 | pr_debug("GOTPC: PC=0x%x, got_offset=0x%lx, core=0x%p\n", |
257 | relocation, module->arch.got_offset, | 257 | relocation, module->arch.got_offset, |
258 | module->module_core); | 258 | module->core_layout.base); |
259 | relocation -= ((unsigned long)module->module_core | 259 | relocation -= ((unsigned long)module->core_layout.base |
260 | + module->arch.got_offset); | 260 | + module->arch.got_offset); |
261 | *location = relocation; | 261 | *location = relocation; |
262 | break; | 262 | break; |