diff options
| author | Takashi Iwai <tiwai@suse.de> | 2010-06-02 14:15:10 +0200 |
|---|---|---|
| committer | Takashi Iwai <tiwai@suse.de> | 2010-06-02 14:15:10 +0200 |
| commit | e4caa8bab3862a7694ab7c6dfede223227ad7fc5 (patch) | |
| tree | 9fa537a72f00f6b4f86c2da7be2e9554304a8ec4 /kernel/module.c | |
| parent | 9f75c1b12c5ef392ddcea575b13560842c28b1b3 (diff) | |
| parent | edb39935c8b19fcd9a8f619d0bc1e9d04594cd2b (diff) | |
Merge branch 'master' of git.alsa-project.org:alsa-kernel into fix/hda
Diffstat (limited to 'kernel/module.c')
| -rw-r--r-- | kernel/module.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/kernel/module.c b/kernel/module.c index 333fbcc9697..0129769301e 100644 --- a/kernel/module.c +++ b/kernel/module.c @@ -403,7 +403,7 @@ static unsigned int find_pcpusec(Elf_Ehdr *hdr, Elf_Shdr *sechdrs, const char *secstrings) { - return find_sec(hdr, sechdrs, secstrings, ".data.percpu"); + return find_sec(hdr, sechdrs, secstrings, ".data..percpu"); } static void percpu_modcopy(struct module *mod, @@ -2014,6 +2014,7 @@ static noinline struct module *load_module(void __user *umod, long err = 0; void *ptr = NULL; /* Stops spurious gcc warning */ unsigned long symoffs, stroffs, *strmap; + void __percpu *percpu; mm_segment_t old_fs; @@ -2158,6 +2159,8 @@ static noinline struct module *load_module(void __user *umod, goto free_mod; sechdrs[pcpuindex].sh_flags &= ~(unsigned long)SHF_ALLOC; } + /* Keep this around for failure path. */ + percpu = mod_percpu(mod); /* Determine total sizes, and put offsets in sh_entsize. For now this is done generically; there doesn't appear to be any @@ -2463,7 +2466,7 @@ static noinline struct module *load_module(void __user *umod, module_free(mod, mod->module_core); /* mod will be freed with core. Don't access it beyond this line! */ free_percpu: - percpu_modfree(mod); + free_percpu(percpu); free_mod: kfree(args); kfree(strmap); |
