virtio-network: Clarify VLAN filter table configuration
PATCH v8 1/1 virtio-network: Clarify VLAN filter table configuration
The filtering behavior of the VLAN filter commands is not very clear as discussed in thread [1].
Hence, add the command description and device requirements for it.
[1] https://www.mail-archive.com/[email protected]/msg912392.html
---
changelog:v7->v8:
- Fixed grammarv6->v7:
- Moved VLAN filter table description from requirements to device descrption section
- Added MUST and SHOULD to device requirementsv5->v6:
- removed unwanted articlev4->v5:
- reworded 'vlan filtering table' to 'vlan filter table' to match to the existing description about vlan filtering
- remove confusing text around VLAN_DEL command description
- added missing article
- reword device match configuration to device configuration
- changed 'found' to 'present' and 'not found' to 'absent' to consider vlan filter table as config table rather than search tablev3->v4:
- added description for accepting vlan tagged packets when vlan filter is not negotiatedv2->v3:
- corrected grammar
- simplified description for untagged packetsv1->v2:
- adapt to new file pathv0->v1:
- added missing conformance section link
--- .../virtio-network/device-conformance.tex | 1 + device-types/virtio-network/device.tex | 22 ++++++++++++++++++- 2 files changed, 22 insertions(+), 1 deletion(-)
device-types/virtio-network/device-conformance.tex +1 -0
@@ -9,6 +9,7 @@ \item \ref{devicenormative:Device Types / Network Device / Device Operation / Processing of Incoming Packets} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Packet Receive Filtering} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Setting MAC Address Filtering} +\item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / VLAN Filtering} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Gratuitous Packet Sending} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Automatic receive steering in multiqueue mode} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Receive-side scaling (RSS) / RSS processing}
device-types/virtio-network/device.tex +21 -1
@@ -1194,7 +1194,11 @@ \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi \paragraph{VLAN Filtering}\label{sec:Device Types / Network Device / Device Operation / Control Virtqueue / VLAN Filtering} If the driver negotiates the VIRTIO_NET_F_CTRL_VLAN feature, it -can control a VLAN filter table in the device. +can control a VLAN filter table in the device. The VLAN filter +table applies only to VLAN tagged packets. + +When VIRTIO_NET_F_CTRL_VLAN is negotiated, the device starts with +an empty VLAN filter table. \begin{note} Similar to the MAC address based filtering, the VLAN filtering
@@ -1210,6 +1214,22 @@ \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi Both the VIRTIO_NET_CTRL_VLAN_ADD and VIRTIO_NET_CTRL_VLAN_DEL command take a little-endian 16-bit VLAN id as the command-specific-data. +VIRTIO_NET_CTRL_VLAN_ADD command adds the specified VLAN to the +VLAN filter table. + +VIRTIO_NET_CTRL_VLAN_DEL command removes the specified VLAN from +the VLAN filter table. + +\devicenormative{\subparagraph}{VLAN Filtering}{Device Types / Network Device / Device Operation / Control Virtqueue / VLAN Filtering} + +When VIRTIO_NET_F_CTRL_VLAN is not negotiated, the device MUST +accept all VLAN tagged packets as per the device configuration. + +When VIRTIO_NET_F_CTRL_VLAN is negotiated, the device MUST +accept all VLAN tagged packets whose VLAN tag is present in +the VLAN filter table and SHOULD drop all VLAN tagged packets +whose VLAN tag is absent in the VLAN filter table. + \subparagraph{Legacy Interface: VLAN Filtering}\label{sec:Device Types / Network Device / Device Operation / Control Virtqueue / VLAN Filtering / Legacy Interface: VLAN Filtering} When using the legacy interface, transitional devices and drivers MUST format the VLAN id
Signature · 18 lines
2.26.2 This publicly archived list offers a means to provide input to the OASIS Virtual I/O Device (VIRTIO) TC. In order to verify user consent to the Feedback License terms and to minimize spam in the list archive, subscription is required before posting. Subscribe: [email protected] Unsubscribe: [email protected] List help: [email protected] List archive: https://lists.oasis-open.org/archives/virtio-comment/ Feedback License: https://www.oasis-open.org/who/ipr/feedback_license.pdf List Guidelines: https://www.oasis-open.org/policies-guidelines/mailing-lists Committee: https://www.oasis-open.org/committees/virtio/ Join OASIS: https://www.oasis-open.org/join/
Quoted 9 lines · Parav Pandit
The filtering behavior of the VLAN filter commands is not very clear as discussed in thread [1].
Hence, add the command description and device requirements for it.
[1] https://www.mail-archive.com/[email protected]/msg912392.html
Suggested-by Si-Wei Liu <[email protected]>Signed-off-by Parav Pandit <[email protected]>
Quoted 88 lines
---
changelog:v7->v8:
- Fixed grammarv6->v7:
- Moved VLAN filter table description from requirements to device descrption section
- Added MUST and SHOULD to device requirementsv5->v6:
- removed unwanted articlev4->v5:
- reworded 'vlan filtering table' to 'vlan filter table' to match to the existing description about vlan filtering
- remove confusing text aroundVLAN_DELcommand description
- added missing article
- reword device match configuration to device configuration
- changed 'found' to 'present' and 'not found' to 'absent' to consider vlan filter table as config table rather than search tablev3->v4:
- added description for accepting vlan tagged packets when vlan filter is not negotiatedv2->v3:
- corrected grammar
- simplified description for untagged packetsv1->v2:
- adapt to new file pathv0->v1:
- added missing conformance section link--- .../virtio-network/device-conformance.tex | 1 + device-types/virtio-network/device.tex | 22 ++++++++++++++++++- 2 files changed, 22 insertions(+), 1 deletion(-)device-types/virtio-network/device-conformance.tex +1
-0@@ -9,6 +9,7 @@ \item \ref{devicenormative:Device Types / Network Device / Device Operation / Processing of Incoming Packets} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Packet Receive Filtering} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Setting MAC Address Filtering} +\item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / VLAN Filtering} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Gratuitous Packet Sending} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Automatic receive steering in multiqueue mode} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Receive-side scaling (RSS) / RSS processing}device-types/virtio-network/device.tex +21
-1@@ -1194,7 +1194,11 @@ \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi \paragraph{VLAN Filtering}\label{sec:Device Types / Network Device / Device Operation / Control Virtqueue / VLAN Filtering} If the driver negotiates the VIRTIO_NET_F_CTRL_VLAN feature, it -can control a VLAN filter table in the device. +can control a VLAN filter table in the device. The VLAN filter +table applies only to VLAN tagged packets. + +When VIRTIO_NET_F_CTRL_VLAN is negotiated, the device starts with +an empty VLAN filter table. \begin{note} Similar to the MAC address based filtering, the VLAN filtering@@ -1210,6 +1214,22 @@ \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi Both the VIRTIO_NET_CTRL_VLAN_ADD and VIRTIO_NET_CTRL_VLAN_DEL command take a little-endian 16-bit VLAN id as the command-specific-data. +VIRTIO_NET_CTRL_VLAN_ADD command adds the specified VLAN to the +VLAN filter table. + +VIRTIO_NET_CTRL_VLAN_DEL command removes the specified VLAN from +the VLAN filter table. + +\devicenormative{\subparagraph}{VLAN Filtering}{Device Types / Network Device / Device Operation / Control Virtqueue / VLAN Filtering} + +When VIRTIO_NET_F_CTRL_VLAN is not negotiated, the device MUST +accept all VLAN tagged packets as per the device configuration. + +When VIRTIO_NET_F_CTRL_VLAN is negotiated, the device MUST +accept all VLAN tagged packets whose VLAN tag is present in +the VLAN filter table and SHOULD drop all VLAN tagged packets +whose VLAN tag is absent in the VLAN filter table. + \subparagraph{Legacy Interface: VLAN Filtering}\label{sec:Device Types / Network Device / Device Operation / Control Virtqueue / VLAN Filtering / Legacy Interface: VLAN Filtering} When using the legacy interface, transitional devices and drivers MUST format the VLAN idSignature · 1 line
2.26.2
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
Quoted 9 lines · Parav Pandit
The filtering behavior of the VLAN filter commands is not very clear as discussed in thread [1].
Hence, add the command description and device requirements for it.
[1] https://www.mail-archive.com/[email protected]/msg912392.html
Suggested-by Si-Wei Liu <[email protected]>Signed-off-by Parav Pandit <[email protected]>
-Siwei
Quoted 76 lines
---
changelog:v7->v8:
- Fixed grammarv6->v7:
- Moved VLAN filter table description from requirements to device descrption section
- Added MUST and SHOULD to device requirementsv5->v6:
- removed unwanted articlev4->v5:
- reworded 'vlan filtering table' to 'vlan filter table' to match to the existing description about vlan filtering
- remove confusing text aroundVLAN_DELcommand description
- added missing article
- reword device match configuration to device configuration
- changed 'found' to 'present' and 'not found' to 'absent' to consider vlan filter table as config table rather than search tablev3->v4:
- added description for accepting vlan tagged packets when vlan filter is not negotiatedv2->v3:
- corrected grammar
- simplified description for untagged packetsv1->v2:
- adapt to new file pathv0->v1:
- added missing conformance section link--- .../virtio-network/device-conformance.tex | 1 + device-types/virtio-network/device.tex | 22 ++++++++++++++++++- 2 files changed, 22 insertions(+), 1 deletion(-)device-types/virtio-network/device-conformance.tex +1
-0@@ -9,6 +9,7 @@ \item \ref{devicenormative:Device Types / Network Device / Device Operation / Processing of Incoming Packets} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Packet Receive Filtering} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Setting MAC Address Filtering} +\item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / VLAN Filtering} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Gratuitous Packet Sending} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Automatic receive steering in multiqueue mode} \item \ref{devicenormative:Device Types / Network Device / Device Operation / Control Virtqueue / Receive-side scaling (RSS) / RSS processing}device-types/virtio-network/device.tex +14
-1@@ -1194,7 +1194,11 @@ \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi \paragraph{VLAN Filtering}\label{sec:Device Types / Network Device / Device Operation / Control Virtqueue / VLAN Filtering} If the driver negotiates the VIRTIO_NET_F_CTRL_VLAN feature, it -can control a VLAN filter table in the device. +can control a VLAN filter table in the device. The VLAN filter +table applies only to VLAN tagged packets. + +When VIRTIO_NET_F_CTRL_VLAN is negotiated, the device starts with +an empty VLAN filter table. \begin{note} Similar to the MAC address based filtering, the VLAN filtering@@ -1210,6 +1214,22 @@ \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi Both the VIRTIO_NET_CTRL_VLAN_ADD and VIRTIO_NET_CTRL_VLAN_DEL command take a little-endian 16-bit VLAN id as the command-specific-data. +VIRTIO_NET_CTRL_VLAN_ADD command adds the specified VLAN to the +VLAN filter table. + +VIRTIO_NET_CTRL_VLAN_DEL command removes the specified VLAN from +the VLAN filter table. + +\devicenormative{\subparagraph}{VLAN Filtering}{Device Types / Network Device / Device Operation / Control Virtqueue / VLAN Filtering} + +When VIRTIO_NET_F_CTRL_VLAN is not negotiated, the device MUST
device-types/virtio-network/device.tex \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi · line 1235
Quoted 10 lines
device-types/virtio-network/device.tex +7
-0+accept all VLAN tagged packets as per the device configuration. + +When VIRTIO_NET_F_CTRL_VLAN is negotiated, the device MUST +accept all VLAN tagged packets whose VLAN tag is present in +the VLAN filter table and SHOULD drop all VLAN tagged packets +whose VLAN tag is absent in the VLAN filter table. + \subparagraph{Legacy Interface: VLAN Filtering}\label{sec:Device Types / Network Device / Device Operation / Control Virtqueue / VLAN Filtering / Legacy Interface: VLAN Filtering} When using the legacy interface, transitional devices and drivers MUST format the VLAN id
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]