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: [PATCH v6 1/5] virtio-net: Add theory of operation for flow filter


On Fri, Nov 10 2023, Parav Pandit <parav@nvidia.com> wrote:

> diff --git a/device-types/net/description.tex b/device-types/net/description.tex
> index aff5e08..30220b5 100644
> --- a/device-types/net/description.tex
> +++ b/device-types/net/description.tex
> @@ -33,6 +33,9 @@ \subsection{Virtqueues}\label{sec:Device Types / Network Device / Virtqueues}
>  controlq is optional; it only exists if VIRTIO_NET_F_CTRL_VQ is
>  negotiated.
>  
> +The flow filter virtqueues are optional; it may exists only if VIRTIO_NET_F_FLOW_FILTER
> +is negotiated and if the device reports such capability.

I first thought we should just reword this... but what does "such
capability" actually mean? If the feature is negotiated, there are M
flow filter virtqueues at positions 2N+1..2N+M, with the value of M
exposed by the device? I think we need to list those virtqueues
explicitly, otherwise it is confusing.

(...)

> +Each flow filter consists of one or more match key, a flow filter priority,

s/key/keys/

> +a flow filter identifier, an action to forward a packet to the destination
> +or to drop the packet.

(...)

> +The flow filter group can have one or more flow filters. Within a flow

s/The/A/

> +filter group, a packet may find a match to multiple flow filters. In such

s/find a match to/match/
s/such/such a/

> +scenario, a flow filter with the highest priority is applied first to the
> +packet, if there is no match, the next higher priority flow filter is applied.

Slightly confusing... maybe

"In such a scenario, of the matching flow filters the one with the
highest priority is applied, skipping any matching filters with a lower
priority."

(At least, that's how I interpret this.)


> +
> +\paragraph{Packet Processing Order}\label{sec:sec:Device Types / Network Device / Device Operation / Flow Filter / Packet Processing Order}
> +
> +Whichever filtering and steering functionality is enabled, they are
> +applied in the following order for the received packet:

"If enabled, filtering and steering functionalities are applied to the
received packet in the following order:" ?

> +
> +\begin{itemize}
> +\item apply device configuration done using control virtqueue commands
> +      VIRTIO_NET_CTRL_RX, VIRTIO_NET_CTRL_MAC and VIRTIO_NET_CTRL_VLAN.
> +\item apply flow filter configuration done using flow filter requests.
> +\item apply device configuration done using command
> +      VIRTIO_NET_CTRL_MQ_RSS_CONFIG.
> +\end{itemize}
> +
> +While processing a received packet, at any stage if the packet is dropped,

"if the packet is dropped at any stage"

> +the next level of processing is omitted.

"the following levels of processing are omitted"

> +
> +When a flow filter is matched for the packet, it also stops the processing
> +of the packet for next stage.

"If a flow filter is matched for the packet, the following levels of
processing are omitted as well." ?

> +
> +Few examples are:

s/Few/A few/

> +\begin{itemize}
> +\item If the packet is dropped by the flow filter configuration, RSS
> +      configuration is not applied to such a packet.
> +\item If the packet is forwarded to a specific receiveq using flow filters,
> +      RSS configuration is not applied to such a packet due to a match on the
> +      flow filter request.
> +\item If the packet is dropped due to VIRTIO_NET_CTRL_MAC configuration,
> +      flow filters or RSS configuration is not applied to such a packet.

"neither flow filters nor RSS configuration are applied"

> +\item If the packet does not find any match in any of the flow filter groups,
> +      next level RSS device configuration is applied if its exists.
> +\item If there are three flow filter groups configured as group_A, group_B
> +      and group_C with respective priorities as 4, 5, and 6; flow filters of

s/flow filters/the flow filters/

> +      group_C is applied first having highest group priority, if there is a match,

s/is applied/are applied/

> +      flow filters of group_B and group_A are skipped; if there is no match for
> +      the flow filters in group_C, the flow filters of next level group_B are applied.
> +\end{itemize}
> +
> +\label{sec:Device Types / Network Device / Device Operation / Control Virtqueue / Setting Promiscuous Mode}%old label for latexdiff
>  \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Device Operation / Control Virtqueue}
>  
>  The driver uses the control virtqueue (if VIRTIO_NET_F_CTRL_VQ is



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