diff options
author | Stephen Hurd <shurd@FreeBSD.org> | 2017-09-16 02:41:38 +0000 |
---|---|---|
committer | Stephen Hurd <shurd@FreeBSD.org> | 2017-09-16 02:41:38 +0000 |
commit | ab2e3f79587150a6a1499417875b4aed7915fead (patch) | |
tree | 5885042f7144171e23cee40c6f202ee4a8874e8f /sys/sys | |
parent | 9fb35c8d7bb2e41f84f8718c4cc6a2360a634b1f (diff) | |
download | src-ab2e3f79587150a6a1499417875b4aed7915fead.tar.gz src-ab2e3f79587150a6a1499417875b4aed7915fead.zip |
Revert r323516 (iflib rollup)
This was really too big of a commit even if everything worked, but there
are multiple new issues introduced in the one huge commit, so it's not
worth keeping this until it's fixed.
I'll work on splitting this up into logical chunks and introduce them one
at a time over the next week or two.
Approved by: sbruno (mentor)
Sponsored by: Limelight Networks
Notes
Notes:
svn path=/head/; revision=323635
Diffstat (limited to 'sys/sys')
-rw-r--r-- | sys/sys/gtaskqueue.h | 37 |
1 files changed, 11 insertions, 26 deletions
diff --git a/sys/sys/gtaskqueue.h b/sys/sys/gtaskqueue.h index be36a4756af8..e85196372323 100644 --- a/sys/sys/gtaskqueue.h +++ b/sys/sys/gtaskqueue.h @@ -58,9 +58,7 @@ int taskqgroup_attach_cpu(struct taskqgroup *qgroup, struct grouptask *grptask, void taskqgroup_detach(struct taskqgroup *qgroup, struct grouptask *gtask); struct taskqgroup *taskqgroup_create(char *name); void taskqgroup_destroy(struct taskqgroup *qgroup); -int taskqgroup_adjust(struct taskqgroup *qgroup, int cnt, int stride, bool ithread, int pri); -int taskqgroup_adjust_once(struct taskqgroup *qgroup, int cnt, int stride, bool ithread, int pri); -void taskqgroup_set_adjust(struct taskqgroup *qgroup, void (*adjust_func)(void*)); +int taskqgroup_adjust(struct taskqgroup *qgroup, int cnt, int stride); #define TASK_ENQUEUED 0x1 #define TASK_SKIP_WAKEUP 0x2 @@ -82,40 +80,27 @@ void taskqgroup_set_adjust(struct taskqgroup *qgroup, void (*adjust_func)(void*) #define TASKQGROUP_DECLARE(name) \ extern struct taskqgroup *qgroup_##name - -#define TASKQGROUP_DEFINE(name, cnt, stride, intr, pri) \ +#define TASKQGROUP_DEFINE(name, cnt, stride) \ \ struct taskqgroup *qgroup_##name; \ \ static void \ -taskqgroup_adjust_##name(void *arg) \ +taskqgroup_define_##name(void *arg) \ { \ - int max = (intr) ? 1 : (cnt); \ - if (arg != NULL) { \ - uintptr_t maxcpu = (uintptr_t) arg; \ - max = maxcpu; \ - } \ - \ - taskqgroup_adjust_once(qgroup_##name, max, (stride), (intr), (pri)); \ + qgroup_##name = taskqgroup_create(#name); \ } \ \ -SYSINIT(taskqgroup_adj_##name, SI_SUB_SMP, SI_ORDER_ANY, \ - taskqgroup_adjust_##name, NULL); \ +SYSINIT(taskqgroup_##name, SI_SUB_TASKQ, SI_ORDER_FIRST, \ + taskqgroup_define_##name, NULL); \ \ static void \ -taskqgroup_define_##name(void *arg) \ +taskqgroup_adjust_##name(void *arg) \ { \ - qgroup_##name = taskqgroup_create(#name); \ - taskqgroup_set_adjust(qgroup_##name, taskqgroup_adjust_##name); \ + taskqgroup_adjust(qgroup_##name, (cnt), (stride)); \ } \ -SYSINIT(taskqgroup_##name, SI_SUB_TASKQ, SI_ORDER_FIRST, \ - taskqgroup_define_##name, NULL) - - - - - - + \ +SYSINIT(taskqgroup_adj_##name, SI_SUB_SMP, SI_ORDER_ANY, \ + taskqgroup_adjust_##name, NULL) TASKQGROUP_DECLARE(net); TASKQGROUP_DECLARE(softirq); |