public inbox for virtio-comment@lists.linux.dev
 help / color / mirror / Atom feed
From: Parav Pandit <parav@nvidia.com>
To: <virtio-comment@lists.linux.dev>, <mst@redhat.com>,
	<cohuck@redhat.com>, <mvaralar@redhat.com>
Cc: <shahafs@nvidia.com>, Parav Pandit <parav@nvidia.com>
Subject: [PATCH v1] virtio-net: editorial: Annotate structure field
Date: Fri, 18 Oct 2024 15:35:01 +0300	[thread overview]
Message-ID: <20241018123501.432708-1-parav@nvidia.com> (raw)

Field command-specific-data is a structure field. Annotate it
as a field so that generated pdf shows it accordingly.

Signed-off-by: Parav Pandit <parav@nvidia.com>

---
changelog:
v0->v1:
- addressed comments from Stefano
- fixed more places which were missing the annotation
---
 device-types/net/description.tex | 25 +++++++++++++------------
 1 file changed, 13 insertions(+), 12 deletions(-)

diff --git a/device-types/net/description.tex b/device-types/net/description.tex
index b2a0d39..e45ecbd 100644
--- a/device-types/net/description.tex
+++ b/device-types/net/description.tex
@@ -1217,7 +1217,7 @@ \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi
 #define VIRTIO_NET_ERR    1
 \end{lstlisting}
 
-The \field{class}, \field{command} and command-specific-data are set by the
+The \field{class}, \field{command} and \field{command-specific-data} are set by the
 driver, and the device sets the \field{ack} byte and optionally
 \field{command-specific-result}. There is little the driver can
 do except issue a diagnostic if \field{ack} is not VIRTIO_NET_OK.
@@ -1255,13 +1255,13 @@ \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi
 commands:
 \begin{itemize}
 \item VIRTIO_NET_CTRL_RX_PROMISC turns promiscuous mode on and
-off. The command-specific-data is one byte containing 0 (off) or
+off. The \field{command-specific-data} is one byte containing 0 (off) or
 1 (on). If promiscuous mode is on, the device SHOULD receive all
 incoming packets.
 This SHOULD take effect even if one of the other modes set by
 a VIRTIO_NET_CTRL_RX class command is on.
 \item VIRTIO_NET_CTRL_RX_ALLMULTI turns all-multicast receive on and
-off. The command-specific-data is one byte containing 0 (off) or
+off. The \field{command-specific-data} is one byte containing 0 (off) or
 1 (on). When all-multicast receive is on the device SHOULD allow
 all incoming multicast packets.
 \end{itemize}
@@ -1271,24 +1271,24 @@ \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi
 commands:
 \begin{itemize}
 \item VIRTIO_NET_CTRL_RX_ALLUNI turns all-unicast receive on and
-off. The command-specific-data is one byte containing 0 (off) or
+off. The \field{command-specific-data} is one byte containing 0 (off) or
 1 (on). When all-unicast receive is on the device SHOULD allow
 all incoming unicast packets.
 \item VIRTIO_NET_CTRL_RX_NOMULTI suppresses multicast receive.
-The command-specific-data is one byte containing 0 (multicast
+The \field{command-specific-data} is one byte containing 0 (multicast
 receive allowed) or 1 (multicast receive suppressed).
 When multicast receive is suppressed, the device SHOULD NOT
 send multicast packets to the driver.
 This SHOULD take effect even if VIRTIO_NET_CTRL_RX_ALLMULTI is on.
 This filter SHOULD NOT apply to broadcast packets.
 \item VIRTIO_NET_CTRL_RX_NOUNI suppresses unicast receive.
-The command-specific-data is one byte containing 0 (unicast
+The \field{command-specific-data} is one byte containing 0 (unicast
 receive allowed) or 1 (unicast receive suppressed).
 When unicast receive is suppressed, the device SHOULD NOT
 send unicast packets to the driver.
 This SHOULD take effect even if VIRTIO_NET_CTRL_RX_ALLUNI is on.
 \item VIRTIO_NET_CTRL_RX_NOBCAST suppresses broadcast receive.
-The command-specific-data is one byte containing 0 (broadcast
+The \field{command-specific-data} is one byte containing 0 (broadcast
 receive allowed) or 1 (broadcast receive suppressed).
 When broadcast receive is suppressed, the device SHOULD NOT
 send broadcast packets to the driver.
@@ -1330,7 +1330,7 @@ \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi
 many addresses.
 }. This table is set using the class
 VIRTIO_NET_CTRL_MAC and the command VIRTIO_NET_CTRL_MAC_TABLE_SET. The
-command-specific-data is two variable length tables of 6-byte MAC
+\field{command-specific-data} is two variable length tables of 6-byte MAC
 addresses (as described in struct virtio_net_ctrl_mac). The first table contains unicast addresses, and the second
 contains multicast addresses.
 
@@ -1339,7 +1339,7 @@ \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi
 accepts (and if VIRTIO_NET_F_MAC has been negotiated,
 this will be reflected in \field{mac} in config space).
 
-The command-specific-data for VIRTIO_NET_CTRL_MAC_ADDR_SET is
+The \field{command-specific-data} for VIRTIO_NET_CTRL_MAC_ADDR_SET is
 the 6-byte MAC address.
 
 \devicenormative{\subparagraph}{Setting MAC Address Filtering}{Device Types / Network Device / Device Operation / Control Virtqueue / Setting MAC Address Filtering}
@@ -1406,7 +1406,8 @@ \subsubsection{Control Virtqueue}\label{sec:Device Types / Network Device / Devi
 \end{lstlisting}
 
 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.
+command take a little-endian 16-bit VLAN id as the
+\field{command-specific-data}.
 
 VIRTIO_NET_CTRL_VLAN_ADD command adds the specified VLAN to the
 VLAN filter table.
@@ -3036,10 +3037,10 @@ \subsubsection{Legacy Interface: Framing Requirements}\label{sec:Device
 \item for all commands, use a single 2-byte descriptor including the first two
 fields: \field{class} and \field{command}
 \item for all commands except VIRTIO_NET_CTRL_MAC_TABLE_SET
-use a single descriptor including command-specific-data
+use a single descriptor including \field{command-specific-data}
 with no padding.
 \item for the VIRTIO_NET_CTRL_MAC_TABLE_SET command use exactly
-two descriptors including command-specific-data with no padding:
+two descriptors including \field{command-specific-data} with no padding:
 the first of these descriptors MUST include the
 virtio_net_ctrl_mac table structure for the unicast addresses with no padding,
 the second of these descriptors MUST include the
-- 
2.34.1


             reply	other threads:[~2024-10-18 12:35 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-18 12:35 Parav Pandit [this message]
2024-10-18 14:31 ` [PATCH v1] virtio-net: editorial: Annotate structure field Stefano Garzarella

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=20241018123501.432708-1-parav@nvidia.com \
    --to=parav@nvidia.com \
    --cc=cohuck@redhat.com \
    --cc=mst@redhat.com \
    --cc=mvaralar@redhat.com \
    --cc=shahafs@nvidia.com \
    --cc=virtio-comment@lists.linux.dev \
    /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