Hi,
在 2025/05/26 14:40, Christoph Hellwig 写道:
On Sat, May 24, 2025 at 02:13:09PM +0800, Yu Kuai wrote:
From: Yu Kuai <yukuai3@xxxxxxxxxx>
Also move other values to md-bitmap.h and update comments.
Hmm. The commit message looks very confusing to me.
I think this should be two patches:
1) move defines relevant to the disk format from md-bitmap.c to md-bitmap.h
2) add new bits for llbitmap (and explain what they are).
OK.
+#define BITMAP_SB_SIZE 1024
And while we're at it: this is still duplicated in llbitmap.c later.
But shouldn't it simply be replaced with a sizeof on struct bitmap_super_s?
Sorry that I forgot to explain why it's still in .c
sizeof(struct bitmap_super_s) is actually 256 bytes, while by default,
1k is reserved, perhaps I can name it as BITMAP_DATA_OFFSET ?
0-255B bitmap_super_s
256-1023B hole
1024-[space] bitmap
[space] - 128k hole
BTW, the new bitmap only support the default offset and space, user
can't configure it manually.
Thanks,
Kuai
(and when cleaning thing up, rename that to bitmap_super without
the _s and use it instead of the typedef at least for all new code)?
.