From: Sunwook Eom <speed.eom@samsung.com>
To: Sami Tolvanen <samitolvanen@google.com>
Cc: "Alasdair Kergon" <agk@redhat.com>,
"Mike Snitzer" <snitzer@redhat.com>,
"device-mapper development" <dm-devel@redhat.com>,
강문철 <mcneo.kang@samsung.com>,
sunwook5492@gmail.com, LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] dm verity fec: fix hash block number in verity_fec_decode
Date: Mon, 13 Apr 2020 13:31:27 +0900 [thread overview]
Message-ID: <8a6d104e-4a2b-c393-567f-95bc06f6763a@samsung.com> (raw)
In-Reply-To: <CABCJKueSJ4sXHL5xnB5LQVW_6od2+_TEp0y_vv1gdi=yBB1Zfg@mail.gmail.com>
On 20. 4. 11. 오전 12:41, Sami Tolvanen wrote:
> On Thu, Apr 9, 2020 at 8:54 PM Sunwook Eom <speed.eom@samsung.com> wrote:
>> The error correction data is computed as if data and hash blocks
>> were concatenated. But hash block number is start from v->hash_start.
>> So, we have to calculate hash block number based on that.
>>
>> Fixes: a739ff3f543af ("dm verity: add support for forward error correction")
>> Signed-off-by: Sunwook Eom <speed.eom@samsung.com>
>> ---
>> drivers/md/dm-verity-fec.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/md/dm-verity-fec.c b/drivers/md/dm-verity-fec.c
>> index 49147e634046..fb41b4f23c48 100644
>> --- a/drivers/md/dm-verity-fec.c
>> +++ b/drivers/md/dm-verity-fec.c
>> @@ -435,7 +435,7 @@ int verity_fec_decode(struct dm_verity *v, struct
>> dm_verity_io *io,
>> fio->level++;
>>
>> if (type == DM_VERITY_BLOCK_TYPE_METADATA)
>> - block += v->data_blocks;
>> + block = block - v->hash_start + v->data_blocks;
>>
>> /*
>> * For RS(M, N), the continuous FEC data is divided into blocks of N
> Thank you for the patch!
>
> Reviewed-by: Sami Tolvanen <samitolvanen@google.com>
>
> Sami
>
>
Add CC : LKML <linux-kernel@vger.kernel.org>
parent reply other threads:[~2020-04-13 4:31 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <CABCJKueSJ4sXHL5xnB5LQVW_6od2+_TEp0y_vv1gdi=yBB1Zfg@mail.gmail.com>]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=8a6d104e-4a2b-c393-567f-95bc06f6763a@samsung.com \
--to=speed.eom@samsung.com \
--cc=agk@redhat.com \
--cc=dm-devel@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mcneo.kang@samsung.com \
--cc=samitolvanen@google.com \
--cc=snitzer@redhat.com \
--cc=sunwook5492@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®