Thread (2 messages) 2 messages, 2 authors, 2017-11-01

Re: [PATCH] bcache: correct journal bucket reading

From: Michael Lyle <hidden>
Date: 2017-11-01 22:54:47
Also in: linux-bcache

Tang--

I think the scenario you listed can't happen, because the first bucket
we try in the hash-search is 0.  If the circular buffer has wrapped,
that will be detected immediately and we'll leave the loop with l=0.
We should add a comment that we need to try the first index first for
correctness so that we don't inadvertently change this behavior.

One thing took me a long time to convince myself was safe with the
original code:  If we have 'YYNYYYYYYY', we'll start at l=0, and then
we'll search across the N;  I think this is OK because sequence
numbers will cause us to do the right thing.

Mike

On Wed, Nov 1, 2017 at 12:10 AM,  [off-list ref] wrote:
From: Tang Junhui <redacted>

Hello Mike, Coly

I found this issue by code reading.
It looks serious.
May I am wrong.
Please have a review.

Thanks,
Tang
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help