[dm-devel] [PATCHES] convert dm-thin to use dm-bufio
Mikulas Patocka
mpatocka at redhat.com
Sun Aug 14 20:18:29 UTC 2011
Hi
I created patches that convert dm-thin to use dm-bufio interface (so that
it is consistent with dm-zeroed and dm-multisnap).
The patches are here:
http://people.redhat.com/mpatocka/patches/kernel/dm-thinp-bufio/
Advantages:
* It uses kmalloc, __get_free_pages or __vmalloc, so the block size is not
limited and memory fragmentation is not an issue. The original code only
used kmalloc.
* It has dynamic cache sizing, cache size can be configured by the user.
In case of inactivity over some time (a buffer is unused for a minute),
the buffers are freed. The original code had cache size hardcoded and it
couldn't be changed.
* Submit bios directly (if we can) without dm-io layer.
Notes:
* Buffer locking is not supported, I suppose it is not used for anything
anyway. If it is used, tell me, I can add it after reviewing it.
* dm_bm_rebind_block_device changes the block device, but it is not used
for anything (dm-thinp never changes the device). I think it could be
removed.
* Two small bugs in dm-thin are fixed --- not closing the superblock
buffer on exit and improper termination sequence (the block devices were
closed before the buffer interface exited).
Mikulas
More information about the dm-devel
mailing list