From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gandalf.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3]) by passt.top (Postfix) with ESMTPS id 62C275A02E4 for ; Wed, 1 May 2024 02:10:33 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gibson.dropbear.id.au; s=202312; t=1714522228; bh=CQAUfilOf/PwEDS5+kAuc8XXt6EhL1BRM+xxNqUBRcM=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Lh8/dLUjkK7JGaL6FgUAHnoSUHi9XyqgJHX2HgAOeIBJteVVf390CI6oyQh3hzUOH KVDVbcWPsrADWauCgJThYsRxeQl2mWFUhrXtFkgTfSQUFO7QftzzX1Da8+RGEqskB3 jkmiFIIstKZ/k5O/Q/nqY4YuS2Ta4UiVEVKgjsl0aWh14o3fZl2WrvwLRTEIPhJKQz jn5w9SoHuIfC3+hVXo06JOrHXNtMkSyPZzsuQ6fc7soJLVifP2Vx0wxO9RgKhkEQ5G 3gsDVhFwM8angeWkTk+0VZCCgjXM1LqNCVRdGGbPLqV0S/xQfSWH50/SozC7ncg4ml gtFhBAyrN9HNA== Received: by gandalf.ozlabs.org (Postfix, from userid 1007) id 4VTcsJ3LG7z4x1y; Wed, 1 May 2024 10:10:28 +1000 (AEST) Date: Wed, 1 May 2024 10:10:22 +1000 From: David Gibson To: Stefano Brivio Subject: Re: [PATCH 7/7] tcp: Update tap specific header too in tcp_fill_headers[46]() Message-ID: References: <20240429070933.1366881-1-david@gibson.dropbear.id.au> <20240429070933.1366881-8-david@gibson.dropbear.id.au> <20240430204809.52711861@elisabeth> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="2ianKqliZt2mJAsc" Content-Disposition: inline In-Reply-To: <20240430204809.52711861@elisabeth> Message-ID-Hash: PH72EAICMQVSNWLUOEHK54G674HRXCBW X-Message-ID-Hash: PH72EAICMQVSNWLUOEHK54G674HRXCBW X-MailFrom: dgibson@gandalf.ozlabs.org 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: passt-dev@passt.top, Laurent Vivier 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: --2ianKqliZt2mJAsc Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Apr 30, 2024 at 08:48:40PM +0200, Stefano Brivio wrote: > On Mon, 29 Apr 2024 17:09:33 +1000 > David Gibson wrote: >=20 > > tcp_fill_headers[46]() fill most of the headers, but the tap specific > > header (the frame length for qemu sockets) is filled in afterwards. > > Filling this as well: > > * Removes a little redundancy between the tcp_send_flag() and > > tcp_data_to_tap() path > > * Makes calculation of the correct length a little easier > > * Removes the now misleadingly named 'vnet_len' variable in > > tcp_send_flag() > >=20 > > Signed-off-by: David Gibson > > --- > > tcp.c | 28 ++++++++++++++-------------- > > 1 file changed, 14 insertions(+), 14 deletions(-) > >=20 > > diff --git a/tcp.c b/tcp.c > > index 27c06958..01987c04 100644 > > --- a/tcp.c > > +++ b/tcp.c > > @@ -1321,6 +1321,7 @@ static void tcp_fill_header(struct tcphdr *th, > > * tcp_fill_headers4() - Fill 802.3, IPv4, TCP headers in pre-cooked b= uffers > > * @c: Execution context > > * @conn: Connection pointer > > + * @taph: TAP backend specific header >=20 > Here and below: s/TAP/tap/. Other than the minor comments I shared the Adjusted, thanks. > series looks good to me (and looks like a big improvement in terms of > possible sources of confusion). --=20 David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson --2ianKqliZt2mJAsc Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEO+dNsU4E3yXUXRK2zQJF27ox2GcFAmYxiG0ACgkQzQJF27ox 2Geufg//fFVikw59DifI/qslYWNt04uTFwxq4urhTQDn+D382KhwLnLhn3ZfyGYK 5wowXlYeM8iVc6T9TTXx9THR9zJqIqGuBPDZPblqKGwVX01hXViXFoE3U4xswN8/ 4cPqf960mdeoxgxxzGBWvpRrK2dhqzz+67irB3wGqTcBOFB/V46UzsXOxLUq8giS Kuh3nTpWSC53ni7ECezOoZdmJE70zRX4pzhUmvCcYRKLfJLyLcQ4iah5R0kEUUmT lsWin04qx52WZ05ch7DKPLlFrgtqqWPSmG0PfGkGR9fY4au7Iax1cvBkc+W2OBKz S32GFxvFbDoEAirCvvqZKWKyUo7HmNqhlC44VQhKf5K9uu4TqDkzKanTTse1NIKo dV70us1Z+2xiFtP4S+BfrjorlkDt8yvAYd+C0Sk37jNf5xWfloWD8cTM1HXJAKuT RoO/fwTRXejnqKgCaLhsxzepBGRO674coZuLvuc2qK8iqOdOr40PKJa9soiu9eIM bTrpL62JdR1YTjcEKhuf0e85P4sDASj2BI0ZhZCVBeJhrUeV2/5QDlU1PLIyaINs fOXAo8/xR824jMXpGflO/9T4rQnCeDoeYTEwiXUh0IGkjyUs8tYxgfFaLYrcnN43 d/fyIUZmWsMx79PVTB8bjBW5TE4G4Na21gbAY150riY+7MdYrKE= =0fki -----END PGP SIGNATURE----- --2ianKqliZt2mJAsc--