From nobody Tue Nov 21 18:35:48 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 4SZY3S2dS9z524kK; Tue, 21 Nov 2023 18:35:48 +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 4SZY3S266zz4nwc; Tue, 21 Nov 2023 18:35:48 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1700591748; 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=cmYZLKFoUZ/QlyswuDsqR0uK6NOzY3QlPWYETdKMS0A=; b=nJJKyU1FQ8qognN3T2uOmCyLgQdYRWe3Sko6LUBelNzA2HSpDMV0EmB14ap7JgCiMTuBe+ 4poz/YureEjdSlkSl+OeXw0WQUYOVjUHLP86QRhPFfeYChMZ7+9ekQVkuA/QYR0wEk2kYF gH7YbKCwZoS1BzA4eSGihEoweGyUD6H5y8y76LrlkkCeeURnSjfMbI6v5AkNn/AMHsqvoO kDoiS9PZ26fXd5nCkk7ILrUvXTkmsN2ctZHe0Q5qWhGOTpuvG/FBn7teh3puZBb0IOi/9g emrfjlx8Q5OAOQ45SRPF/Su9pRXhiYf8VtzHwFTMPpaAfVPB5iX6Sg5tWrdqWg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1700591748; 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=cmYZLKFoUZ/QlyswuDsqR0uK6NOzY3QlPWYETdKMS0A=; b=JPjPSwTJ6+H6shJ7UpInD8wmiuJwtiE21bOKXvcRtZyIjd7nMS/5ezxodobt0jkrGXyFNX xoYXdNSKFNGkeLSPlx3PLDPBMGGXPUcPTETRG4Mq6dnAfLjPe96pXka4+VDPG/Hl/051Az 9zi1VFMuG950/iNTXGVZuNb9nW5E+6lQROPKHXYummYQkVtg7AazXHRACuLiTPWCa1TTM9 ETe2Hey5OT0jxnybzo4YsP2zaCeUC9FPtz2O1tZqrfEHn4JJP3/SBbSbH5iBAIsduXsLg3 Vc8reIM7PhJR33iO5qc3ge4dwKZMaMhc/6GFxq7uXo9dKSr1yANeddAvFOvOXw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1700591748; a=rsa-sha256; cv=none; b=JaKXkJ88UvUk1TGlT+59VdObrTwCGf/O1gX48VfGVlLZxqpI8NOes8Uu0A4PqwZ+h27kup DlE/vGz7ybO5A5T3H7JEdKffohJ9o9Ml2mZaTsxpwx2Cf0QQ6A03bfsKXeF7TEzMTXO/YB mnTTEMQhLMsGwNm3XHUQQ/DL9hCplTdayreWzOKbm7wriv8x8qq83RGf1a0RZoEQ18waoh P8qAGs8jSunvxZfdaMvxX3lj33ZDNkUabWpn6S/aswqyX05U902EH4yd8MKDG/yI53Aw2Q lXYBVmyBV95e6y9eSZ9tLrZYRr5cKcz2OE9R1z8aFGahj3O5NjbpweYv0RBTAA== 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 4SZY3S19Z4zmkK; Tue, 21 Nov 2023 18:35:48 +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 3ALIZmYJ045703; Tue, 21 Nov 2023 18:35:48 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 3ALIZmdd045700; Tue, 21 Nov 2023 18:35:48 GMT (envelope-from git) Date: Tue, 21 Nov 2023 18:35:48 GMT Message-Id: <202311211835.3ALIZmdd045700@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Mark Johnston Subject: git: 2f68ae6150aa - main - makesyscall: Simplify a bit emitting syscall declarations 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: markj X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 2f68ae6150aa51d724e22c7e6748adfe2bc932d7 Auto-Submitted: auto-generated The branch main has been updated by markj: URL: https://cgit.FreeBSD.org/src/commit/?id=2f68ae6150aa51d724e22c7e6748adfe2bc932d7 commit 2f68ae6150aa51d724e22c7e6748adfe2bc932d7 Author: Olivier Certner AuthorDate: 2023-10-12 13:47:03 +0000 Commit: Mark Johnston CommitDate: 2023-11-21 18:25:34 +0000 makesyscall: Simplify a bit emitting syscall declarations Reviewed by: kevans, imp MFC after: 2 weeks Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D42168 --- sys/tools/makesyscalls.lua | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) diff --git a/sys/tools/makesyscalls.lua b/sys/tools/makesyscalls.lua index bf631ac2ffdd..8a56310f0068 100644 --- a/sys/tools/makesyscalls.lua +++ b/sys/tools/makesyscalls.lua @@ -865,18 +865,15 @@ local function handle_noncompat(sysnum, thr_flag, flags, sysflags, rettype, local protoflags = get_mask({"NOPROTO", "NODEF"}) if flags & protoflags == 0 then + local sys_prefix = "sys_" if funcname == "nosys" or funcname == "lkmnosys" or funcname == "sysarch" or funcname:find("^freebsd") or funcname:find("^linux") then - write_line("sysdcl", string.format( - "%s\t%s(struct thread *, struct %s *)", - rettype, funcname, argalias)) - else - write_line("sysdcl", string.format( - "%s\tsys_%s(struct thread *, struct %s *)", - rettype, funcname, argalias)) + sys_prefix = "" end - write_line("sysdcl", ";\n") + write_line("sysdcl", string.format( + "%s\t%s%s(struct thread *, struct %s *);\n", + rettype, sys_prefix, funcname, argalias)) write_line("sysaue", string.format("#define\t%sAUE_%s\t%s\n", config.syscallprefix, funcalias, auditev)) end