diff --git a/sys/compat/linuxkpi/common/include/linux/kthread.h b/sys/compat/linuxkpi/common/include/linux/kthread.h --- a/sys/compat/linuxkpi/common/include/linux/kthread.h +++ b/sys/compat/linuxkpi/common/include/linux/kthread.h @@ -110,6 +110,17 @@ __w; \ }) +/* + * On Linux, `kthread_run_worker()` differs from `kthread_create_worker()` by + * waking up the task after creating it with `kthread_create_worker()`. + * + * On FreeBSD, we already execute it and wait for it, so probably no need to do + * anything further. Therefore, `kthread_run_worker()` is an alias to + * `kthread_create_worker()`. + */ +#define kthread_run_worker(flags, fmt, ...) \ + kthread_create_worker(flags, fmt, ##__VA_ARGS__) + static inline void kthread_destroy_worker(struct kthread_worker *worker) {