All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] Split lowmem and kernel mappings
@ 2021-05-17 14:57 Linus Walleij
  2021-05-17 14:57 ` [PATCH 1/3] ARM: Split KERNEL_OFFSET from PAGE_OFFSET Linus Walleij
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Linus Walleij @ 2021-05-17 14:57 UTC (permalink / raw)
  To: linux-arm-kernel, Russell King, Arnd Bergmann
  Cc: Florian Fainelli, Geert Uytterhoeven, Ard Biesheuvel, Linus Walleij

This patch set of 3 patches is the beginnings of an idea
from Arnd: to move the kernel image (executable and
non-executable sections) into the VMALLOC area.

To get there we first need to pry apart the section
mappings of lowmem and the kernel.

This series:

- Creates a specific KERNEL_OFFSET and removes the implied
  assumption that the kernel will always start at PAGE_OFFSET.

- Saves the kernel physical section start and end addresses
  from the early assembly-coded section mappings so we can
  reuse these later without having to rely on
  virtual-to-physical mappings.

- Splits the map_lowmem() function into two: map_lowmem()
  which maps the lowmem proper and map_kernel() that maps
  the kernel. The split is nice (IMO) because the functions
  become cleaner and easier to read. It is possible that
  the refactoring of map_lowmem() also avoids a few
  pitfalls from the earlier code.

I have a prototype patch that on top of this actually moves
the kernel into the VMALLOC area at 0xf1000000 but I want
to keep things apart to avoid too much discussion and
confusion. One thing at the time. I think these patches
are fine in their own right, but I wrote them so I need
others to think the same.

If you want to see the prototype patch(es) it is here:
https://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-integrator.git/log/?h=kernel-in-vmalloc-v5.13-rc1

Linus Walleij (3):
  ARM: Split KERNEL_OFFSET from PAGE_OFFSET
  ARM: Define kernel physical section start and end
  ARM: Map the lowmem and kernel separately

 arch/arm/include/asm/memory.h |  15 +++-
 arch/arm/kernel/head.S        |  30 +++++--
 arch/arm/kernel/vmlinux.lds.S |   2 +-
 arch/arm/mm/mmu.c             | 144 ++++++++++++++++++++++++++--------
 4 files changed, 151 insertions(+), 40 deletions(-)

-- 
2.31.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2021-08-04 13:15 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-17 14:57 [PATCH 0/3] Split lowmem and kernel mappings Linus Walleij
2021-05-17 14:57 ` [PATCH 1/3] ARM: Split KERNEL_OFFSET from PAGE_OFFSET Linus Walleij
2021-05-17 14:57 ` [PATCH 2/3] ARM: Define kernel physical section start and end Linus Walleij
2021-05-17 14:57 ` [PATCH 3/3] ARM: Map the lowmem and kernel separately Linus Walleij
2021-07-30 20:22   ` Nishanth Menon
2021-07-30 22:40     ` Linus Walleij
2021-08-03 10:27       ` Grygorii Strashko
2021-08-03 10:49         ` Russell King (Oracle)
2021-08-03 11:34           ` Linus Walleij
2021-08-04 10:05           ` Linus Walleij
2021-08-04 10:36             ` Russell King (Oracle)
2021-08-04 13:12               ` Linus Walleij

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.