[dm-devel] [PATCH] bcache: never writeback a discard operation

Coly Li colyli at suse.de
Wed Jan 23 01:39:15 UTC 2019


在 2019/1/23 上午8:10, Daniel Axtens 写道:
> Hi Sasha,
> 
>> This commit has been processed because it contains a "Fixes:" tag,
>> fixing commit: 72c270612bd3 bcache: Write out full stripes.
> 
> I added that fixes tag because that was the commit that added the
> code. However, I noticed that one of the bug reports mentions that the
> problem only arising after v4.8. [1] I don't quite know what to make of
> this: perhaps it is a consequence of another change enabling the broken
> path. Maybe someone on one of the lists will have an idea.
> 

>From code logic, bcache should not have a discard bio in cache device,
otherwise it is a bug. Therefore no matter whether the issue happens
before v4.8 kernel, I'd like to have the fix in.

>> v4.4.171: Build failed! Errors:
>>     drivers/md/bcache/writeback.h:71:6: error: implicit declaration of function ‘bio_op’; did you mean ‘bio_rw’? [-Werror=implicit-function-declaration]
>>     drivers/md/bcache/writeback.h:71:21: error: ‘REQ_OP_DISCARD’ undeclared (first use in this function); did you mean ‘REQ_DISCARD’?
>>
>> v3.18.132: Build failed! Errors:
>>     drivers/md/bcache/writeback.h:71:6: error: implicit declaration of function ‘bio_op’; did you mean ‘bio_rw’? [-Werror=implicit-function-declaration]
>>     drivers/md/bcache/writeback.h:71:21: error: ‘REQ_OP_DISCARD’ undeclared (first use in this function); did you mean ‘REQ_DISCARD’?
>>
>>
>> How should we proceed with this patch?
> 
> The patch seems reasonably easy to backport. Compile-tested only, and
> only against v4.4.171.

I don't have idea whether stable kernels accept rebased patches, for
SUSE kernel I will do back port for all necessary kernel versions.

-- 

Coly Li




More information about the dm-devel mailing list