Skip to content

Commit

Permalink
reiserfs: clean-up function return type
Browse files Browse the repository at this point in the history
Turn 'reiserfs_flush_old_commits()' into a void function because the callers
do not cares about what it returns anyway.

We are going to remove the 'sb->s_dirt' field completely and this patch is a
small step towards this direction.

Signed-off-by: Artem Bityutskiy <[email protected]>
Signed-off-by: Al Viro <[email protected]>
  • Loading branch information
dedekind authored and Al Viro committed Jun 1, 2012
1 parent efaa33e commit 25729b0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
8 changes: 3 additions & 5 deletions fs/reiserfs/journal.c
Original file line number Diff line number Diff line change
Expand Up @@ -3492,7 +3492,7 @@ static void flush_async_commits(struct work_struct *work)
** flushes any old transactions to disk
** ends the current transaction if it is too old
*/
int reiserfs_flush_old_commits(struct super_block *sb)
void reiserfs_flush_old_commits(struct super_block *sb)
{
time_t now;
struct reiserfs_transaction_handle th;
Expand All @@ -3502,9 +3502,8 @@ int reiserfs_flush_old_commits(struct super_block *sb)
/* safety check so we don't flush while we are replaying the log during
* mount
*/
if (list_empty(&journal->j_journal_list)) {
return 0;
}
if (list_empty(&journal->j_journal_list))
return;

/* check the current transaction. If there are no writers, and it is
* too old, finish it, and force the commit blocks to disk
Expand All @@ -3526,7 +3525,6 @@ int reiserfs_flush_old_commits(struct super_block *sb)
do_journal_end(&th, sb, 1, COMMIT_NOW | WAIT);
}
}
return sb->s_dirt;
}

/*
Expand Down
2 changes: 1 addition & 1 deletion fs/reiserfs/reiserfs.h
Original file line number Diff line number Diff line change
Expand Up @@ -2452,7 +2452,7 @@ struct reiserfs_transaction_handle *reiserfs_persistent_transaction(struct
int reiserfs_end_persistent_transaction(struct reiserfs_transaction_handle *);
int reiserfs_commit_page(struct inode *inode, struct page *page,
unsigned from, unsigned to);
int reiserfs_flush_old_commits(struct super_block *);
void reiserfs_flush_old_commits(struct super_block *);
int reiserfs_commit_for_inode(struct inode *);
int reiserfs_inode_needs_commit(struct inode *);
void reiserfs_update_inode_transaction(struct inode *);
Expand Down

0 comments on commit 25729b0

Please sign in to comment.