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

From: Srivatsa S. Bhat
Date: Thu Jun 14 2012 - 04:37:08 EST


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@xxxxxxxxxxxxx>
> ---
>
> /**
> + * 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

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/