[RFC] net/9p: raise MAX_SOCK_BUF beyond 1 MiB for fd/tcp/unix transports?

"Pierre Barre" <[email protected]> Tue, 14 Apr 2026 16:26:36 +0200
Newsgroups dev.linux.lists.v9fs,org.kernel.vger.linux-fsdevel
Message-ID <[email protected]>
Hi all,

MAX_SOCK_BUF in net/9p/trans_fd.c currently caps msize at 1 MiB for the fd/tcp/unix transports. The commit that introduced this ceiling (22bb3b79290e, "net/9p: increase tcp max msize to 1MB") noted that a further bump would need the allocator moved off contiguous slab chunks.

That prerequisite appears to be met now: p9_fcall_init() in net/9p/client.c uses kvmalloc() when the transport sets supports_vmalloc = true, which fd/tcp/unix all do. So the original slab fragmentation argument against raising the cap no longer applies to these transports.

Before I put together a patch, I wanted to check:

1. Are there other reasons that the 1 MiB cap should stay?
2. If a bump is welcome, is there a target value you'd prefer (e.g. 16 MiB, 32 MiB)?

Thanks,
Pierre