Ensure that we don't miss a trigger for kicking off the SCTP iterator.

Reported by:		nwhitehorn@
MFC after:		1 week
This commit is contained in:
Michael Tuexen 2020-01-05 13:56:32 +00:00
parent 2e77cad11d
commit 397b1c945f

View File

@ -1475,12 +1475,11 @@ sctp_iterator_work(struct sctp_iterator *it)
void
sctp_iterator_worker(void)
{
struct sctp_iterator *it, *nit;
struct sctp_iterator *it;
/* This function is called with the WQ lock in place */
sctp_it_ctl.iterator_running = 1;
TAILQ_FOREACH_SAFE(it, &sctp_it_ctl.iteratorhead, sctp_nxt_itr, nit) {
while ((it = TAILQ_FIRST(&sctp_it_ctl.iteratorhead)) != NULL) {
/* now lets work on this one */
TAILQ_REMOVE(&sctp_it_ctl.iteratorhead, it, sctp_nxt_itr);
SCTP_IPI_ITERATOR_WQ_UNLOCK();