[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1280935813-4478-4-git-send-email-lczerner@redhat.com>
Date: Wed, 4 Aug 2010 17:30:13 +0200
From: Lukas Czerner <lczerner@...hat.com>
To: linux-ext4@...r.kernel.org
Cc: jmoyer@...hat.com, rwheeler@...hat.com, eshishki@...hat.com,
sandeen@...hat.com, jack@...e.cz, tytso@....edu,
lczerner@...hat.com
Subject: [PATCH 4/4] Ext4 check for negative err from sb_issue_discard
sb_issue_discard is returning negative error code, so check for
negative value instead of positive.
Signed-off-by: Lukas Czerner <lczerner@...hat.com>
---
fs/ext4/mballoc.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c
index a16a813..a8fe7f1 100644
--- a/fs/ext4/mballoc.c
+++ b/fs/ext4/mballoc.c
@@ -2589,7 +2589,7 @@ static void release_blocks_on_commit(journal_t *journal, transaction_t *txn)
(unsigned long long)discard_block,
entry->count);
ret = sb_issue_discard(sb, discard_block, entry->count);
- if (ret == EOPNOTSUPP) {
+ if (ret == -EOPNOTSUPP) {
ext4_warning(sb,
"discard not supported, disabling");
clear_opt(EXT4_SB(sb)->s_mount_opt, DISCARD);
--
1.7.2
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists