From nobody Sun Aug 20 07:37:46 2023 X-Original-To: dev-commits-src-main@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 4RT6s712bWz4qsHK; Sun, 20 Aug 2023 07:37:47 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RT6s63gjCz3DLX; Sun, 20 Aug 2023 07:37:46 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1692517066; 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=SeDUWkcxw4uiIHgdb7I7RoLF633DkLR5oUj10yMEJeA=; b=K88fRgLfWn9jvOLs+Bo0zcoKThHdWH2pteT04NvelRyT7RCdyE9SoQkV9CpHNkGNC87z7Q ud4S109nGQruSLvdu8DSq8GjpwcztcWh51n8DHLatbnJOfEjUnUtq2jspOZphu+n0bPmRO jjI0R4yZmbFyJJjCl3fxMpRJW1ilavSHc8O9RRbJJAoHzTNh05iKtd2KaBLmXsjigtVTB7 az9+T45ustVGwGc2kbihHJyi4BZ+qeFtWCy8Q7gF1qicn2HD9eUZDxkbinL3Ncb90CnaH8 GvfpkZpcb7XpNGKUhMeij3yHeCF9NEE26PmFKP88xZREbOzOEIJM6aSXj0QDzw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1692517066; 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=SeDUWkcxw4uiIHgdb7I7RoLF633DkLR5oUj10yMEJeA=; b=kGDql71vwYCv2uCAFiD9pBD/qrHuADYp8o75QCozfUtUJPP64ffIy4yRXpY2N0cYfWtAvk 3HQfCOPZKSqfGVl2+n9K8v50tsU/E5U2qZ7E1Wl7+1z05FKE0kCZgNNGq1Uuy69y2SGscS XZerRa8lhV360XxBrmUxZHr5mJXXE0hUeQKRUoD3nxySNCKAs2KHwQh0TWx42aTU5et/fv I80dThHuoUdEoW+ng0sx3uFhe61olPnSa2aqnGyY4riFwXL0Yh4aRzZvJ/9f86CarkcDay 7UW5RYXwxBr5WTLituNdTnvXSWKlq43ns4OYmh0ZR6p0ALcVoQ+pJHG4BGpEVA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1692517066; a=rsa-sha256; cv=none; b=bG92JQMzXjjVvrSVc0DCLfyuKr1HnmrJEQWynvhihAm3BDglp7pANsyXh4yFIc3x1evxP3 LAOFbY3Rp6EOSO2uAYIe3d60KaIGYVzPNLWPRiT04hW4m4EwSaWG2Tdir9/2XWCzmBJLgx 232KdhlHI8iHgsncNrMgSxpXoxm2J5Rv9j21tB5X6q7ZVQAlObszsAUtm/j8ik6ZB/1YkC mbRpLvjCSFq6mPDcTbRVGnEAnFxNNQEzCvgCUyr835L7fUceP4rl3PAcmpHfp4DXpoI/Mf 2iHgnPueDOv/1T+AcTg9xdrJWu4GuaK5JFlSWbV6hNVf1L23aUrleiiF92FTeA== 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 4RT6s62CWdzWSk; Sun, 20 Aug 2023 07:37:46 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 37K7bknA049653; Sun, 20 Aug 2023 07:37:46 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 37K7bkOX049650; Sun, 20 Aug 2023 07:37:46 GMT (envelope-from git) Date: Sun, 20 Aug 2023 07:37:46 GMT Message-Id: <202308200737.37K7bkOX049650@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Dmitry Chagin Subject: git: aad4b799f78a - main - linux(4): Add a writev syscall wrapper List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-src-main@freebsd.org X-BeenThere: dev-commits-src-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dchagin X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: aad4b799f78a8177732b27badc133d734f9c77d8 Auto-Submitted: auto-generated The branch main has been updated by dchagin: URL: https://cgit.FreeBSD.org/src/commit/?id=aad4b799f78a8177732b27badc133d734f9c77d8 commit aad4b799f78a8177732b27badc133d734f9c77d8 Author: Dmitry Chagin AuthorDate: 2023-08-20 07:36:30 +0000 Commit: Dmitry Chagin CommitDate: 2023-08-20 07:36:30 +0000 linux(4): Add a writev syscall wrapper Adding a writev syscall wrapper is needed due to Linux family of write syscalls doesn't distinguish between in kernel blocking operations and always returns EAGAIN while FreeBSD can return ENOBUFS. MFC after: 1 month --- sys/amd64/linux/syscalls.master | 4 ++-- sys/amd64/linux32/syscalls.master | 3 ++- sys/arm64/linux/syscalls.master | 4 ++-- sys/i386/linux/syscalls.master | 4 ++-- 4 files changed, 8 insertions(+), 7 deletions(-) diff --git a/sys/amd64/linux/syscalls.master b/sys/amd64/linux/syscalls.master index 885192963728..88caaa49367b 100644 --- a/sys/amd64/linux/syscalls.master +++ b/sys/amd64/linux/syscalls.master @@ -176,8 +176,8 @@ u_int iovcnt ); } -20 AUE_WRITEV NOPROTO { - int writev( +20 AUE_WRITEV STD { + int linux_writev( int fd, struct iovec *iovp, u_int iovcnt diff --git a/sys/amd64/linux32/syscalls.master b/sys/amd64/linux32/syscalls.master index aa3e420053f4..5ebbe3f6e55d 100644 --- a/sys/amd64/linux32/syscalls.master +++ b/sys/amd64/linux32/syscalls.master @@ -33,6 +33,7 @@ #include #include #include +#include #include #include @@ -775,7 +776,7 @@ 146 AUE_WRITEV STD { int linux_writev( l_ulong fd, - struct l_iovec32 *iovp, + struct iovec32 *iovp, l_ulong iovcnt ); } diff --git a/sys/arm64/linux/syscalls.master b/sys/arm64/linux/syscalls.master index 90c6fcfc4642..daaeeef1acc2 100644 --- a/sys/arm64/linux/syscalls.master +++ b/sys/arm64/linux/syscalls.master @@ -406,8 +406,8 @@ u_int iovcnt ); } -66 AUE_WRITEV NOPROTO { - int writev( +66 AUE_WRITEV STD { + int linux_writev( int fd, struct iovec *iovp, u_int iovcnt diff --git a/sys/i386/linux/syscalls.master b/sys/i386/linux/syscalls.master index 81473ef776aa..6144deeb31ab 100644 --- a/sys/i386/linux/syscalls.master +++ b/sys/i386/linux/syscalls.master @@ -790,8 +790,8 @@ u_int iovcnt ); } -146 AUE_WRITEV NOPROTO { - int writev( +146 AUE_WRITEV STD { + int linux_writev( int fd, struct iovec *iovp, u_int iovcnt