public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Set the initial TRIM information as TRIMMED
@ 2011-12-01  7:00 Kyungmin Park
  2011-12-01  7:39 ` Tao Ma
                   ` (2 more replies)
  0 siblings, 3 replies; 16+ messages in thread
From: Kyungmin Park @ 2011-12-01  7:00 UTC (permalink / raw)
  To: tytso, tm; +Cc: linux-ext4, linux-kernel

From: Kyungmin Park <kyungmin.park@samsung.com>

Now trim information doesn't stored at disk so every boot time. it's cleared.
and do the trim all disk groups.
But assume that it's already trimmed at previous time so don't need to trim it again. So set the intial state as trimmed.

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
---
diff --git a/fs/ext4/mballoc.c b/fs/ext4/mballoc.c
index e2d8be8..97ef342 100644
--- a/fs/ext4/mballoc.c
+++ b/fs/ext4/mballoc.c
@@ -1098,6 +1098,12 @@ int ext4_mb_init_group(struct super_block *sb, ext4_group_t group)
 		goto err;
 	}
 	mark_page_accessed(page);
+
+	/*
+	 * TRIM information is not stored at disk so set the initial
+	 * state as trimmed. Since previous time it's already trimmed all
+	 */
+	EXT4_MB_GRP_SET_TRIMMED(this_grp);
 err:
 	ext4_mb_put_buddy_page_lock(&e4b);
 	return ret;

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

end of thread, other threads:[~2011-12-05 11:09 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-01  7:00 [PATCH] Set the initial TRIM information as TRIMMED Kyungmin Park
2011-12-01  7:39 ` Tao Ma
2011-12-01  8:19   ` Kyungmin Park
2011-12-01  8:30     ` Tao Ma
2011-12-01  8:39       ` Kyungmin Park
2011-12-01 22:06 ` Eric Sandeen
2011-12-02  0:01   ` Kyungmin Park
2011-12-02  0:50     ` Greg Freemyer
2011-12-05 10:25       ` Lukas Czerner
2011-12-02 15:30     ` Eric Sandeen
2011-12-02 15:45     ` Eric Sandeen
2011-12-02 15:57     ` Eric Sandeen
2011-12-05  9:55       ` Kyungmin Park
2011-12-05 10:17 ` Lukas Czerner
2011-12-05 10:35   ` Kyungmin Park
2011-12-05 11:09     ` Lukas Czerner

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