OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

virtio-comment message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]

Subject: Re: [virtio-comment] [PATCH] virtio-blk: clarify descriptor-segment relation

On Tue, Jan 12, 2021 at 11:16:11AM +0200, Laura Loghin wrote:
> Regarding the relation between data descriptors and segments, the
> commit that added discard and write zeroes to the spec, stated that
> the idea is "using 16 Bytes payload to support 1 descriptor" (not, for
> example, 32 bytes). There wasn't any mention in the spec about one data
> descriptor corresponding to exactly one segment. Added this constraint
> to block documentation.
> Signed-off-by: Laura Loghin <lauralg@amazon.com>
> ---
>  content.tex | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
> diff --git a/content.tex b/content.tex
> index 620c0e2..6393b68 100644
> --- a/content.tex
> +++ b/content.tex
> @@ -4599,8 +4599,9 @@ \subsection{Device Operation}\label{sec:Device Types / Block Device / Device Ope
>  of 512 bytes).
>  The \field{data} used for discard or write zeroes commands consists of one or
> -more segments.  The maximum number of segments is \field{max_discard_seg} for
> -discard commands and \field{max_write_zeroes_seg} for write zeroes commands.
> +more segments, and one data descriptor corresponds to exactly one such segment.
> +The maximum number of segments is \field{max_discard_seg} for discard commands
> +and \field{max_write_zeroes_seg} for write zeroes commands.
>  Each segment is of form:

I'm not sure what this means, could you clarify?

There is no concept of "descriptor" in virtio-blk write zeroes/discard.
There is only the "segment" (struct virtio_blk_discard_write_zeroes).

If you are referring to vring descriptors, then there is no relationship
between struct virtio_blk_req::data[] and vring descriptors. The driver
may choose any vring descriptor framing/layout (see 2.6.4 Message


Attachment: signature.asc
Description: PGP signature

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]