[PATCH 2/6] ARM: move vmalloc() lazy-page table population
Russell King (Oracle)
linux at armlinux.org.uk
Mon Mar 2 02:57:03 PST 2026
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:
> > Split the vmalloc() lazy-page table population from
> > do_translation_fault() into a new vmalloc_fault() function.
> >
> > Signed-off-by: Russell King (Oracle) <rmk+kernel at armlinux.org.uk>
> Reviewed-by: Sebastian Andrzej Siewior <bigeasy at linutronix.de>
>
> > --- 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.
>
> > + * 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!
More information about the linux-arm-kernel
mailing list