Thread (19 messages) 19 messages, 3 authors, 2026-03-19

Re: [PATCH 2/6] ARM: move vmalloc() lazy-page table population

From: "Russell King (Oracle)" <linux@armlinux.org.uk>
Date: 2026-03-02 10:57:17
Also in: linux-rt-devel

On Mon, Mar 02, 2026 at 11:43:51AM +0100, Sebastian Andrzej Siewior wrote:
On 2026-02-27 15:19:13 [+0000], Russell King (Oracle) wrote:
quoted
Split the vmalloc() lazy-page table population from
do_translation_fault() into a new vmalloc_fault() function.

Signed-off-by: Russell King (Oracle) <redacted>
Reviewed-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
quoted
--- a/arch/arm/mm/fault.c
+++ b/arch/arm/mm/fault.c
@@ -261,6 +261,70 @@ static inline bool ttbr0_usermode_access_allowed(struct pt_regs *regs)
 }
 #endif
 
+/*
+ * Handle a vmalloc fault, copying the non-leaf page table entries from
+ * init_mm.pgd. Any kernel context can trigger this, so we must not sleep
+ * or enable interrupts. Having two CPUs execute this for the same page is
"unconditionally enable interrupts."? It wouldn't be wrong to enable
them if the calling context had them enabled, right?
I don't know where you got "unconditionally enable interrupts" from the
comment - it says the exact opposite.
quoted
+ * no problem, we'll just copy the same data twice.
+ *
+ * Returns false on failure.
+ */
+static bool __kprobes __maybe_unused vmalloc_fault(unsigned long addr)
Maybe handle_vmalloc_fault().
x86:

static noinline int vmalloc_fault(unsigned long address)
{
...

I prefer to keep the name the same.

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help