> 2023年12月24日 09:38,Jens Axboe 写道:
>
> On 12/23/23 5:32 PM, Coly Li wrote:
>>> 2023?12?24? 08:28?Coly Li ???
>>>
>>> If prev_badblocks() returns '-1', it means no valid badblocks record
>>> before the checking range. It doesn't
> 2023年12月24日 08:28,Coly Li 写道:
>
> If prev_badblocks() returns '-1', it means no valid badblocks record
> before the checking range. It doesn't make sense to check whether
> the input checking range is overlapped with the non-existed invalid
> front range
calling
overlap_front(), to void such invalid operations.
Fixes: 3ea3354cb9f0 ("badblocks: improve badblocks_check() for multiple ranges
handling")
Reported-and-tested-by: Ira Weiny
Signed-off-by: Coly Li
Link:
https://lore.kernel.org/nvdimm/3035e75a-9be0-4bc3-8d4a-6e52c207f.
> 2023年12月24日 01:13,Ira Weiny 写道:
>
> Coly Li wrote:
>
> [snip]
>
>>
>> Hi Ira,
>>
>> The above information is accurate and very helpful, thank you!
>>
>> From __badblocks_check(), the problematic code block is,
>> 1303 re_c
blocks_set() and badblocks_clear(), 'prev < 0' is explicitly checked,
value '-1' doesn't go though into following code.
Could you please apply and try the attached patch? Hope it may help a bit.
And now it is weekend time, you may be out of office and not able to a
notice that this work was due to a bug report in badblock_set().
> Therefore, I'm not sure of that severity of that fix is vs a revert. But
> at this point I'm not seeing an easy fix so I'm in favor of a revert.
Hi Ira,
Thanks for the information reported. Let me look into the situation now.
Coly Li
l 512 badblock slots from being full filled.
Of course the testing code is not perfect, this is the try-best effort
to verify simple conditions of bad blocks setting/clearing with random
generated ranges. For complicated situations, manual check by people are
still necessary.
Signed-off-by: Coly Li
Cc
() and _badblocks_check().
This patch only contains the changes of old code deletion, new added
code for the improved algorithms are in previous patches.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
Cc: Xiao Ni
ocks_set(), and just add a new
one named _badblocks_set(). Later patch will remove current existing
badblocks_set() code and make it as a wrapper of _badblocks_set(). So
the new added change won't be mixed with deleted code, the code review
can be easier.
Signed-off-by: Coly Li
Cc: Dan Willi
_badblock_clear() for the improvement.
Later patch will delete current code of badblock_clear() and make it as
a wrapper to _badblock_clear(), so the code change can be much clear for
review.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
eview.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
Cc: Xiao Ni
---
block/badblocks.c | 97 +++
1 file changed, 97 insertions(+)
diff --git a/block/badblocks.c b/
ks_set()/badblocks_clear()/badblocks_check().
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
Cc: Xiao Ni
---
block/badblocks.c | 386 ++
1 file changed, 386 insertions(
sed in the improved badblocks code in following
patches.
Signed-off-by: Coly Li
Reviewed-by: Xiao Ni
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
include/linux/badblocks.h | 30 ++
1 file changed, 30
r the code review accomplished.
Please review the code and response. Thank you all in advance.
Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Richard Fan
Cc: Vishal L Verma
Cc: Wols Lists
Cc: Xiao Ni
---
Coly Li (6):
badblocks: add m
On Wed, Sep 21, 2022 at 11:26:52PM +0800, Xiao Ni wrote:
> On Thu, Jul 21, 2022 at 8:12 PM Coly Li wrote:
>>
[snipped]
>> + * setting does, but much more simpler. The only thing needs to be noticed
>> is
>> + * when the clearing range hits middle of a bad block
On Wed, Sep 21, 2022 at 11:26:52PM +0800, Xiao Ni wrote:
> On Thu, Jul 21, 2022 at 8:12 PM Coly Li wrote:
>>
[snipped]
>> + * setting does, but much more simpler. The only thing needs to be noticed
>> is
>> + * when the clearing range hits middle of a bad block
> 2022年9月21日 20:13,Xiao Ni 写道:
>
> On Thu, Jul 21, 2022 at 8:12 PM Coly Li wrote:
[snipped]
>>
>> + *+--+
>> + * 4.2.2) If range E is acked and the setting range S is unacked, the
>> setting
>> + *request of
AKE(BB_OFFSET(p[prev]),
>> + bad->start - BB_OFFSET(p[prev]),
>> + BB_ACK(p[prev]));
>
> s/BB_ACK(p[prev])/orig_ack/g
It will be used in next version.
>
>> + /*
>> +* prev + 3 -> prev + 1 + 2, which is for,
>> +* 1) prev + 1: the slot index of the previous one
>> +* 2) + 2: two more slots for extra being 2.
>> +*/
>> + memmove(p + prev + 3, p + prev + 1,
>> + (bb->count - prev - 1) * 8);
>> + p[prev + 1] = BB_MAKE(bad->start, bad->len, bad->ack);
>> + p[prev + 2] = BB_MAKE(BB_END(p[prev + 1]),
>> + orig_end - BB_END(p[prev + 1]),
>> + BB_ACK(p[prev]));
>
> s/BB_ACK(p[prev])/orig_ack/g
It will be used in next version.
>> + break;
>> + default:
>> + break;
>> + }
>> +
>> + return bad->len;
>> +}
>> +
>> +/*
Thank you for the review!
Coly Li
> 2023年5月23日 10:38,Li Nan 写道:
>
> Hi Coly Li,
>
> Recently, I have been trying to fix the bug of backblocks settings, and I
> found that your patch series has already fixed the bug. This patch series has
> not been applied to mainline at present, may I ask if you stil
l 512 badblock slots from being full filled.
Of course the testing code is not perfect, this is the try-best effort
to verify simple conditions of bad blocks setting/clearing with random
generated ranges. For complicated situations, manual check by people are
still necessary.
Signed-off-by: Coly Li
Cc
() and _badblocks_check().
This patch only contains the changes of old code deletion, new added
code for the improved algorithms are in previous patches.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
Cc: Xiao Ni
eview.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
Cc: Xiao Ni
---
block/badblocks.c | 97 +++
1 file changed, 97 insertions(+)
diff --git a/block/badblocks.c b/
_badblock_clear() for the improvement.
Later patch will delete current code of badblock_clear() and make it as
a wrapper to _badblock_clear(), so the code change can be much clear for
review.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
ocks_set(), and just add a new
one named _badblocks_set(). Later patch will remove current existing
badblocks_set() code and make it as a wrapper of _badblocks_set(). So
the new added change won't be mixed with deleted code, the code review
can be easier.
Signed-off-by: Coly Li
Cc: Dan Willi
ks_set()/badblocks_clear()/badblocks_check().
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
Cc: Xiao Ni
---
block/badblocks.c | 377 ++
1 file changed, 377 insertions(
sed in the improved badblocks code in following
patches.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
Cc: Xiao Ni
---
include/linux/badblocks.h | 30 ++
1 file changed, 30 insertions(+)
The whole change is divided into 6 patches to make the code review more
clear and easier. If people prefer, I'd like to post a single large
patch finally after the code review accomplished.
Please review the code and response. Thank you all in advance.
Coly Li
Cc: Dan Williams
Cc: Geli
> 2022年1月2日 21:48,Xiao Ni 写道:
>
> On Sat, Dec 11, 2021 at 12:05 AM Coly Li wrote:
>>
>> Recently I received a bug report that current badblocks code does not
>> properly handle multiple ranges. For example,
>>badblocks_set(bb, 32, 1, true);
>&g
> 2022年1月2日 15:04,Xiao Ni 写道:
>
> On Sat, Dec 11, 2021 at 12:05 AM Coly Li wrote:
>>
>>
[snipped]
>> block/badblocks.c | 376 ++
>> 1 file changed, 376 insertions(+)
>>
>> diff --git a/block/badblock
On 3/3/22 7:19 PM, Christoph Hellwig wrote:
Using local kmaps slightly reduces the chances to stray writes, and
the bvec interface cleans up the code a little bit.
Signed-off-by: Christoph Hellwig
Acked-by: Coly Li
Thanks.
Coly Li
---
drivers/md/bcache/request.c | 4 ++--
1 file
l 512 badblock slots from being full filled.
Of course the testing code is not perfect, this is the try-best effort
to verify simple conditions of bad blocks setting/clearing with random
generated ranges. For complicated situations, manual check by people are
still necessary.
Signed-off-by: Coly Li
Cc
() and _badblocks_check().
This patch only contains the changes of old code deletion, new added
code for the improved algorithms are in previous patches.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
block
eview.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
block/badblocks.c | 97 +++
1 file changed, 97 insertions(+)
diff --git a/block/badblocks.c b/block/badblocks.c
_badblock_clear() for the improvement.
Later patch will delete current code of badblock_clear() and make it as
a wrapper to _badblock_clear(), so the code change can be much clear for
review.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
badblocks_set(), and just add a new
one named _badblocks_set(). Later patch will remove current existing
badblocks_set() code and make it as a wrapper of _badblocks_set(). So
the new added change won't be mixed with deleted code, the code review
can be easier.
Signed-off-by: Coly Li
Cc: Dan W
ks_set()/badblocks_clear()/badblocks_check().
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
block/badblocks.c | 376 ++
1 file changed, 376 insertions(+)
diff --gi
sed in the improved badblocks code in following
patches.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
include/linux/badblocks.h | 30 ++
1 file changed, 30 insertions(+)
diff --git
d.
Please review the code and response. Thank you all in advance.
Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Richard Fan
Cc: Vishal L Verma
Cc: Wols Lists
---
Coly Li (6):
badblocks: add more helper structure and routines in b
On 12/9/21 3:22 PM, Geliang Tang wrote:
Hi Coly,
Thanks for this new version!
Thank you so much for the review comments. I fix all the typos and
change the code as you suggested with dropping extra local variables.
The modification will be posted in next version.
Coly Li
[snip]
On 12/10/21 2:37 AM, Wols Lists wrote:
On 09/12/2021 07:28, Geliang Tang wrote:
On Thu, Dec 02, 2021 at 08:52:41PM +0800, Coly Li wrote:
Recently I received a bug report that current badblocks code does not
+ * +++
+ * | S | E
l 512 badblock slots from being full filled.
Of course the testing code is not perfect, this is the try-best effort
to verify simple conditions of bad blocks setting/clearing with random
generated ranges. For complicated situations, manual check by people are
still necessary.
Signed-off-by: Coly Li
Cc
() and _badblocks_check().
This patch only contains the changes of old code deletion, new added
code for the improved algorithms are in previous patches.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
block
eview.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
block/badblocks.c | 97 +++
1 file changed, 97 insertions(+)
diff --git a/block/badblocks.c b/block/badblocks.c
_badblock_clear() for the improvement.
Later patch will delete current code of badblock_clear() and make it as
a wrapper to _badblock_clear(), so the code change can be much clear for
review.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
badblocks_set(), and just add a new
one named _badblocks_set(). Later patch will remove current existing
badblocks_set() code and make it as a wrapper of _badblocks_set(). So
the new added change won't be mixed with deleted code, the code review
can be easier.
Signed-off-by: Coly Li
Cc: Dan W
ks_set()/badblocks_clear()/badblocks_check().
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
block/badblocks.c | 374 ++
1 file changed, 374 insertions(+)
diff --gi
sed in the improved badblocks code in following
patches.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
include/linux/badblocks.h | 30 ++
1 file changed, 30 insertions(+)
diff --git
ngle large
patch finally after the code review accomplished.
Please review the code and response. Thank you all in advance.
Coly Li
Cc: Dan Williams
Cc: Geliang Tang
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Richard Fan
Cc: Vishal L Verma
---
Coly Li (6):
badblocks: add m
On 9/27/21 3:23 PM, Geliang Tang wrote:
Hi Coly,
On 9/14/21 00:36, Coly Li wrote:
This patch adds the following helper structure and routines into
badblocks.h,
- struct badblocks_context
This structure is used in improved badblocks code for bad table
iteration.
- BB_END()
The macro to
On 9/27/21 3:25 PM, Geliang Tang wrote:
On 9/14/21 00:36, Coly Li wrote:
This patch adds several helper routines to improve badblock ranges
handling. These helper routines will be used later in the improved
version of badblocks_set()/badblocks_clear()/badblocks_check().
- Helpers prev_by_hint
On 9/27/21 3:30 PM, Geliang Tang wrote:
On 9/14/21 00:36, Coly Li wrote:
[snipped]
+ * 2.1.1) If S and E are both acked or unacked range, the setting
range S can
+ * be merged into existing bad range E. The result is,
+ * +-+
+ * | S
On 9/23/21 6:09 PM, NeilBrown wrote:
On Thu, 23 Sep 2021, Coly Li wrote:
Hi all the kernel gurus, and folks in mailing lists,
This is a question about exporting 4KB+ text information via sysfs
interface. I need advice on how to handle the problem.
Hi Neil,
Why do you think there is a
On 9/23/21 2:47 PM, Greg Kroah-Hartman wrote:
On Thu, Sep 23, 2021 at 02:14:12PM +0800, Coly Li wrote:
On 9/23/21 2:08 PM, Greg Kroah-Hartman wrote:
On Thu, Sep 23, 2021 at 01:59:28PM +0800, Coly Li wrote:
Hi all the kernel gurus, and folks in mailing lists,
This is a question about
On 9/23/21 2:08 PM, Greg Kroah-Hartman wrote:
On Thu, Sep 23, 2021 at 01:59:28PM +0800, Coly Li wrote:
Hi all the kernel gurus, and folks in mailing lists,
This is a question about exporting 4KB+ text information via sysfs
interface. I need advice on how to handle the problem.
Hi Greg,
This
xceed
the page size limitation of sysfs file.
2) Add seq_file support to sysfs interface if there is no
It is probably there is other better solution to fix. So I do want to
get hint/advice from you.
Thanks in advance for any comment :-)
Coly Li
On 9/14/21 12:36 AM, Coly Li wrote:
This is
this version.
The whole change is divided into 6 patches to make the code review more
clear and easier. If people prefer, I'd like to post a single large
patch finally after the code review accomplished.
This version is seriously tested, and so far no more defect observed.
Coly Li
Cc: Da
l 512 badblock slots from being full filled.
Of course the testing code is not perfect, this is the try-best effort
to verify simple conditions of bad blocks setting/clearing with random
generated ranges. For complicated situations, manual check by people are
still necessary.
Signed-off-by: Coly Li
Cc
() and _badblocks_check().
This patch only contains the changes of old code deletion, new added
code for the improved algorithms are in previous patches.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Richard Fan
Cc: Vishal L Verma
---
block
eview.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Richard Fan
Cc: Vishal L Verma
---
block/badblocks.c | 99 +++
1 file changed, 99 insertions(+)
diff --git a/block/badblocks.c b/block/badblocks.c
_badblock_clear() for the improvement.
Later patch will delete current code of badblock_clear() and make it as
a wrapper to _badblock_clear(), so the code change can be much clear for
review.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Richard Fan
badblocks_set(), and just add a new
one named _badblocks_set(). Later patch will remove current existing
badblocks_set() code and make it as a wrapper of _badblocks_set(). So
the new added change won't be mixed with deleted code, the code review
can be easier.
Signed-off-by: Coly Li
Cc: Dan Will
ks_set()/badblocks_clear()/badblocks_check().
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Richard Fan
Cc: Vishal L Verma
---
block/badblocks.c | 374 ++
1 file changed, 374 insertions(+)
diff --gi
sed in the improved badblocks code in following
patches.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Richard Fan
Cc: Vishal L Verma
---
include/linux/badblocks.h | 32
1 file changed, 32 insertions(+)
diff --git
this version.
The whole change is divided into 6 patches to make the code review more
clear and easier. If people prefer, I'd like to post a single large
patch finally after the code review accomplished.
This version is seriously tested, and so far no more defect observed.
Coly Li
Cc: Da
l 512 badblock slots from being full filled.
Of course the testing code is not perfect, this is the try-best effort
to verify simple conditions of bad blocks setting/clearing with random
generated ranges. For complicated situations, manual check by people are
still necessary.
Signed-off-by: Coly Li
Cc
() and _badblocks_check().
This patch only contains the changes of old code deletion, new added
code for the improved algorithms are in previous patches.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
block/badblocks.c | 310
eview.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
block/badblocks.c | 99 +++
1 file changed, 99 insertions(+)
diff --git a/block/badblocks.c b/block/badblocks.c
index b8d466e
_badblock_clear() for the improvement.
Later patch will delete current code of badblock_clear() and make it as
a wrapper to _badblock_clear(), so the code change can be much clear for
review.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L
badblocks_set(), and just add a new
one named _badblocks_set(). Later patch will remove current existing
badblocks_set() code and make it as a wrapper of _badblocks_set(). So
the new added change won't be mixed with deleted code, the code review
can be easier.
Signed-off-by: Coly Li
Cc:
ks_set()/badblocks_clear()/badblocks_check().
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
block/badblocks.c | 374 ++
1 file changed, 374 insertions(+)
diff --git a/block/badblocks.c
sed in the improved badblocks code in following
patches.
Signed-off-by: Coly Li
Cc: Dan Williams
Cc: Hannes Reinecke
Cc: Jens Axboe
Cc: NeilBrown
Cc: Vishal L Verma
---
include/linux/badblocks.h | 32
1 file changed, 32 insertions(+)
diff --git a/include/linux/b
that
tradition.
Signed-off-by: Luis Chamberlain
Acked-by: Coly Li
Thanks.
---
drivers/md/bcache/super.c | 17 -
1 file changed, 12 insertions(+), 5 deletions(-)
diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c
index f2874c77ff79..f0c32cdd6594 100644
--- a/dr
On 2019/10/16 12:04 上午, Christoph Hellwig wrote:
> Hi Coly,
>
> this series removes a pointless cflags override and unused exports
> from bcache.
>
Sure, I add them in my for-next series. Thansk.
--
Coly Li
On 2019/8/24 1:17 上午, Song Liu wrote:
>
>
>> On Aug 23, 2019, at 10:03 AM, Coly Li wrote:
>>
>> On 2019/8/24 12:37 上午, Song Liu wrote:
>>> Thanks Coly and Neil.
>>>
>>>> On Aug 22, 2019, at 5:02 PM, NeilBrown wrote:
>>>
On 2019/8/24 12:37 上午, Song Liu wrote:
> Thanks Coly and Neil.
>
>> On Aug 22, 2019, at 5:02 PM, NeilBrown wrote:
>>
>> On Thu, Aug 22 2019, Coly Li wrote:
>>
>>> Hi folks,
>>>
>>> First line: This bug only influences md raid0 dev
veloper community to work together for a solution, this
is the motivation I post this email for your comments.
Thanks in advance.
--
Coly Li
IBLE. Then process A
> goes to sleep but no one will wake up it. This problem may cause bcache
> device to dead.
>
> Signed-off-by: Guoju Fang
Hi Guoju,
It looks good to me at the first glance, let me add it into my for-test
directory.
Thanks.
Coly Li
> ---
> drivers/md/bca
atch_string() instead of __sysfs_match_string()").
This bug was introduced in Linux v5.2, so this fix only applies to
Linux v5.2 is enough for stable tree maintainer.
Fixes: 89e0341af082 ("bcache: use sysfs_match_string() instead of
__sysfs_match_string()")
Signed-off-by: Coly Li
Hi Jens,
I have a bug report that is frequent happens in product environment,
the problem was introduced in Linux v5.2, we should have the fix in
in Linux v5.3.
I add the missing 'Fixes:' field for the patch in v2.
Thanks in advance for taking this.
Coly Li
---
Coly Li (1):
bcac
atch_string() instead of __sysfs_match_string()").
This bug was introduced in Linux v5.2, so this fix only applies to
Linux v5.2 is enough for stable tree maintainer.
Signed-off-by: Coly Li
Reported-by: Peifeng Lin
Cc: sta...@vger.kernel.org
Cc: Alexandru Ardelean
---
drivers/md/bca
Hi Jens,
I have a bug report that is frequent happens in product environment,
the problem was introduced in Linux v5.2, we should have the fix in
in Linux v5.3.
Thanks in advance for taking this.
Coly Li
---
Coly Li (1):
bcache: Revert "bcache: use sysfs_match_string() inste
From: Wei Yongjun
memory malloced in bch_cached_dev_run() and should be freed before
leaving from the error handling cases, otherwise it will cause
memory leak.
Fixes: 0b13efecf5f2 ("bcache: add return value check to bch_cached_dev_run()")
Signed-off-by: Wei Yongjun
Signed-off-b
Hi Jens,
Up to now we have one fix from Wei Yongjun for the patches merged in
Linux v5.3-rc1, which is for a possible memory leak when running a
cached device.
Thank you in advance, for taking it in v5.3-rc2.
Coly Li
---
Wei Yongjun (1):
bcache: fix possible memory leak in bch_cached_dev_run
he above change decreases 50%+ CPU consumption when
journal space is full. Some times IOPS drops to 0 for 5-8 seconds,
comparing blocking I/O for 120+ seconds in previous code, this is much
better. Maybe there is room to improve in future, but at this momment
the fix looks fine and performs well in m
>flush_btree in
bch_journal_free")
Signed-off-by: Coly Li
Cc: sta...@vger.kernel.org
Cc: Shenghui Wang
---
drivers/md/bcache/journal.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/md/bcache/journal.c b/drivers/md/bcache/journal.c
index 3d321bffddc9..11d8c93b88bb 100644
--- a/drivers/md
In struct cache_set, retry_flush_write is added for commit c4dc2497d50d
("bcache: fix high CPU occupancy during journal") which is reverted in
previous patch.
Now it is useless anymore, and this patch removes it from bcache code.
Signed-off-by: Coly Li
---
drivers/md/bcache/bca
many journal buckets are
reclaimed since cache set runs. From all these three counters (reclaim,
reclaimed_journal_buckets, flush_write), we can have idea how well
current journal space reclaim code works.
Signed-off-by: Coly Li
---
drivers/md/bcache/bcache.h | 1 +
drivers/md/bcache/journal.
_NODE_journal_flush bit cleared,
and free the btree node memory.
Fixes: cafe56359144 ("bcache: A block layer cache")
Signed-off-by: Coly Li
Reported-and-tested-by: kbuild test robot
Cc: sta...@vger.kernel.org
---
drivers/md/bcache/btree.c | 28 +++-
dri
p;bch_register_lock) to a later location where
before atomic_read(&dc->running) in cached_dev_free(), such A-A lock
problem can be solved without any reboot time registration race.
Signed-off-by: Coly Li
---
drivers/md/bcache/super.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions
This patch adds more code comments in journal_read_bucket(), this is an
effort to make the code to be more understandable.
Signed-off-by: Coly Li
---
drivers/md/bcache/journal.c | 24
1 file changed, 24 insertions(+)
diff --git a/drivers/md/bcache/journal.c b/drivers
(). Which
is later then original location in cached_dev_detach_finish().
Signed-off-by: Coly Li
---
drivers/md/bcache/super.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c
index a88238ad5da1..40d857e690f9 100644
--- a
Indeed if btree_node_dirty(b) returns false, it means BTREE_NODE_dirty
bit is cleared, then it is unnecessary to clear the bit again.
This patch only clears BTREE_NODE_dirty when btree_node_dirty(b) is
true (the bit is set), to save a few CPU cycles.
Signed-off-by: Coly Li
---
drivers/md/bcache/
g or clearing BTREE_NODE_dirty bit there.
Signed-off-by: Coly Li
---
drivers/md/bcache/btree.c | 10 ++
1 file changed, 10 insertions(+)
diff --git a/drivers/md/bcache/btree.c b/drivers/md/bcache/btree.c
index 88e5aa3fbb07..846306c3a887 100644
--- a/drivers/md/bcache/btree.c
+++ b/drivers/md/b
k_write_wq in writebach kthread routine
bch_writeback_thread(), where after quit the thread main while-loop
and before cached_dev_put() is called.
By this fix, dc->writeback_write_wq will be stopped and destroy before
the writeback kthread stopped, so the chance for a A-A locking on
wq->
: c4dc2497d50d ("bcache: fix high CPU occupancy during journal")
Signed-off-by: Coly Li
Cc: sta...@vger.kernel.org
Cc: Tang Junhui
---
drivers/md/bcache/bcache.h | 2 --
drivers/md/bcache/journal.c | 47 +++--
drivers/md/bcache/util.h| 2 -
base, or I/O service of distributed storage node).
This patch tries to call bcache mca shrinker routine to proactively
release mca cache memory, to decrease the memory pressure of system and
avoid negative effort of the overall system I/O performance.
Signed-off-by: Coly Li
---
drivers/md/bcache
gger
then current value.
Signed-off-by: Coly Li
---
drivers/md/bcache/journal.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/md/bcache/journal.c b/drivers/md/bcache/journal.c
index 98ee467ec3f7..3d321bffddc9 100644
--- a/drivers/md/bcache/journal.c
+++ b/drivers/
In register_bcache(), if bcache_is_reboot is checked
to be true, reject the registration by returning -EBUSY immediately.
Signed-off-by: Coly Li
---
drivers/md/bcache/super.c | 40 +++-
drivers/md/bcache/sysfs.c | 26 ++
2 files cha
to attach to the cache devince and run, so it won't be an
error level message in kernel message.
Signed-off-by: Coly Li
---
drivers/md/bcache/super.c | 9 +++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c
ind
This patch adds more error message for attaching cached device, this is
helpful to debug code failure during bache device start up.
Signed-off-by: Coly Li
---
drivers/md/bcache/super.c | 4
1 file changed, 4 insertions(+)
diff --git a/drivers/md/bcache/super.c b/drivers/md/bcache/super.c
1 - 100 of 854 matches
Mail list logo