lkml.org 
[lkml]   [2002]   [Feb]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: [PATCH][RFC] kthread abstraction
    Date
    On February 01, 2002 09:38, Christoph Hellwig wrote:
    > Currently the startup of custom kernel threads contains lots
    > of duplicated code (and bugs!).

    Very interesting and approachable patch. Am I correct this replaces the API
    for starting threads like bdflush and kswapd? Is this just an API
    cleanliness thing or is there a performance motivation?

    Just one question....

    >
    > I'd like to propose the following interface to get rid of these
    > code waste:
    >
    > int kthread_start(struct kthread *kth)
    >
    > Startup a new kernel thread as described by 'kth' (details
    > below). Wait until it has finished initialization.
    >
    >
    > void kthread_stop(struct kthread *kth)

    Do you think you could get by just passing struct task_struct here? I
    realize that would make it less pleasant for calling functions. However, it
    would also prevent you from changing something else in the kthread in a later
    version and catching a caller by surprise.

    Otherwise, looks nice to my naive eyes :)

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

    \
     
     \ /
      Last update: 2005-03-22 13:23    [W:2.378 / U:0.168 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site