aboutsummaryrefslogtreecommitdiff
path: root/sys/netinet/cc/cc_hd.c
diff options
context:
space:
mode:
authorPawel Biernacki <kaktus@FreeBSD.org>2020-02-26 14:26:36 +0000
committerPawel Biernacki <kaktus@FreeBSD.org>2020-02-26 14:26:36 +0000
commit7029da5c36f2d3cf6bb6c81bf551229f416399e8 (patch)
tree53cae9da1371117a3ac21d0d0f3f030a692807ae /sys/netinet/cc/cc_hd.c
parentd7313dc6f5fcab29946951936597772dfff6a4be (diff)
downloadsrc-7029da5c36f2d3cf6bb6c81bf551229f416399e8.tar.gz
src-7029da5c36f2d3cf6bb6c81bf551229f416399e8.zip
Mark more nodes as CTLFLAG_MPSAFE or CTLFLAG_NEEDGIANT (17 of many)
r357614 added CTLFLAG_NEEDGIANT to make it easier to find nodes that are still not MPSAFE (or already are but aren’t properly marked). Use it in preparation for a general review of all nodes. This is non-functional change that adds annotations to SYSCTL_NODE and SYSCTL_PROC nodes using one of the soon-to-be-required flags. Mark all obvious cases as MPSAFE. All entries that haven't been marked as MPSAFE before are by default marked as NEEDGIANT Approved by: kib (mentor, blanket) Commented by: kib, gallatin, melifaro Differential Revision: https://reviews.freebsd.org/D23718
Notes
Notes: svn path=/head/; revision=358333
Diffstat (limited to 'sys/netinet/cc/cc_hd.c')
-rw-r--r--sys/netinet/cc/cc_hd.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/sys/netinet/cc/cc_hd.c b/sys/netinet/cc/cc_hd.c
index 7f86e2ff0d74..f9e944ddfc0f 100644
--- a/sys/netinet/cc/cc_hd.c
+++ b/sys/netinet/cc/cc_hd.c
@@ -232,21 +232,23 @@ hd_qthresh_handler(SYSCTL_HANDLER_ARGS)
}
SYSCTL_DECL(_net_inet_tcp_cc_hd);
-SYSCTL_NODE(_net_inet_tcp_cc, OID_AUTO, hd, CTLFLAG_RW, NULL,
+SYSCTL_NODE(_net_inet_tcp_cc, OID_AUTO, hd, CTLFLAG_RW | CTLFLAG_MPSAFE, NULL,
"Hamilton delay-based congestion control related settings");
SYSCTL_PROC(_net_inet_tcp_cc_hd, OID_AUTO, queue_threshold,
- CTLFLAG_VNET | CTLTYPE_UINT | CTLFLAG_RW, &VNET_NAME(hd_qthresh), 20,
- &hd_qthresh_handler, "IU", "queueing congestion threshold (qth) in ticks");
+ CTLFLAG_VNET | CTLTYPE_UINT | CTLFLAG_RW | CTLFLAG_NEEDGIANT,
+ &VNET_NAME(hd_qthresh), 20, &hd_qthresh_handler, "IU",
+ "queueing congestion threshold (qth) in ticks");
SYSCTL_PROC(_net_inet_tcp_cc_hd, OID_AUTO, pmax,
- CTLFLAG_VNET | CTLTYPE_UINT | CTLFLAG_RW, &VNET_NAME(hd_pmax), 5,
- &hd_pmax_handler, "IU",
+ CTLFLAG_VNET | CTLTYPE_UINT | CTLFLAG_RW | CTLFLAG_NEEDGIANT,
+ &VNET_NAME(hd_pmax), 5, &hd_pmax_handler, "IU",
"per packet maximum backoff probability as a percentage");
SYSCTL_PROC(_net_inet_tcp_cc_hd, OID_AUTO, queue_min,
- CTLFLAG_VNET | CTLTYPE_UINT | CTLFLAG_RW, &VNET_NAME(hd_qmin), 5,
- &hd_qmin_handler, "IU", "minimum queueing delay threshold (qmin) in ticks");
+ CTLFLAG_VNET | CTLTYPE_UINT | CTLFLAG_RW | CTLFLAG_NEEDGIANT,
+ &VNET_NAME(hd_qmin), 5, &hd_qmin_handler, "IU",
+ "minimum queueing delay threshold (qmin) in ticks");
DECLARE_CC_MODULE(hd, &hd_cc_algo);
MODULE_DEPEND(hd, ertt, 1, 1, 1);