• Sources: primary, discussion
  • Summary: Linux has no system call that creates and opens a directory in one race-free step, which matters when another process can replace a directory between the two calls. Christian Brauner favours reusing the existing flag combination over the earlier mkdirat2 proposal, because it inherits open's name-resolution restrictions. Pedro Falcato and Christoph Hellwig argue applications cannot feature-test it safely, since older LTS kernels never took the 6.4 change that made the combination return EINVAL and the older behaviour silently created a regular file, and Neil Brown proposed a rejecting flag on openat2 instead. The series is not applied, so the final shape of the interface is unsettled.
  • Why it matters: A silent fallback to creating a regular file on unpatched LTS kernels makes userspace adoption of the flag combination unsafe until a feature test exists.

send feedback on this story