Re: [PATCH] ramfs: nommu: fix error rollback and reader races in ramfs_nommu_expand_for_mapping()

From: Hajime Tazaki

Date: Mon Jul 13 2026 - 20:28:19 EST



On Tue, 14 Jul 2026 01:36:21 +0200,
Daniel Palmer wrote:
>
> > so I was wondering if it is still interesting to support the syscall
> > (memfd_createfd) on nommu even the fcntl always fails.
>
> I think these fcntls will also fail on MMU=y where the full tmpfs is
> not enabled for size reasons. I'm not sure if it's actually possible
> to detect if tmpfs is really tmpfs or not. (I have this exact issue
> with a test for nolibc).

thanks, I'll look into detail.

> memfd_createfd is still useful because it basically allows you to
> create anonymous temporary files that you can pass to another process
> and mmap() in both.
> I use this for doing DNS resolution in my nolibc system: A process
> that needs DNS resolution creates an memfd for the result and then
> forks the resolver which mmap()s the memfd, fills in the result and
> then exits. This avoids having the big resolver code in everything
> that needs it since I don't have any shared libraries :).

I understand, this might be a good test case with the actual use.

> BTW: Could you share a link to your LTP fork? I will add it to my m68k
> environment.

forgive me in advance :)
links are only the current working tree; it might be renamed/removed
in future.

here is a fork/branch of ltp:
https://github.com/thehajime/ltp/tree/fix-nommu

it is triggered from my UML branch with github actions (below),

https://github.com/thehajime/linux/blob/zpoline-nommu-v6.10/.github/workflows/ci.yml

using this dirty yaml file to build and execute part of testcases.

https://github.com/thehajime/linux/blob/zpoline-nommu-v6.10/.github/workflows/ci-docker-build.yml

-- Hajime