Date: Mon, 3 Feb 2025 12:28:19 GMT From: Zhenlei Huang <zlei@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Subject: git: 67e952ebaaad - stable/13 - if_vxlan(4): Prefer SYSCTL_INT over TUNABLE_INT Message-ID: <202502031228.513CSJf3000604@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch stable/13 has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=67e952ebaaad2f3db00c05b1fe23afdf95c32166 commit 67e952ebaaad2f3db00c05b1fe23afdf95c32166 Author: Zhenlei Huang <zlei@FreeBSD.org> AuthorDate: 2025-01-27 15:54:43 +0000 Commit: Zhenlei Huang <zlei@FreeBSD.org> CommitDate: 2025-02-03 12:27:05 +0000 if_vxlan(4): Prefer SYSCTL_INT over TUNABLE_INT This driver does not need to retrieve those tunable during early boot. Meanwhile SYSCTL_INT can provide rich info such as description. Also `sysctl net.link.vxlan.[legacy_port|reuse_port]` can report the current settings. MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D48621 (cherry picked from commit 92632371b360010709fad60146f1aee0b8b99776) (cherry picked from commit 7d2a5c78a714732f3494c7d8668b36368ed6bc39) --- sys/net/if_vxlan.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/sys/net/if_vxlan.c b/sys/net/if_vxlan.c index f9478da983d8..737a2ae312ac 100644 --- a/sys/net/if_vxlan.c +++ b/sys/net/if_vxlan.c @@ -428,9 +428,11 @@ SYSCTL_NODE(_net_link, OID_AUTO, vxlan, CTLFLAG_RW | CTLFLAG_MPSAFE, 0, "Virtual eXtensible Local Area Network"); static int vxlan_legacy_port = 0; -TUNABLE_INT("net.link.vxlan.legacy_port", &vxlan_legacy_port); +SYSCTL_INT(_net_link_vxlan, OID_AUTO, legacy_port, CTLFLAG_RDTUN, + &vxlan_legacy_port, 0, "Use legacy port"); static int vxlan_reuse_port = 0; -TUNABLE_INT("net.link.vxlan.reuse_port", &vxlan_reuse_port); +SYSCTL_INT(_net_link_vxlan, OID_AUTO, reuse_port, CTLFLAG_RDTUN, + &vxlan_reuse_port, 0, "Re-use port"); /* * This macro controls the default upper limitation on nesting of vxlan
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202502031228.513CSJf3000604>