Re: [RFC patch 1/5] kthread: Implement park/unpark facility

Srivatsa S. Bhat
2012-06-14T08:37:12Z

On 06/13/2012 04:30 PM, Thomas Gleixner wrote:

> To avoid the full teardown/setup of per cpu kthreads in the case of
> cpu hot(un)plug, provide a facility which allows to put the kthread
> into a park position and unpark it when the cpu comes online again.
>
> Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
> ---
>
> /**
> + * kthread_should_park - should this kthread return now?
> + *
> + * When someone calls kthread_park() on your kthread, it will be woken
> + * and this will return true. You should then return, and your return
> + * value will be passed through to kthread_park().
> + *
> + * Similar to kthread_should_stop(), but this keeps the thread alive
> + * and in a park position. kthread_unpark() "restart" the thread and

s/restart/restarts

> + * calls the thread function again.
> + */

Regards,
Srivatsa S. Bhat