Move some other SI_SUB_INIT_IF initializations to SI_SUB_TASKQ

Drop the EARLY_AP_STARTUP gtaskqueue code, as gtaskqueues are now
initialized before APs are started.

Reviewed by:	hselasky@, jhb@
Sponsored by:	Dell EMC Isilon
Differential Revision:	https://reviews.freebsd.org/D12054
This commit is contained in:
cem 2017-08-18 18:55:07 +00:00
parent 5b2ee3b7e9
commit e2500ac573
3 changed files with 5 additions and 21 deletions

View File

@ -110,7 +110,7 @@ tasklet_subsystem_init(void *arg __unused)
"tasklet", i, -1, buf);
}
}
SYSINIT(linux_tasklet, SI_SUB_INIT_IF, SI_ORDER_THIRD, tasklet_subsystem_init, NULL);
SYSINIT(linux_tasklet, SI_SUB_TASKQ, SI_ORDER_THIRD, tasklet_subsystem_init, NULL);
static void
tasklet_subsystem_uninit(void *arg __unused)
@ -128,7 +128,7 @@ tasklet_subsystem_uninit(void *arg __unused)
mtx_destroy(&tw->mtx);
}
}
SYSUNINIT(linux_tasklet, SI_SUB_INIT_IF, SI_ORDER_THIRD, tasklet_subsystem_uninit, NULL);
SYSUNINIT(linux_tasklet, SI_SUB_TASKQ, SI_ORDER_THIRD, tasklet_subsystem_uninit, NULL);
void
tasklet_init(struct tasklet_struct *ts,

View File

@ -577,7 +577,7 @@ linux_work_init(void *arg)
system_power_efficient_wq = linux_system_short_wq;
system_unbound_wq = linux_system_short_wq;
}
SYSINIT(linux_work_init, SI_SUB_INIT_IF, SI_ORDER_THIRD, linux_work_init, NULL);
SYSINIT(linux_work_init, SI_SUB_TASKQ, SI_ORDER_THIRD, linux_work_init, NULL);
static void
linux_work_uninit(void *arg)
@ -591,4 +591,4 @@ linux_work_uninit(void *arg)
system_power_efficient_wq = NULL;
system_unbound_wq = NULL;
}
SYSUNINIT(linux_work_uninit, SI_SUB_INIT_IF, SI_ORDER_THIRD, linux_work_uninit, NULL);
SYSUNINIT(linux_work_uninit, SI_SUB_TASKQ, SI_ORDER_THIRD, linux_work_uninit, NULL);

View File

@ -80,21 +80,6 @@ int taskqgroup_adjust(struct taskqgroup *qgroup, int cnt, int stride);
#define TASKQGROUP_DECLARE(name) \
extern struct taskqgroup *qgroup_##name
#ifdef EARLY_AP_STARTUP
#define TASKQGROUP_DEFINE(name, cnt, stride) \
\
struct taskqgroup *qgroup_##name; \
\
static void \
taskqgroup_define_##name(void *arg) \
{ \
qgroup_##name = taskqgroup_create(#name); \
taskqgroup_adjust(qgroup_##name, (cnt), (stride)); \
} \
\
SYSINIT(taskqgroup_##name, SI_SUB_INIT_IF, SI_ORDER_FIRST, \
taskqgroup_define_##name, NULL)
#else /* !EARLY_AP_STARTUP */
#define TASKQGROUP_DEFINE(name, cnt, stride) \
\
struct taskqgroup *qgroup_##name; \
@ -105,7 +90,7 @@ taskqgroup_define_##name(void *arg) \
qgroup_##name = taskqgroup_create(#name); \
} \
\
SYSINIT(taskqgroup_##name, SI_SUB_INIT_IF, SI_ORDER_FIRST, \
SYSINIT(taskqgroup_##name, SI_SUB_TASKQ, SI_ORDER_FIRST, \
taskqgroup_define_##name, NULL); \
\
static void \
@ -116,7 +101,6 @@ taskqgroup_adjust_##name(void *arg) \
\
SYSINIT(taskqgroup_adj_##name, SI_SUB_SMP, SI_ORDER_ANY, \
taskqgroup_adjust_##name, NULL)
#endif /* EARLY_AP_STARTUP */
TASKQGROUP_DECLARE(net);
TASKQGROUP_DECLARE(softirq);