diff options
author | Lukas Czerner <lczerner@redhat.com> | 2010-10-27 21:30:11 -0400 |
---|---|---|
committer | Theodore Ts'o <tytso@mit.edu> | 2010-10-27 21:30:11 -0400 |
commit | 77ca6cdf0ab8a42f481ec997911bc89e79138723 (patch) | |
tree | 30f6cb268a3b4cad391e5784557b2c6432b52691 | |
parent | 877836905da55e8f2426234f42a89287184949e9 (diff) | |
download | op-kernel-dev-77ca6cdf0ab8a42f481ec997911bc89e79138723.zip op-kernel-dev-77ca6cdf0ab8a42f481ec997911bc89e79138723.tar.gz |
ext4: Use return value from sb_issue_discard()
Use return value from sb_issue_discard() as return value in
ext4_issue_discard(). Since sb_issue_discard() may result in more
serious errors than just -EOPNOTSUPP it is worth to inform user of this
function about them to handle error cases properly.
Signed-off-by: Lukas Czerner <lczerner@redhat.com>
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
-rw-r--r-- | fs/ext4/mballoc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c index 611c866..11c2eec 100644 --- a/fs/ext4/mballoc.c +++ b/fs/ext4/mballoc.c @@ -2603,7 +2603,7 @@ int ext4_mb_release(struct super_block *sb) return 0; } -static inline void ext4_issue_discard(struct super_block *sb, +static inline int ext4_issue_discard(struct super_block *sb, ext4_group_t block_group, ext4_grpblk_t block, int count) { int ret; @@ -2617,6 +2617,7 @@ static inline void ext4_issue_discard(struct super_block *sb, ext4_warning(sb, "discard not supported, disabling"); clear_opt(EXT4_SB(sb)->s_mount_opt, DISCARD); } + return ret; } /* |