This makes sure the kthread name can't be parsed as a format string.
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Benjamin Romer <benjamin.romer@unisys.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
void *thrcontext, char *name)
{
/* used to stop the thread */
- thrinfo->task = kthread_run(threadfn, thrcontext, name);
+ thrinfo->task = kthread_run(threadfn, thrcontext, "%s", name);
if (IS_ERR(thrinfo->task)) {
pr_debug("%s failed (%ld)\n",
__func__, PTR_ERR(thrinfo->task));