From nobody Wed Nov 05 00:31:17 2025 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4d1R863C6Mz6Fs7c; Wed, 05 Nov 2025 00:31:18 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R12" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4d1R856swRz3fVP; Wed, 05 Nov 2025 00:31:17 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1762302678; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Du8ZBTw01JHi+NJtLviEpkd9ovqha9mhYEXWEj3XEcw=; b=K1A6v4AiBJG60gdbFuu9cE4tImn1hw2hI7Yn/cR4c9UFMjcJzOnyuMhsXTAJgmxZapITb0 NRVWQAn2jbFVP95Xwbnmnqlpe9FiHpjtMW7Rtz7zMZXgNqN4QBOs2ejQfpTwRAmeor2ZwV v2GbrzZEU0L9xPkZueqdPxNHz1uLCuGD+6eiiaIU1cXojxp4IMBqTgpa2HnclBXHaGxfUJ ORfRkwver1Bl9Y1Mj8RtWQ+JFRIzIoi9w5oEQMReIIm3Kgvgdgc1VyfBRKC79poUGbGCrN 0oDsraVHpO+RXENxSHpLktm+igFWkHSTgOGQYN0itUj5vy+eF3xFBeSmxt0VOA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1762302678; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=Du8ZBTw01JHi+NJtLviEpkd9ovqha9mhYEXWEj3XEcw=; b=b/k+OYqa+U4+afU/yj+X+ojGiAGmJBcca/20l9tvPix5GTT3S8f7M4rrNfwQDH493ly0fu BiK4CO+ehbvoQGT+UX8zhr0jaQWubmskgg5/GVky8iHPJusIoMe7YP1n9rSa2piV8enPnj PEMBgWEOfO5jZY/2+2b6+xlJEDmvivr+VAnTp6lFbF8dQESInc8GEJ74Cwo6axmf1RweIS UX5XBf9bgcz8ab/7YbB807EvwnI3hodI11tS0F93cC8WYVOdG1YvcH4UnRt/WETP0EnfJ0 0L+PaPU162NJ4nfph7LjBU9Y2Y+m3b/0UH0QScPjDTR0/O+VY3in9761o1J4yQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1762302678; a=rsa-sha256; cv=none; b=uia3h81CzDUGq0ePtl5+8r0IKVbIm92dMQ8hG9BE6bSIJob+iDXcNqmQPMHGQcd4SXW4PE YqJ1b8dvlbxCcW0CTIxK5T/y1JqPSB5HnHJQ67ISqYNU1VcpJvQijKhFmkvu2Mz/dQsbay cDQGU/K97Gk54zI1duno6lAk2Kx+G7XVMEzQuWYWbX5pfK8P5bfiVMrFXj6q//bYG3h3Uk TyFcNiW8o04nOpO4nGAlmlteOKpkFL+VsAWtHCGanN2aIEH21O6OnLOSp1JIvs0wLpq5Nb WxPNlVN0524DUjL1h2Hy4TUEkTlKSkv2ucnWKdyEc5cEQRncG7Jj7K1+QKTjFw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4d1R8564zhz4G3; Wed, 05 Nov 2025 00:31:17 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 5A50VHPS028366; Wed, 5 Nov 2025 00:31:17 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 5A50VHc5028363; Wed, 5 Nov 2025 00:31:17 GMT (envelope-from git) Date: Wed, 5 Nov 2025 00:31:17 GMT Message-Id: <202511050031.5A50VHc5028363@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kyle Evans Subject: git: 737edb8fb52b - main - posix_fallocate(2): move unsupported case to EOPNOTSUPP List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: kevans X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 737edb8fb52b6ed13ae4e09553a0d2ae2899cede Auto-Submitted: auto-generated The branch main has been updated by kevans: URL: https://cgit.FreeBSD.org/src/commit/?id=737edb8fb52b6ed13ae4e09553a0d2ae2899cede commit 737edb8fb52b6ed13ae4e09553a0d2ae2899cede Author: Kyle Evans AuthorDate: 2025-11-05 00:30:59 +0000 Commit: Kyle Evans CommitDate: 2025-11-05 00:30:59 +0000 posix_fallocate(2): move unsupported case to EOPNOTSUPP ZFS has since been changed to use EOPNOTSUPP instead of EINVAL, and fusefs/nfs are following suit. POSIX Issue 8 had also made this move, so it makes sense for us to standardize on EOPNOTSUPP. Note in the HISTORY section where we're diverging from our previous versions to align with the new standard. Reviewed by: asomers, imp (both previous version), kib Differential Revision: https://reviews.freebsd.org/D53537 --- lib/libsys/posix_fallocate.2 | 26 ++++++++++++++++++++++---- 1 file changed, 22 insertions(+), 4 deletions(-) diff --git a/lib/libsys/posix_fallocate.2 b/lib/libsys/posix_fallocate.2 index 8be075b41331..94858c4a0f90 100644 --- a/lib/libsys/posix_fallocate.2 +++ b/lib/libsys/posix_fallocate.2 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd March 30, 2020 +.Dd November 2, 2025 .Dt POSIX_FALLOCATE 2 .Os .Sh NAME @@ -105,8 +105,7 @@ The .Fa len argument was less than or equal to zero, the .Fa offset -argument was less than zero, -or the operation is not supported by the file system. +argument was less than zero. .It Bq Er EIO An I/O error occurred while reading from or writing to a file system. .It Bq Er EINTEGRITY @@ -123,6 +122,8 @@ media. The file descriptor .Fa fd has insufficient rights. +.It Bq Er EOPNOTSUPP +The operation is not supported by the file system. .It Bq Er ESPIPE The .Fa fd @@ -137,12 +138,29 @@ argument is associated with a pipe or FIFO. The .Fn posix_fallocate system call conforms to -.St -p1003.1-2004 . +.St -p1003.1-2024 . .Sh HISTORY The .Fn posix_fallocate function appeared in .Fx 9.0 . +.Pp +Previous versions of +.Nm +used +.Er EINVAL +to indicate that the operation is not supported by the file system, as specified +in +.St -p1003.1 +Base Specifications, Issue 7. +.St -p1003.1 +Base Specifications, Issue 8 switched to requiring +.Er EOPNOTSUPP +for this error case. +ZFS adopted the latter convention in +.Fx 15.0 , +and the remaining filesystems in base adopted it in +.Fx 15.1 . .Sh AUTHORS .Fn posix_fallocate and this manual page were initially written by