From nobody Thu Aug 01 18:21:22 2024 X-Original-To: dev-commits-src-all@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 4WZcjZ65pjz5RCLG; Thu, 01 Aug 2024 18:21:22 +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 "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4WZcjZ5fSxz42tk; Thu, 1 Aug 2024 18:21:22 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1722536482; 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=l26naueaE8y3r0MHEeuXQwjiqsSawRyANDzrAk1qP5s=; b=E+W/irIckVXuFTG0H5vGLMtvyCGTUHffWUkpQxgmHzVo6hon+4va/ln3GjDn0+/nNaW+4q Vc6QEoWvC2t9mKVK98dz6l1hJqzDcCx0LlDOtfG+GBBQA22qbhJ+nDmn/MciN3pqiMGAKQ 5pF2jnvmRPAmJ98iNhMJ3h5B9hHHGlB9qb492e0DpfroP5vTCp7sw/E+FXYzAStgUNmfQY z8WWLwBFfTEwc/f8Unom6QZjBYseDOcRE6pUMSJZTlZLF7ahGatnKUzDaDiKVHFyf1ckmd EqwdzwvQb8R7Mc5jQ1vcBgjZQ52JuLBRWBbQRq5qC33VKCLo776bTtg1zKYQsw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1722536482; a=rsa-sha256; cv=none; b=ksJHcHmFcAcP5oSX/yQdR8uZMKtOpU+oczj5U/uFOXXNUzUqyjmg3vANht/HiHJ2+2Xgiw mSWy062Kn3mse1iqBIwMahQdXUi47ywUqxxJ5nxTeioepoqTklxaE+npyY8fTQNDwfl/9g s0kiAGH/yEzk3hAMNznCwFps/0ZtR8gCLKDjQtkK6XQi9lNgcZIeSfYbsAw9HvNp1IXS8I 9v3SJyXuy88WXUosFUAhq4FaP7hIfnBdku6ZTPgZDxJihcduNoQQCSZS2QB2DWtuVaVkMe yw38DQdStSbuyVrb7veQT8vT79OoXzoW3qB0ipGWyEYBWK/QXyKLwi9QM2GOcQ== 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=1722536482; 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=l26naueaE8y3r0MHEeuXQwjiqsSawRyANDzrAk1qP5s=; b=H9bm9tV8bP+NbRjKOmmC+2D9kNGzeWQmlCrnKwa5Lb6Ho3+Wa6AxScbVQWvYKmsJO+NfuX JbqzVeuEnoqtm50OL/GHxuQwkoaGHCM3qUBLHPJiqCn8OVRaZc9zS0c4dvOrUkHZ62WBkk V1NBAdIuZf18e8eFZT750tiMfe0mtVL6BvgSpIVNwomTioNLVVL0HbfXWJ8vegOdhn/C// DKAKNdRuCMRQcYYWq6ML01ZIfxIKxJNs8NkBv7taPiqlbEKjGPh9ES8h4ErJlUtRLfHbEI JsqWRGe9Bl3WX7Vkrdd9T+eKJythEYUE3LpD7ghr2D1XLo4sZVXxAGpgT8+rhQ== 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 4WZcjZ5GDBzvJl; Thu, 1 Aug 2024 18:21:22 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 471ILMMa010387; Thu, 1 Aug 2024 18:21:22 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 471ILMYb010369; Thu, 1 Aug 2024 18:21:22 GMT (envelope-from git) Date: Thu, 1 Aug 2024 18:21:22 GMT Message-Id: <202408011821.471ILMYb010369@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Zhenlei Huang Subject: git: 7797719d3a8b - stable/13 - fibs: Limit the WARNING message to only once when setting up with multiple fibs List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@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/stable/13 X-Git-Reftype: branch X-Git-Commit: 7797719d3a8b1eb50e57c6652f744a6bffc91599 Auto-Submitted: auto-generated The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=7797719d3a8b1eb50e57c6652f744a6bffc91599 commit 7797719d3a8b1eb50e57c6652f744a6bffc91599 Author: Zhenlei Huang AuthorDate: 2024-08-01 18:00:45 +0000 Commit: Zhenlei Huang CommitDate: 2024-08-01 18:04:54 +0000 fibs: Limit the WARNING message to only once when setting up with multiple fibs In main [1] this warning message is suppressed but no plans to MFC the change as the message may be still useful for users that upgrade from older releases to 14.x or 13.x. Well emitting this warning message every time increasing the fib number is confusing for users not for the feature `net.add_addr_allfibs`, let's limit it to be printed only once. 1. a48f7a2eb90b fibs: Suppress the WARNING message for setups with multiple fibs This is a direct commit to stable/14 and stable/13. PR: 280097 Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D46204 (cherry picked from commit 352dd826ffdd88d26744023fe8bcff795bdf64d8) --- sys/net/route/route_tables.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/sys/net/route/route_tables.c b/sys/net/route/route_tables.c index 45c1b6cab8ed..47fe5cfae1dd 100644 --- a/sys/net/route/route_tables.c +++ b/sys/net/route/route_tables.c @@ -217,6 +217,7 @@ populate_kernel_routes(struct rib_head **new_rt_tables, struct rib_head *rh) static void grow_rtables(uint32_t num_tables) { + static bool printedonce; struct domain *dom; struct rib_head **prnh, *rh; struct rib_head **new_rt_tables, **old_rt_tables; @@ -230,10 +231,12 @@ grow_rtables(uint32_t num_tables) new_rt_tables = mallocarray(num_tables * (AF_MAX + 1), sizeof(void *), M_RTABLE, M_WAITOK | M_ZERO); - if ((num_tables > 1) && (V_rt_add_addr_allfibs == 0)) + if (num_tables > 1 && V_rt_add_addr_allfibs == 0 && !printedonce) { + printedonce = true; printf("WARNING: Adding ifaddrs to all fibs has been turned off " "by default. Consider tuning %s if needed\n", "net.add_addr_allfibs"); + } #ifdef FIB_ALGO fib_grow_rtables(num_tables);