[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <40af768d-373c-4a56-8af5-82aeabe49515@huaweicloud.com>
Date: Mon, 26 May 2025 16:12:06 +0800
From: Yu Kuai <yukuai1@...weicloud.com>
To: Christoph Hellwig <hch@....de>, Yu Kuai <yukuai1@...weicloud.com>
Cc: xni@...hat.com, colyli@...nel.org, song@...nel.org,
linux-doc@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-raid@...r.kernel.org, yi.zhang@...wei.com, yangerkun@...wei.com,
johnny.chenyi@...wei.com, "yukuai (C)" <yukuai3@...wei.com>
Subject: Re: [PATCH 12/23] md/md-bitmap: add macros for lockless bitmap
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@...wei.com>
>>
>> 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)?
> .
>
Powered by blists - more mailing lists