Linux EXT4 FS development
 help / color / mirror / Atom feed
* [PATCH 1/2] ext4: no need to cond_resched() in ext4_trim_all_free()
@ 2017-04-27  8:36 Lukas Czerner
  2017-04-30  4:26 ` Theodore Ts'o
  0 siblings, 1 reply; 3+ messages in thread
From: Lukas Czerner @ 2017-04-27  8:36 UTC (permalink / raw)
  To: linux-ext4; +Cc: Lukas Czerner

There is no need to call cond_resched() in ext4_trim_all_free() since
blkdev_issue_discard() already takes care of that. So just remove it.

Signed-off-by: Lukas Czerner <lczerner@redhat.com>
---
 fs/ext4/mballoc.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c
index 354dc1a..4879766 100644
--- a/fs/ext4/mballoc.c
+++ b/fs/ext4/mballoc.c
@@ -5163,12 +5163,6 @@ ext4_trim_all_free(struct super_block *sb, ext4_group_t group,
 			break;
 		}
 
-		if (need_resched()) {
-			ext4_unlock_group(sb, group);
-			cond_resched();
-			ext4_lock_group(sb, group);
-		}

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-05-04 11:19 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-04-27  8:36 [PATCH 1/2] ext4: no need to cond_resched() in ext4_trim_all_free() Lukas Czerner
2017-04-30  4:26 ` Theodore Ts'o
2017-05-04 11:19   ` Lukas Czerner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox