lkml.org 
[lkml]   [2015]   [Jan]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [PATCH] block: pass correct seed to integrity metadata generation function
Date


> -----Original Message-----
> From: Martin K. Petersen [mailto:martin.petersen@oracle.com]
> Sent: Wednesday, January 07, 2015 4:19 PM
> To: Sam Bradshaw (sbradshaw)
> Cc: Martin K. Petersen; axboe@kernel.dk; linux-kernel@vger.kernel.org
> Subject: Re: [PATCH] block: pass correct seed to integrity metadata
> generation function
>
> >>>>> "Sam" == Sam Bradshaw (sbradshaw) <sbradshaw@micron.com> writes:
>
> Sam> Yes.
>
> The seed is just a seed. We happen to set it to the (block layer)
> sector number if nothing else is provided but it's essentially just an
> incrementing counter starting at an arbitrary value chosen by the
> caller.
>
> Since an I/O may get remapped many times as block devices are stacked
> (DM, MD, stripe splits, partition offset shifts, etc.) the seed is not
> expected to match the LBA on the storage device. That is almost never
> the case.
>
> In SCSI we do a remapping pass before submitting a WRITE or upon
> completion of a READ. You will have to do the same for NVMe.
>
> It was done this way to avoid remapping the ref tag several times. We
> adjust the seed as the I/O gets sliced and diced and only map the PI
> pages once to do a single traversal at the bottom of the stack.
>
> For next gen devices we simply pass the seed to the hardware and let it
> handle the remapping. This saves us having to map the PI pages and pull
> them through the cache.

Got it, thanks!



\
 
 \ /
  Last update: 2015-01-08 02:21    [W:0.054 / U:0.464 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site