[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20181029133243.wjrwnwgnqszojwpi@linux-8ccs>
Date: Mon, 29 Oct 2018 14:32:43 +0100
From: Jessica Yu <jeyu@...nel.org>
To: Miroslav Benes <mbenes@...e.cz>
Cc: Torsten Duwe <duwe@....de>, Will Deacon <will.deacon@....com>,
Catalin Marinas <catalin.marinas@....com>,
Julien Thierry <julien.thierry@....com>,
Steven Rostedt <rostedt@...dmis.org>,
Josh Poimboeuf <jpoimboe@...hat.com>,
Ingo Molnar <mingo@...hat.com>,
Ard Biesheuvel <ard.biesheuvel@...aro.org>,
Arnd Bergmann <arnd@...db.de>,
AKASHI Takahiro <takahiro.akashi@...aro.org>,
Petr Mladek <pmladek@...e.com>,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
live-patching@...r.kernel.org
Subject: Re: [PATCH v2] arm64/module: use mod->klp_info section header
information for livepatch modules
+++ Miroslav Benes [29/10/18 14:24 +0100]:
>
>> diff --git a/arch/arm64/kernel/module.c b/arch/arm64/kernel/module.c
>> index dd23655fda3a..490e56070a7e 100644
>> --- a/arch/arm64/kernel/module.c
>> +++ b/arch/arm64/kernel/module.c
>> @@ -461,5 +461,15 @@ int module_finalize(const Elf_Ehdr *hdr,
>> #endif
>> }
>>
>> +#ifdef CONFIG_LIVEPATCH
>> + /*
>> + * For livepatching, switch to the saved section header info for .plt
>> + * stored in mod->klp_info. This is needed so that livepatch is able to
>> + * call apply_relocate_add() after patch module load.
>> + */
>> + if (is_livepatch_module(me))
>> + me->arch.core.plt = me->klp_info->sechdrs + me->arch.core.plt_shndx;
>> +#endif
>
>I missed it before, but the hunk should be under "#ifdef
>CONFIG_ARM64_MODULE_PLTS" protection similarly to ftrace_trampoline just
>above. me->arch.core.plt may not exist otherwise.
Gah! Yes you are right, will fix.
Thanks,
Jessica
Powered by blists - more mailing lists