]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Add flag to struct task to mark the task as requiring network epoch.
authorglebius <glebius@FreeBSD.org>
Tue, 11 Feb 2020 18:48:07 +0000 (18:48 +0000)
committerglebius <glebius@FreeBSD.org>
Tue, 11 Feb 2020 18:48:07 +0000 (18:48 +0000)
commit755fde96b65a61f10295db67fc64aa1b77d8c9ab
treea460831d490a3103fdf3f5c457409cbc5b67766f
parentcbc55c85d01e5ae3f31b1087ddd71119831ec42d
Add flag to struct task to mark the task as requiring network epoch.

When processing a taskqueue and a task has associated epoch, then
enter for duration of the task.  If consecutive tasks belong to the
same epoch, batch them.  Now we are talking about the network epoch
only.

Shrink the ta_priority size to 8-bits.  No current consumers use
a priority that won't fit into 8 bits.  Also complexity of
taskqueue_enqueue() is a square of maximum value of priority, so
we unlikely ever want to go over UCHAR_MAX here.

Reviewed by: hselasky
Differential Revision: https://reviews.freebsd.org/D23518
sys/kern/subr_gtaskqueue.c
sys/kern/subr_taskqueue.c
sys/sys/_task.h
sys/sys/epoch.h
sys/sys/gtaskqueue.h
sys/sys/taskqueue.h