From nobody Wed Aug 17 18:52:25 2022 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 4M7HFP36Lbz4YxPH; Wed, 17 Aug 2022 18:52:25 +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 4M7HFP2fr6z4D5b; Wed, 17 Aug 2022 18:52:25 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1660762345; 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=4l5fS7k75dBdRC5Qmx1+wYanpHFQaTebydW9BHPTi8c=; b=Cge9CZMGCowM5brl6gE4astiLAoIBzL/V3vqPICt9bbY8ur/tNyos9bu8jgpDYKD335AU2 b95X0ZMvj0gmL+Oa3se6rzXSCzqALDXljhv1o+5NJ9aVgGAVhtSw/e8ZQgpZVd/OAs84yC sCq+kMAf7kdWQANmz7OWhsVK1G1r0A2uauHEhubGZrMd3O9ATzi6Gk20Nf5bFzash4OCk8 UQkxwo7uNlXjac8s7Jio700vS+ENrFnj/+ORB0Va4uuKkGK3rD9gyOLtlodZOqlJVl0IEO pcm4zarmgEXaGbHz/v/hoL5j7Ryy/My1F/2USqGVwRlROx8sJUvC0kcSLQaKrA== 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 4M7HFP1jGgz10t1; Wed, 17 Aug 2022 18:52:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 27HIqPOu013198; Wed, 17 Aug 2022 18:52:25 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 27HIqPwu013197; Wed, 17 Aug 2022 18:52:25 GMT (envelope-from git) Date: Wed, 17 Aug 2022 18:52:25 GMT Message-Id: <202208171852.27HIqPwu013197@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: f6dc5aa3422a - main - unix: use private enum as argument for unp_connect2() 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: glebius X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: f6dc5aa3422a980cd94562deaeb01722fdde71d3 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1660762345; 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=4l5fS7k75dBdRC5Qmx1+wYanpHFQaTebydW9BHPTi8c=; b=tcXTQqzBpwsAj+gc31c8Wub7ND92qsfHwYiMXnmIErILXwk03fZfAUmLshPzkxq5esK1VP +Z/wBBLyBNOo2BTJk+kuhD8tjIx/cKdPrZ3WLu81IIzeKR7vzzYgbRljAY+pOkRfGYQu6p NAyW0YM3d4Zg62xXpMpHb7cDSL+/wCBW6BneAnoE3uA/JSD1s/GQt8cmOhxtg6CAZEn7u0 0F3IOHYdjOq83jHRjPMJqDhtHR3HsiNZItwLUUakmxicP8YqDMn4nLtouqI3KMlfVuJnC8 xG/nb5SMgyveRBqey7eDy24wEa1/dyHR/8gW2EBGRHhVOkQ5kbaWKCqfXjTTSA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1660762345; a=rsa-sha256; cv=none; b=R/bLylCAOjvRUB1Y0uz9+xKk55LYwNuQunb9CmS2l6MXjRDaketgjIVUSbop40JH89Fpq+ kppw85o+7XNf+SWbQrwKYoQUQjVM341ylMFjMeIBWnYKD50kTlE0ZxN5L619t+Q694Qq6G EQ/Sarp4IPsLAlwdvHc0l9PpITrJKc8nUF09m0ORIhgN1AQyznQMJlwoBBAhEojxUe/FFN pWvqsNFkJDdAVFSCWTHBwGPR4y04fQnBVl14NrWMJ4APwM/wofQH+PMlMVyZ+mRusDHyVB p77YSWNurrkya0G/jcw2mzff3+o82nGM/sE8F1tV6QJ/GQm763eJ4/ejtp7IAw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=f6dc5aa3422a980cd94562deaeb01722fdde71d3 commit f6dc5aa3422a980cd94562deaeb01722fdde71d3 Author: Gleb Smirnoff AuthorDate: 2022-08-17 18:50:31 +0000 Commit: Gleb Smirnoff CommitDate: 2022-08-17 18:50:31 +0000 unix: use private enum as argument for unp_connect2() instead of using historic PRU_ flags that are now not used by anything rather than TCP debugging. --- sys/kern/uipc_usrreq.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/sys/kern/uipc_usrreq.c b/sys/kern/uipc_usrreq.c index 3b54c5f145be..eb6404c86320 100644 --- a/sys/kern/uipc_usrreq.c +++ b/sys/kern/uipc_usrreq.c @@ -293,7 +293,8 @@ static int unp_connect(struct socket *, struct sockaddr *, struct thread *); static int unp_connectat(int, struct socket *, struct sockaddr *, struct thread *, bool); -static void unp_connect2(struct socket *so, struct socket *so2, int); +typedef enum { PRU_CONNECT, PRU_CONNECT2 } conn2_how; +static void unp_connect2(struct socket *so, struct socket *so2, conn2_how); static void unp_disconnect(struct unpcb *unp, struct unpcb *unp2); static void unp_dispose(struct socket *so); static void unp_shutdown(struct unpcb *); @@ -2151,7 +2152,7 @@ unp_copy_peercred(struct thread *td, struct unpcb *client_unp, } static void -unp_connect2(struct socket *so, struct socket *so2, int req) +unp_connect2(struct socket *so, struct socket *so2, conn2_how req) { struct unpcb *unp; struct unpcb *unp2;