pfctl: Ensure parent queue is configured for FAIRQ
We failed to account for the FAIRQ scheduler in expand_altq(), which led it to be set up without its parent queue. MFC after: 1 week Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D30347
This commit is contained in:
parent
26705a39e5
commit
dc78428796
@ -5107,7 +5107,8 @@ expand_altq(struct pf_altq *a, struct node_if *interfaces,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (pa.scheduler == ALTQT_CBQ ||
|
if (pa.scheduler == ALTQT_CBQ ||
|
||||||
pa.scheduler == ALTQT_HFSC) {
|
pa.scheduler == ALTQT_HFSC ||
|
||||||
|
pa.scheduler == ALTQT_FAIRQ) {
|
||||||
/* now create a root queue */
|
/* now create a root queue */
|
||||||
memset(&pb, 0, sizeof(struct pf_altq));
|
memset(&pb, 0, sizeof(struct pf_altq));
|
||||||
if (strlcpy(qname, "root_", sizeof(qname)) >=
|
if (strlcpy(qname, "root_", sizeof(qname)) >=
|
||||||
@ -5138,7 +5139,8 @@ expand_altq(struct pf_altq *a, struct node_if *interfaces,
|
|||||||
if (n == NULL)
|
if (n == NULL)
|
||||||
err(1, "expand_altq: calloc");
|
err(1, "expand_altq: calloc");
|
||||||
if (pa.scheduler == ALTQT_CBQ ||
|
if (pa.scheduler == ALTQT_CBQ ||
|
||||||
pa.scheduler == ALTQT_HFSC)
|
pa.scheduler == ALTQT_HFSC ||
|
||||||
|
pa.scheduler == ALTQT_FAIRQ)
|
||||||
if (strlcpy(n->parent, qname,
|
if (strlcpy(n->parent, qname,
|
||||||
sizeof(n->parent)) >=
|
sizeof(n->parent)) >=
|
||||||
sizeof(n->parent))
|
sizeof(n->parent))
|
||||||
|
Loading…
Reference in New Issue
Block a user