Re: [PATCH v3 09/14] vfs: add O_CREAT|O_DIRECTORY to open*(2)
From: Christoph Hellwig
Date: Thu Jul 09 2026 - 02:26:45 EST
On Wed, Jul 08, 2026 at 04:39:54PM +0100, Pedro Falcato wrote:
> Because it's a black box:
> - Maybe this feature lands in 7.3 or 7.4 and enterprise kernels (and Android)
> backport it to older releases on request (as a random example, XFS atomic
> writes were added in 6.16, but were backported to 6.12 in SLES, and UEK 8,
> and possibly RHEL/Ubuntu too)
> - Maybe the feature is posteriously reverted, disabled, changed
> - Upstream LTS also does its backports, so the O_CREAT | O_DIRECTORY EINVAL
> only landed in 6.4, but was backported to 6.1, but not to 6.2 or 6.3, and
> not to 5.15 or 5.10, and the behavior will again change as soon as this
> lands
> - Sometimes the kernel perfectly supports a feature but you're running under
> a tight seccomp filter that rejects unknown syscalls (or ones that it can't
> filter, like SYS_clone3), so you get a mysterious -ENOSYS that uname() will
> not be able to explain.
> - You can technically even be running under the uname26 personality and now
> your uname() is completely nonsensical
Exactly. NEw features need to be discoverable, and O_ flags that
get ignored by old kernel are not.