From nobody Mon Jun 24 09:59:36 2024 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 4W73N86C1hz5NnX8; Mon, 24 Jun 2024 09:59:36 +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 4W73N85hrFz4sNV; Mon, 24 Jun 2024 09:59:36 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1719223176; 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=MjBcuayw7acYFqEPhKW4L88U23Q7bY8kAnpO+ALY9n8=; b=Qii2lVqfZNpOkJGFxhdPpjurD08O/MXR8bvcckFlRLcFL9VCRXxRbAldevcoglM8lEtF++ lIDwIl/1d8npukpKWgntRQd51nLWtl+35PSZJ1eAJO8yv+ASgm3ehaV4123jgOPJPun1WK Mfa/K1HjSDia4dWZDXtVs2yn6UZLfNtlpn4vOgxmkC7zCd049LlDL5Q3dTDX/2od89Fw0u COWxbpTMCi/eEjYC0xGL6AQlaBrW5sNcb66q7CBE1+C19/zjT6rVevWboNfI2ONjxImdgz J3r+M5NmRr5i9tNExNFegKPYFNNeDhxwxMHvVMTCOOH9UkslVZt21wwpb11btA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1719223176; a=rsa-sha256; cv=none; b=SYYJDqEeVySDV7jaYkt5UrOqwOoWP6V+giCaZUwAH5KYuKyOpFNEqOW0cnRDnNj9e0QaV9 7SBpSHVNN0fixoKXGe3KAc2/Mlz/d5G5BVjXWzHkW1ec6XY2EBWWz25uc6CVTK3Jby/KZb XSBkGW4shOO+wsai/7KE7CO8tzlmNCKmrl6WFM2VDK3aTOkGU6afDk/rZ9meOugTFizBF3 3q+WdGxcDdxnKDzP3b0mx5Opcz9BNLR4XZId7sV2XTd/icdN+FgBhC0Rsy3R2z/62Cp6sS kR++BjY1XEhsOsbDJm6yFf72be81XLfU44+iuPHxAGpXq9XOmel0i93WLNzSVg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1719223176; 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=MjBcuayw7acYFqEPhKW4L88U23Q7bY8kAnpO+ALY9n8=; b=kyL1/WzczO3pH3tnJzJrHN8+Pftj8ItdAwqMvG515eN9RqbQqoCg1bZs7IGNIIPFqVSYiG WKvMbrrXfz/uN5gMlRjloEFSVopmC4zfAlfld1nnkQamTtnZ6B74pqb7LzFyokmjc1kgQA xl9U99W0uKeuCy4IAc7hqJJBrNLaXKx303ZsCOGIJbnUuJDrPG9fBoDoxYRxYIfQqlkJ3V 1kGhSItdUpSaP5NNhBEiiH5x0WRWGlgiX9Zrfh11Y29wY+PKvIOVrxFtoOh4NSRvj+5N1O uylyZvLM687DCcaU62MILh5lE1kbFcMuBo3YGtKRTjzM3PuAu0iDyyD7C7H4EA== 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 4W73N85KFhzDqB; Mon, 24 Jun 2024 09:59:36 +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 45O9xaHw097792; Mon, 24 Jun 2024 09:59:36 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 45O9xauN097789; Mon, 24 Jun 2024 09:59:36 GMT (envelope-from git) Date: Mon, 24 Jun 2024 09:59:36 GMT Message-Id: <202406240959.45O9xauN097789@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Zhenlei Huang Subject: git: 71f8fbf9bda4 - main - ifnet: Use NET_EPOCH_WAIT() macro 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: zlei X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 71f8fbf9bda43e3ca2f26d0499b7a88d0f2f7352 Auto-Submitted: auto-generated The branch main has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=71f8fbf9bda43e3ca2f26d0499b7a88d0f2f7352 commit 71f8fbf9bda43e3ca2f26d0499b7a88d0f2f7352 Author: Zhenlei Huang AuthorDate: 2024-06-24 09:57:14 +0000 Commit: Zhenlei Huang CommitDate: 2024-06-24 09:57:14 +0000 ifnet: Use NET_EPOCH_WAIT() macro This makes it easier to grep the usage. Reviewed by: kp MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D45715 --- sys/net/if.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/net/if.c b/sys/net/if.c index c3c27fbf678f..df405f088133 100644 --- a/sys/net/if.c +++ b/sys/net/if.c @@ -594,7 +594,7 @@ if_alloc_domain(u_char type, int numa_domain) old = ifindex_table; ck_pr_store_ptr(&ifindex_table, new); if_indexlim = newlim; - epoch_wait_preempt(net_epoch_preempt); + NET_EPOCH_WAIT(); free(old, M_IFNET); } if (idx > if_index) @@ -1132,7 +1132,7 @@ if_detach_internal(struct ifnet *ifp, bool vmove) * At this point we know the interface still was on the ifnet list * and we removed it so we are in a stable state. */ - epoch_wait_preempt(net_epoch_preempt); + NET_EPOCH_WAIT(); /* * Ensure all pending EPOCH(9) callbacks have been executed. This @@ -1544,7 +1544,7 @@ _if_delgroup_locked(struct ifnet *ifp, struct ifg_list *ifgl, } IFNET_WUNLOCK(); - epoch_wait_preempt(net_epoch_preempt); + NET_EPOCH_WAIT(); EVENTHANDLER_INVOKE(group_change_event, groupname); if (freeifgl) { EVENTHANDLER_INVOKE(group_detach_event, ifgl->ifgl_group);