From: Youling Tang <tangyouling@loongson.cn>
To: Xi Ruoyao <xry111@xry111.site>
Cc: Huacai Chen <chenhuacai@kernel.org>,
Jinyang He <hejinyang@loongson.cn>,
Xuerui Wang <kernel@xen0n.name>,
loongarch@lists.linux.dev, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v5 4/5] LoongArch: Add support for kernel relocation
Date: Fri, 17 Feb 2023 16:13:42 +0800 [thread overview]
Message-ID: <fc5b0403-ed2f-2dcf-11b9-e3be4642ddda@loongson.cn> (raw)
In-Reply-To: <5ac82f53aeb6a040be90eac2be7c64055e62f0ef.camel@xry111.site>
On 02/17/2023 04:02 PM, Xi Ruoyao wrote:
> On Fri, 2023-02-17 at 15:26 +0800, Youling Tang wrote:
>
>> This config allows to compile kernel as PIE and to relocate it at
>> any virtual address at runtime: this paves the way to KASLR.
>> Runtime relocation is possible since relocation metadata are embedded
>> into the kernel.
>>
>> Signed-off-by: Youling Tang <tangyouling@loongson.cn>
>> Signed-off-by: Xi Ruoyao <xry111@xry111.site> # Use arch_initcall
>> Signed-off-by: Jinyang He <hejinyang@loongson.cn> # Provide la_abs idea
>
> Use Suggested-by if only "idea" is provided.
In addition to the idea, the first draft code of la_abs is also
provided.
Maybe change it to the following,
Signed-off-by: Jinyang He <hejinyang@loongson.cn> # Provide la_abs
relocation draft code
>
>> +struct rela_la_abs {
>> + long offset;
>> + long symvalue;
>> +};
>
> Use one tab instead of two for the indent.
My mistake.
Also the missing do_kaslr declaration will be added.
Youling.
> Otherwise LGTM.
>
next prev parent reply other threads:[~2023-02-17 8:13 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-17 7:26 [PATCH v5 0/5] LoongArch: Add kernel relocation and KASLR support Youling Tang
2023-02-17 7:26 ` [PATCH v5 1/5] LoongArch: Use la.pcrel instead of la.abs when it's trivially possible Youling Tang
2023-02-17 7:26 ` [PATCH v5 2/5] LoongArch: Add JUMP_VIRT_ADDR macro implementation to avoid using la.abs Youling Tang
2023-02-17 7:26 ` [PATCH v5 3/5] LoongArch: Add la_abs macro implementation Youling Tang
2023-02-17 7:26 ` [PATCH v5 4/5] LoongArch: Add support for kernel relocation Youling Tang
2023-02-17 8:02 ` Xi Ruoyao
2023-02-17 8:13 ` Youling Tang [this message]
2023-02-17 7:26 ` [PATCH v5 5/5] LoongArch: Add support for kernel address space layout randomization (KASLR) Youling Tang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=fc5b0403-ed2f-2dcf-11b9-e3be4642ddda@loongson.cn \
--to=tangyouling@loongson.cn \
--cc=chenhuacai@kernel.org \
--cc=hejinyang@loongson.cn \
--cc=kernel@xen0n.name \
--cc=linux-kernel@vger.kernel.org \
--cc=loongarch@lists.linux.dev \
--cc=xry111@xry111.site \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®