Date: Wed, 9 May 2018 18:51:35 +0000 (UTC) From: Matt Macy <mmacy@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r333426 - in head/sys: kern sys Message-ID: <201805091851.w49IpZQ5017834@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mmacy Date: Wed May 9 18:51:35 2018 New Revision: 333426 URL: https://svnweb.freebsd.org/changeset/base/333426 Log: Add taskqgroup_config_gtask_deinit to support teardown after taskqgroup_config_gtask_init. Approved by: sbruno Modified: head/sys/kern/subr_gtaskqueue.c head/sys/sys/gtaskqueue.h Modified: head/sys/kern/subr_gtaskqueue.c ============================================================================== --- head/sys/kern/subr_gtaskqueue.c Wed May 9 18:47:24 2018 (r333425) +++ head/sys/kern/subr_gtaskqueue.c Wed May 9 18:51:35 2018 (r333426) @@ -987,3 +987,9 @@ taskqgroup_config_gtask_init(void *ctx, struct groupta GROUPTASK_INIT(gtask, 0, fn, ctx); taskqgroup_attach(qgroup_config, gtask, gtask, -1, name); } + +void +taskqgroup_config_gtask_deinit(struct grouptask *gtask) +{ + taskqgroup_detach(qgroup_config, gtask); +} Modified: head/sys/sys/gtaskqueue.h ============================================================================== --- head/sys/sys/gtaskqueue.h Wed May 9 18:47:24 2018 (r333425) +++ head/sys/sys/gtaskqueue.h Wed May 9 18:51:35 2018 (r333426) @@ -63,6 +63,7 @@ void taskqgroup_destroy(struct taskqgroup *qgroup); int taskqgroup_adjust(struct taskqgroup *qgroup, int cnt, int stride); void taskqgroup_config_gtask_init(void *ctx, struct grouptask *gtask, gtask_fn_t *fn, const char *name); +void taskqgroup_config_gtask_deinit(struct grouptask *gtask); #define TASK_ENQUEUED 0x1 #define TASK_SKIP_WAKEUP 0x2
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201805091851.w49IpZQ5017834>