From patchwork Tue Jun 2 12:11:26 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [JFFS2] jffs2_start_garbage_collect_thread() return value cleanup Date: Tue, 02 Jun 2009 02:11:26 -0000 From: Gerard Lledo X-Patchwork-Id: 27996 Message-Id: <1243944686-7039-2-git-send-email-gerard.lledo@gmail.com> To: akpm@linux-foundation.org Cc: linux-mtd@lists.infradead.org, Gerard Lledo , dwmw2@infradead.org, linux-kernel@vger.kernel.org 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);