Thread (32 messages) flat view 32 messages, 8 authors, 2020-07-24

Re: [PATCH v5 1/4] riscv: Move kernel mapping to vmalloc zone

From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Date: 2020-07-22 02:22:17
Also in: linux-mm, linux-riscv, lkml

On Tue, 2020-07-21 at 16:48 -0700, Palmer Dabbelt wrote:
quoted
Why ? Branch distance limits ? You can't use trampolines ?
Nothing fundamental, it's just that we don't have a large code model in the C
compiler.  As a result all the global symbols are resolved as 32-bit
PC-relative accesses.  We could fix this with a fast large code model, but then
the kernel would need to relax global symbol references in modules and we don't
even do that for the simple code models we have now.  FWIW, some of the
proposed large code models are essentially just split-PLT/GOT and therefor
don't require relaxation, but at that point we're essentially PIC until we
have more that 2GiB of kernel text -- and even then, we keep all the
performance issues.
My memory might be out of date but I *think* we do it on powerpc
without going to a large code model, but just having the in-kernel
linker insert trampolines.

Cheers,
Ben.

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help