writeback_inodes_sb{_nr}_if_idle() is not invoked by other functions, so cleanup them. No module calls writeback_inodes_sb_nr(), so its export is unused, cleanup it. Signed-off-by: Miao Xie <miaox@xxxxxxxxxxxxxx> --- fs/fs-writeback.c | 44 -------------------------------------------- include/linux/writeback.h | 3 --- 2 files changed, 0 insertions(+), 47 deletions(-) diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c index b0c35c3..7bcb822 100644 --- a/fs/fs-writeback.c +++ b/fs/fs-writeback.c @@ -1230,7 +1230,6 @@ void writeback_inodes_sb_nr(struct super_block *sb, bdi_queue_work(sb->s_bdi, &work); wait_for_completion(&done); } -EXPORT_SYMBOL(writeback_inodes_sb_nr); /** * writeback_inodes_sb - writeback dirty inodes from given super_block @@ -1248,49 +1247,6 @@ void writeback_inodes_sb(struct super_block *sb, enum wb_reason reason) EXPORT_SYMBOL(writeback_inodes_sb); /** - * writeback_inodes_sb_if_idle - start writeback if none underway - * @sb: the superblock - * @reason: reason why some writeback work was initiated - * - * Invoke writeback_inodes_sb if no writeback is currently underway. - * Returns 1 if writeback was started, 0 if not. - */ -int writeback_inodes_sb_if_idle(struct super_block *sb, enum wb_reason reason) -{ - if (!writeback_in_progress(sb->s_bdi)) { - down_read(&sb->s_umount); - writeback_inodes_sb(sb, reason); - up_read(&sb->s_umount); - return 1; - } else - return 0; -} -EXPORT_SYMBOL(writeback_inodes_sb_if_idle); - -/** - * writeback_inodes_sb_nr_if_idle - start writeback if none underway - * @sb: the superblock - * @nr: the number of pages to write - * @reason: reason why some writeback work was initiated - * - * Invoke writeback_inodes_sb if no writeback is currently underway. - * Returns 1 if writeback was started, 0 if not. - */ -int writeback_inodes_sb_nr_if_idle(struct super_block *sb, - unsigned long nr, - enum wb_reason reason) -{ - if (!writeback_in_progress(sb->s_bdi)) { - down_read(&sb->s_umount); - writeback_inodes_sb_nr(sb, nr, reason); - up_read(&sb->s_umount); - return 1; - } else - return 0; -} -EXPORT_SYMBOL(writeback_inodes_sb_nr_if_idle); - -/** * try_to_writeback_inodes_sb_nr - try to start writeback if none underway * @sb: the superblock * @nr: the number of pages to write diff --git a/include/linux/writeback.h b/include/linux/writeback.h index d8e2a99..0552d1a 100644 --- a/include/linux/writeback.h +++ b/include/linux/writeback.h @@ -86,9 +86,6 @@ int inode_wait(void *); void writeback_inodes_sb(struct super_block *, enum wb_reason reason); void writeback_inodes_sb_nr(struct super_block *, unsigned long nr, enum wb_reason reason); -int writeback_inodes_sb_if_idle(struct super_block *, enum wb_reason reason); -int writeback_inodes_sb_nr_if_idle(struct super_block *, unsigned long nr, - enum wb_reason reason); int try_to_writeback_inodes_sb(struct super_block *, enum wb_reason reason); int try_to_writeback_inodes_sb_nr(struct super_block *, unsigned long nr, enum wb_reason reason); -- 1.7.6.5 -- To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html