[PATCH 0/3 v3] Batched discard support for Ext3/Ext4

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,

since my last post I have changed those patches slightly. Ext3 patch does
not introduce DISCARD/NODISCARD mount option, so there is just FITRIM
ioctl which can be invoked only by user with CAP_SYS_ADMIN.

Ext3 patch also involves journaling because as Jan pointed out not using
journal can cause problems when system crashes. Jan please look at this
I hope it is ok now. Also I am not sure if it would not be better to close
the journal after allocating free space and then start new one after
the TRIM (this was proposed by Josef Bacik).

Ext4 patch does not remove old "online" discard implementation and does not
check for DISCARD mount option. To avoid journaling I have used alloc_sem
semaphore to prevent allocations from the group while it is being trimmed.
It seems sufficient to me.

The general idea of batched discards stays the same. So when FITRIM ioctl
is invoked upon the mount point, it walks through all allocation groups
searching for free extents bigger than minlen, then trim those extents. In
ext3 consistency is assured by allocating these free extents in alloc. group
(with journal involved). In ext4 consistency is assured by use of alloc_sem
semaphore.

-Lukas

[PATCH 1/3] Add ioctl FITRIM.
[PATCH 2/3] Add batched discard support for ext3
[PATCH 3/3] Add batched discard support for ext4
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux