From nobody Mon Jan 5 18:03:25 2026 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 4dlMby0mwjz6Mqpt for ; Mon, 05 Jan 2026 18:03:26 +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 "R13" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4dlMby03t0z4D4q for ; Mon, 05 Jan 2026 18:03:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1767636206; 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=uAnydi28zerURpej4haMrXCyOP2KT4FNcRwrZf4d+o4=; b=bnuv6NFrA7z3XmsXejJwH2Kn04p+hdInNubo66hhjD3TAKelSqt6NykptrhuQZGKgF+MSM /Ac368icPor979QmDD7z+9vXn0pxB6IjMDWv8iGddvdQGplskxtDRn9qVpyq/5g0ZBcGaW 0eJbXg3veXO4evxZknkjaxBzP6aD1CbgIJHkP5WKjNqn0vN3JwVfW8pJNpMn/fHtyhnhht tjomF80tXlTQRKbH2WjPl2PkMvHZ7PiiggQocZJ6Q/0aMJNw8bkZQH4qzqwCH5HkLUbPH8 HM/ek+GG56IaqU0PIP5oKay/AqqEQnXAoyzxis8W6Iu5GCU/G9XUOvvngCe6EA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1767636206; 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=uAnydi28zerURpej4haMrXCyOP2KT4FNcRwrZf4d+o4=; b=j5EZP/l1P0Xwsm2iG997rr+/L2TyWPobSu/eZVhj99BoCh08MFwRSEU1w/x7d4OBVyS5Ps 8VoXZVHhfRJRNVtjioDquUZG+oP770VOzNAwveMTZHLNb6eMi0+axTdioWWINlagUsLLEF MJ+JSSp/hravCuS6K9LiyVMv1AHIeYvYUcHIh+AS1xPrK2LF+mcb1F3vwTcqkqjn6h4Wjp iyryadZfxLdZiL1ydgddhf0X8rSmQTEgkfoLOXU86JbaSB1j3ifoVttPupPnKLTc1bJQ+T R9UzucdeYqhggRuNXuXJ85sVFIMyYkYqQ9VUiTKnVCuBR2db5rftTwHWLOjP2g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1767636206; a=rsa-sha256; cv=none; b=GhNEmBdVaRQmUpn7dOmhzyTW2ez4ox/9TnIDX9GyZfQM5ELiCphI7/2ISa/K6gqrwBcdmo Y5ZNcQ1x4O/fESmnFv2GutkzO0BreSgCl9+auOYgZF/YCkPDIBZEferyGrxH1sKHLFUeNG oiAH96Ewbu15dXrEK5ei+sv7xY6vg0m/MWOtPavncc1PJTOJwHxLrK3saFa85wuDTE6bS4 O1wJD6JwK5Q5o3BJk0pPFQesl55e8hzZZb6/+U6hm6ELAyxVLXnVF9gzNxC6lIuF2EfxdL 5g+2hMHAPqW3vwrtWSsMIoBaSnqUgSbuUWaEkaGcoj8ASj4IM8S1y95hBOmh0A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4dlMbx6b7dzXMJ for ; Mon, 05 Jan 2026 18:03:25 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3372d by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 05 Jan 2026 18:03:25 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Gleb Smirnoff Subject: git: e4e30d5a8136 - main - ipfw: remove extraneous argument from ipfw_add_protected_rule() 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: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-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: e4e30d5a81367b96dc8255252b527d6a65bb43b3 Auto-Submitted: auto-generated Date: Mon, 05 Jan 2026 18:03:25 +0000 Message-Id: <695bfced.3372d.5531791d@gitrepo.freebsd.org> The branch main has been updated by glebius: URL: https://cgit.FreeBSD.org/src/commit/?id=e4e30d5a81367b96dc8255252b527d6a65bb43b3 commit e4e30d5a81367b96dc8255252b527d6a65bb43b3 Author: Gleb Smirnoff AuthorDate: 2026-01-05 18:03:10 +0000 Commit: Gleb Smirnoff CommitDate: 2026-01-05 18:03:10 +0000 ipfw: remove extraneous argument from ipfw_add_protected_rule() This function is always called with unlocked IPFW_UH_LOCK. --- sys/netpfil/ipfw/ip_fw2.c | 2 +- sys/netpfil/ipfw/ip_fw_dynamic.c | 2 +- sys/netpfil/ipfw/ip_fw_private.h | 3 +-- sys/netpfil/ipfw/ip_fw_sockopt.c | 5 ++--- 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/sys/netpfil/ipfw/ip_fw2.c b/sys/netpfil/ipfw/ip_fw2.c index c27b6bc274fb..4e13e6e55f1d 100644 --- a/sys/netpfil/ipfw/ip_fw2.c +++ b/sys/netpfil/ipfw/ip_fw2.c @@ -3692,7 +3692,7 @@ vnet_ipfw_init(const void *unused) rule->cmd[0].len = 1; rule->cmd[0].opcode = default_to_accept ? O_ACCEPT : O_DENY; chain->default_rule = rule; - ipfw_add_protected_rule(chain, rule, 0); + ipfw_add_protected_rule(chain, rule); ipfw_eaction_init(chain, first); ipfw_init_skipto_cache(chain); diff --git a/sys/netpfil/ipfw/ip_fw_dynamic.c b/sys/netpfil/ipfw/ip_fw_dynamic.c index cfb686594c7c..34e4e638e65a 100644 --- a/sys/netpfil/ipfw/ip_fw_dynamic.c +++ b/sys/netpfil/ipfw/ip_fw_dynamic.c @@ -3175,7 +3175,7 @@ dyn_add_protected_rule(struct ip_fw_chain *chain) cmd->opcode = O_COUNT; rule->act_ofs = cmd - rule->cmd; rule->cmd_len = rule->act_ofs + 1; - ipfw_add_protected_rule(chain, rule, 0); + ipfw_add_protected_rule(chain, rule); } void diff --git a/sys/netpfil/ipfw/ip_fw_private.h b/sys/netpfil/ipfw/ip_fw_private.h index c60b7aa47e94..32ae54581833 100644 --- a/sys/netpfil/ipfw/ip_fw_private.h +++ b/sys/netpfil/ipfw/ip_fw_private.h @@ -646,8 +646,7 @@ void ipfw_destroy_skipto_cache(struct ip_fw_chain *chain); void ipfw_enable_skipto_cache(struct ip_fw_chain *chain); int ipfw_find_rule(struct ip_fw_chain *chain, uint32_t key, uint32_t id); int ipfw_ctl3(struct sockopt *sopt); -int ipfw_add_protected_rule(struct ip_fw_chain *chain, struct ip_fw *rule, - int locked); +int ipfw_add_protected_rule(struct ip_fw_chain *chain, struct ip_fw *rule); void ipfw_reap_add(struct ip_fw_chain *chain, struct ip_fw **head, struct ip_fw *rule); void ipfw_reap_rules(struct ip_fw *head); diff --git a/sys/netpfil/ipfw/ip_fw_sockopt.c b/sys/netpfil/ipfw/ip_fw_sockopt.c index a91fb2e84da9..2126c3e1c8a6 100644 --- a/sys/netpfil/ipfw/ip_fw_sockopt.c +++ b/sys/netpfil/ipfw/ip_fw_sockopt.c @@ -568,12 +568,11 @@ ipfw_commit_rules(struct ip_fw_chain *chain, struct rule_check_info *rci, } int -ipfw_add_protected_rule(struct ip_fw_chain *chain, struct ip_fw *rule, - int locked) +ipfw_add_protected_rule(struct ip_fw_chain *chain, struct ip_fw *rule) { struct ip_fw **map; - map = get_map(chain, 1, locked); + map = get_map(chain, 1, 0); if (map == NULL) return (ENOMEM); if (chain->n_rules > 0)