Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 138847
b: refs/heads/master
c: 32e8b10
h: refs/heads/master
i:
  138845: 1b5e8b8
  138843: 68ef8ca
  138839: cd417e4
  138831: c426721
  138815: bb9b7ff
v: v3
  • Loading branch information
Jeff Mahoney authored and Linus Torvalds committed Mar 30, 2009
1 parent 9bbc078 commit d5a88e3
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 22 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: c3a9c2109f84882b9b3178f6b1838d550d3df0ec
refs/heads/master: 32e8b1062915d00d07d3b88a95174648e369b6a3
23 changes: 4 additions & 19 deletions trunk/fs/reiserfs/journal.c
Original file line number Diff line number Diff line change
Expand Up @@ -4295,14 +4295,15 @@ static int do_journal_end(struct reiserfs_transaction_handle *th,
return journal->j_errno;
}

static void __reiserfs_journal_abort_hard(struct super_block *sb)
/* Send the file system read only and refuse new transactions */
void reiserfs_abort_journal(struct super_block *sb, int errno)
{
struct reiserfs_journal *journal = SB_JOURNAL(sb);
if (test_bit(J_ABORTED, &journal->j_state))
return;

printk(KERN_CRIT "REISERFS: Aborting journal for filesystem on %s\n",
reiserfs_bdevname(sb));
if (!journal->j_errno)
journal->j_errno = errno;

sb->s_flags |= MS_RDONLY;
set_bit(J_ABORTED, &journal->j_state);
Expand All @@ -4312,19 +4313,3 @@ static void __reiserfs_journal_abort_hard(struct super_block *sb)
#endif
}

static void __reiserfs_journal_abort_soft(struct super_block *sb, int errno)
{
struct reiserfs_journal *journal = SB_JOURNAL(sb);
if (test_bit(J_ABORTED, &journal->j_state))
return;

if (!journal->j_errno)
journal->j_errno = errno;

__reiserfs_journal_abort_hard(sb);
}

void reiserfs_journal_abort(struct super_block *sb, int errno)
{
__reiserfs_journal_abort_soft(sb, errno);
}
2 changes: 1 addition & 1 deletion trunk/fs/reiserfs/prints.c
Original file line number Diff line number Diff line change
Expand Up @@ -386,7 +386,7 @@ void reiserfs_abort(struct super_block *sb, int errno, const char *fmt, ...)
error_buf);

sb->s_flags |= MS_RDONLY;
reiserfs_journal_abort(sb, errno);
reiserfs_abort_journal(sb, errno);
}

/* this prints internal nodes (4 keys/items in line) (dc_number,
Expand Down
2 changes: 1 addition & 1 deletion trunk/include/linux/reiserfs_fs.h
Original file line number Diff line number Diff line change
Expand Up @@ -1771,7 +1771,7 @@ int journal_begin(struct reiserfs_transaction_handle *,
struct super_block *p_s_sb, unsigned long);
int journal_join_abort(struct reiserfs_transaction_handle *,
struct super_block *p_s_sb, unsigned long);
void reiserfs_journal_abort(struct super_block *sb, int errno);
void reiserfs_abort_journal(struct super_block *sb, int errno);
void reiserfs_abort(struct super_block *sb, int errno, const char *fmt, ...);
int reiserfs_allocate_list_bitmaps(struct super_block *s,
struct reiserfs_list_bitmap *, unsigned int);
Expand Down

0 comments on commit d5a88e3

Please sign in to comment.