Re: [RFC PATCH] mm/nommu: Implement just enough vmap that compressed erofs can be mounted
From: Pedro Falcato
Date: Wed May 20 2026 - 15:45:41 EST
On Thu, May 21, 2026 at 02:22:25AM +0900, Daniel Palmer wrote:
> Hi Lorenzo, (and Pedro),
>
> On Thu, 21 May 2026 at 02:05, Lorenzo Stoakes <ljs@xxxxxxxxxx> wrote:
> >
> > For some reason this iddn't arrive in my inbox properly... strange? Maybe
> > missing To:?
>
> Sorry, I CC'd everyone hoping I wouldn't get grilled for the silly patch.
>
> > > Did I miss anything massive that is going to come back and bite me?
> > > Maybe it would have made more sense just to change the erofs
> > > code so on !CONFIG_MMU it doesn't use vmap?
> >
> > I think that'd probably be better honestly. I think faking out vmalloc is more
> > trouble than it's worth, and it'd probably have to be everything-or-nothing.
>
> That makes sense.
> Do you think it'd be acceptable to maybe return NULL from these
> functions instead of crashing the kernel?
I suspect the reason for this is simple: calling these functions in !mmu
configs is a programming mistake, and we want it to blow up loudly instead
of having slightly/very broken behavior.
Maybe in 2026 we'd have picked WARN_ON() + return NULL. But I don't think
it makes too much sense here, honestly.
>
> > But yeah would gently point you towards doing something on the fs end I think
> > here :)
>
> Noted. I think I'll at least send them a patch to make compression
> support depend on CONFIG_MMU.
Awesome! (note: since you're space restricted you may actually want that
compression :p)
--
Pedro