From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: passt.top; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: passt.top; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=eujzmDTf; dkim-atps=neutral Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by passt.top (Postfix) with ESMTPS id 1592A5A0265 for ; Tue, 24 Feb 2026 18:57:20 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1771955839; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=v3VIeZElMEpM4/w9L6us0kYkIGOveXt9WI05uCzLCGE=; b=eujzmDTfL8O9B+0mTtnF7gA/ajZgVrUnmJVaj78NBJ38cyotheS97m/ERfG1G5+1biX33g HLT2IP0BQvU4CWPbQ5B5SJ2tXCMA0VpGp6UyXL+OTM2qK61osynbwTbQr1oLx2HFgHPrKd LzoOVTiXv19uSHAM8omLAFi0tTt/4pk= Received: from mail-wm1-f71.google.com (mail-wm1-f71.google.com [209.85.128.71]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-56-3dDb2fziOvGkDExtfJxOpg-1; Tue, 24 Feb 2026 12:57:18 -0500 X-MC-Unique: 3dDb2fziOvGkDExtfJxOpg-1 X-Mimecast-MFC-AGG-ID: 3dDb2fziOvGkDExtfJxOpg_1771955837 Received: by mail-wm1-f71.google.com with SMTP id 5b1f17b1804b1-4836cd6dfe6so21785135e9.2 for ; Tue, 24 Feb 2026 09:57:18 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1771955837; x=1772560637; h=date:content-transfer-encoding:mime-version:organization:references :in-reply-to:message-id:subject:cc:to:from:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=v3VIeZElMEpM4/w9L6us0kYkIGOveXt9WI05uCzLCGE=; b=RWcWmikNArbmuf/f4d1NOLvIy0UChgRyiQ7CWKGekjvyPEbIn/6dZkL8KyN5ymiJf2 Wt2iVUzmXqeghy5ArMInFY6v1PyzKE56t+Q1adkazYDd4Kd/TB8aOkjyOzyOZqv/prz6 iRebhI69MeSVyYNzeKGQUF3NzeXrG5ur70NJRArTFvIyM9hr4lyomJ+/L+75Kv0Z5IE4 3NbTr9BSr1wjk1xhHhcQNDhafatKh9MIudOwWwOePI2oLF0eEC5v8HV6gYNmsY9gBklI nRMP+PUMQy433B40l7XVNID8JCxR2213wvby2nQ0Mv2u5oH//bkjWIgUSYlmsIV3V34S DqLw== X-Forwarded-Encrypted: i=1; AJvYcCXnP43LZKrP5mLtXdBLNlC3oV5xISzKWWB45NeXRWe+xP1BFVhNC54vyDgu48xjfBnn1MHSBtcdVps=@passt.top X-Gm-Message-State: AOJu0YzgP+3/WOidWJgRmMROB3WubKlyF9QPXUIVFBVj28i65/8bduyU eQWb10LNS0s98rZTEdP+cjGOrEydQGQZul4MN5QxgO4QIRZn1hwHJUPSdpJhb05vmWMEQN9lErr rVeTdp+23ohAQxV4d9baNF5AGIwhsiKJKnBgd1hCBrAzNcvCrW8UD/dVfZJs0sm0hWfDE6Yc1gJ kvRBKSIPSuM92J5tBpaJdZei34M4k2rqTeP3Sa X-Gm-Gg: AZuq6aJeEwfO7WGAtjkmC1Q3V8mPdbKxTSx8wW3PlpAcCqhOGVit3Jspxfy64Eawiu2 witRhwC3DDZYpjrxYQtceffsuwIfCuqI9ueXjXnWB2lg7oICJOOGHeLnrkk7Yxd64fiL/Fy/LxM HyLBwWL5AvPnk6/QrSh/Hlc3uJjm9w4V1q7PoRwV2yU6LI2IgLFsVRPV2C2jArdvODR3WEeFqx1 bmmVoOHUsX/QMfTZtqLEYBYvQQpZO/VsbD+TPOJt7vhFq1WkTFshTuKoIPR2Y1W0sY7CUSZmWp0 zE7urQlP0OWfMLhlTpDd+W7Yr21PoshPj66EJsf/k/FxGZ/ivBg4LuvaxkaYxUI9SVSf8uUxdwu 06AnwgKzGY5DhzkM7RPQG1/5fiG/VQBm8 X-Received: by 2002:a05:600c:6094:b0:483:8f0f:36fe with SMTP id 5b1f17b1804b1-483a95eac45mr227908705e9.1.1771955836893; Tue, 24 Feb 2026 09:57:16 -0800 (PST) X-Received: by 2002:a05:600c:6094:b0:483:8f0f:36fe with SMTP id 5b1f17b1804b1-483a95eac45mr227908255e9.1.1771955836418; Tue, 24 Feb 2026 09:57:16 -0800 (PST) Received: from maya.myfinge.rs (ifcgrfdd.trafficplex.cloud. [2a10:fc81:a806:d6a9::1]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-483bd68826asm24747315e9.0.2026.02.24.09.57.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 24 Feb 2026 09:57:16 -0800 (PST) From: Stefano Brivio To: Laurent Vivier Subject: Re: [PATCH trivial] tcp_vu, udp_vu: Fix comment headers for header length functions Message-ID: <20260224185714.5d5bf508@elisabeth> In-Reply-To: References: <20260224122227.437310-1-lvivier@redhat.com> <20260224162409.6ab5eb90@elisabeth> Organization: Red Hat X-Mailer: Claws Mail 4.2.0 (GTK 3.24.49; x86_64-pc-linux-gnu) MIME-Version: 1.0 Date: Tue, 24 Feb 2026 18:57:15 +0100 (CET) X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: 7O31-ij92yiqGYff04PNNB6-sqUYV9oJe8QIGU-KFZ8_1771955837 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Message-ID-Hash: GZQQBWGZBKDUSMVLO2DRFRKMIUHHFAAI X-Message-ID-Hash: GZQQBWGZBKDUSMVLO2DRFRKMIUHHFAAI X-MailFrom: sbrivio@redhat.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Laurent Vivier , passt-dev@passt.top X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: On Tue, 24 Feb 2026 16:26:59 +0100 Laurent Vivier wrote: > On 2/24/26 16:24, Stefano Brivio wrote: > > On Tue, 24 Feb 2026 13:22:27 +0100 > > Laurent Vivier wrote: > > > >> The comment headers for tcp_vu_hdrlen() and udp_vu_hdrlen() described > >> the return value as "the size of the header in level 2 frame", but > >> these functions also include the virtio net header, which is not part > >> of the L2 frame. > >> > >> Signed-off-by: Laurent Vivier > >> --- > >> tcp_vu.c | 4 ++-- > >> udp_vu.c | 4 ++-- > >> 2 files changed, 4 insertions(+), 4 deletions(-) > >> > >> diff --git a/tcp_vu.c b/tcp_vu.c > >> index 94169c21f700..8908d376a7dd 100644 > >> --- a/tcp_vu.c > >> +++ b/tcp_vu.c > >> @@ -40,10 +40,10 @@ static struct vu_virtq_element elem[VIRTQUEUE_MAX_SIZE]; > >> static int head[VIRTQUEUE_MAX_SIZE + 1]; > >> > >> /** > >> - * tcp_vu_hdrlen() - return the size of the header in level 2 frame (TCP) > >> + * tcp_vu_hdrlen() - Return the size of virtio net and L2 headers (TCP) > > > > Thanks, I think that this, plus the line changed below, makes it clear. > > > > What I still find confusing is: "L2 headers (TCP)". If I see this > > together with udp_vu_hdrlen() I understand what you mean, but > > otherwise I'd ask myself what TCP has to do with Layer-2... > > > > I tried rephrasing it a bit, what do you think about: > > > > * tcp_vu_hdrlen() - Sum size of all headers, from TCP to virtio-net > > > >> * @v6: Set for IPv6 packet > >> * > >> - * Return: return the size of the header > >> + * Return: total size of virtio net header, Ethernet, IP and TCP headers > > > > ...and changing this to "virtio-net" (not a very official name but it > > seems to be widely used, more than "virtio net"...)? > > > > If you're fine with it (same for UDP) I would change it and apply. I'm > > not exactly proud of this either, so if you or somebody else has better > > ideas... > > I'm fine with it, go ahead... Applied with changes as discussed. -- Stefano