lkml.org 
[lkml]   [2009]   [Jun]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH] [JFFS2] jffs2_start_garbage_collect_thread() return value cleanup
    Date
    There is no user of this return value in the kernel.  Change it to return void
    instead.
    ---
    fs/jffs2/background.c | 7 +------
    fs/jffs2/os-linux.h | 2 +-
    2 files changed, 2 insertions(+), 7 deletions(-)

    diff --git a/fs/jffs2/background.c b/fs/jffs2/background.c
    index 3ff50da..3ae7e5c 100644
    --- a/fs/jffs2/background.c
    +++ b/fs/jffs2/background.c
    @@ -30,10 +30,9 @@ void jffs2_garbage_collect_trigger(struct jffs2_sb_info *c)
    }

    /* This must only ever be called when no GC thread is currently running */
    -int jffs2_start_garbage_collect_thread(struct jffs2_sb_info *c)
    +void jffs2_start_garbage_collect_thread(struct jffs2_sb_info *c)
    {
    struct task_struct *tsk;
    - int ret = 0;

    BUG_ON(c->gc_task);

    @@ -44,15 +43,11 @@ int jffs2_start_garbage_collect_thread(struct jffs2_sb_info *c)
    if (IS_ERR(tsk)) {
    printk(KERN_WARNING "fork failed for JFFS2 garbage collect thread: %ld\n", -PTR_ERR(tsk));
    complete(&c->gc_thread_exit);
    - ret = PTR_ERR(tsk);
    } else {
    /* Wait for it... */
    D1(printk(KERN_DEBUG "JFFS2: Garbage collect thread is pid %d\n", tsk->pid));
    wait_for_completion(&c->gc_thread_start);
    - ret = tsk->pid;
    }
    -
    - return ret;
    }

    void jffs2_stop_garbage_collect_thread(struct jffs2_sb_info *c)
    diff --git a/fs/jffs2/os-linux.h b/fs/jffs2/os-linux.h
    index 2228380..f3184ac 100644
    --- a/fs/jffs2/os-linux.h
    +++ b/fs/jffs2/os-linux.h
    @@ -151,7 +151,7 @@ static inline void jffs2_erase_pending_trigger(struct jffs2_sb_info *c)
    }

    /* background.c */
    -int jffs2_start_garbage_collect_thread(struct jffs2_sb_info *c);
    +void jffs2_start_garbage_collect_thread(struct jffs2_sb_info *c);
    void jffs2_stop_garbage_collect_thread(struct jffs2_sb_info *c);
    void jffs2_garbage_collect_trigger(struct jffs2_sb_info *c);

    --
    1.5.6.5


    \
     
     \ /
      Last update: 2009-06-02 14:15    [W:0.030 / U:0.056 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site