From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail.ozlabs.org (mail.ozlabs.org [IPv6:2404:9400:2221:ea00::3]) by passt.top (Postfix) with ESMTPS id 656195A004F for ; Wed, 12 Jun 2024 08:28:10 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gibson.dropbear.id.au; s=202312; t=1718173687; bh=zKZ0XUwgrzeqVxuPoaMbgN7i8Ld9sCG8N8zKUjgV/BY=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Nmf6ckKkQJ0gVOHwccyp4bJ3/u7/BIZlK+CJQA7xJsRwACzr860XKnEc4TI9Cqxxs U3wv9Pr9UoPLVy/oMMcf4o+UAlDat0bY909DI2qzd7Pfwk1VRfj/fBpw670zQ6MwqV 9j9d8QtXkFchti7BItQ47dg1qCxhVVNGxrTXR/8kOljvE23tkKi3NiWVCpwLTfiBHq UU44FwEMpugdEh6iRJf/dJSeF6zITqn9hqxzvZrt95+3bU48Zk3gbYcGrcNTo37kgd aGCLSPK1FlKRwdPx7Jbpr4A9dWfNm7KH2Wq+YKj3ElDnEeCABFTtcXEt0fWTSj0Bq8 +bjzetPkxb9AQ== Received: by gandalf.ozlabs.org (Postfix, from userid 1007) id 4VzbFg6c4rz4w2P; Wed, 12 Jun 2024 16:28:07 +1000 (AEST) Date: Wed, 12 Jun 2024 16:28:01 +1000 From: David Gibson To: Laurent Vivier Subject: Re: [PATCH v5 5/8] udp: rename udp_sock_handler() to udp_buf_sock_handler() Message-ID: References: <20240605152129.1641658-1-lvivier@redhat.com> <20240605152129.1641658-6-lvivier@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="777j0PYLacl3Y1gb" Content-Disposition: inline In-Reply-To: <20240605152129.1641658-6-lvivier@redhat.com> Message-ID-Hash: VKIM7FYWXJ4YOD65WLLFNZNSR64KP3QS X-Message-ID-Hash: VKIM7FYWXJ4YOD65WLLFNZNSR64KP3QS 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 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: --777j0PYLacl3Y1gb Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Jun 05, 2024 at 05:21:26PM +0200, Laurent Vivier wrote: > We are going to introduce a variant of the function to use > vhost-user buffers rather than passt internal buffers. >=20 > Signed-off-by: Laurent Vivier Reviewed-by: David Gibson > --- > passt.c | 2 +- > udp.c | 6 +++--- > udp.h | 2 +- > 3 files changed, 5 insertions(+), 5 deletions(-) >=20 > diff --git a/passt.c b/passt.c > index a8c4cd3f8820..69a59f1e9b6d 100644 > --- a/passt.c > +++ b/passt.c > @@ -365,7 +365,7 @@ loop: > tcp_timer_handler(&c, ref); > break; > case EPOLL_TYPE_UDP: > - udp_sock_handler(&c, ref, eventmask, &now); > + udp_buf_sock_handler(&c, ref, eventmask, &now); > break; > case EPOLL_TYPE_PING: > icmp_sock_handler(&c, ref); > diff --git a/udp.c b/udp.c > index 4295d48046a6..a13013901e26 100644 > --- a/udp.c > +++ b/udp.c > @@ -729,7 +729,7 @@ static void udp_tap_send(const struct ctx *c, > } > =20 > /** > - * udp_sock_handler() - Handle new data from socket > + * udp_buf_sock_handler() - Handle new data from socket > * @c: Execution context > * @ref: epoll reference > * @events: epoll events bitmap > @@ -737,8 +737,8 @@ static void udp_tap_send(const struct ctx *c, > * > * #syscalls recvmmsg > */ > -void udp_sock_handler(const struct ctx *c, union epoll_ref ref, uint32_t= events, > - const struct timespec *now) > +void udp_buf_sock_handler(const struct ctx *c, union epoll_ref ref, uint= 32_t events, > + const struct timespec *now) > { > /* For not entirely clear reasons (data locality?) pasta gets > * better throughput if we receive tap datagrams one at a > diff --git a/udp.h b/udp.h > index 9976b6231f1c..5865def20856 100644 > --- a/udp.h > +++ b/udp.h > @@ -9,7 +9,7 @@ > #define UDP_TIMER_INTERVAL 1000 /* ms */ > =20 > void udp_portmap_clear(void); > -void udp_sock_handler(const struct ctx *c, union epoll_ref ref, uint32_t= events, > +void udp_buf_sock_handler(const struct ctx *c, union epoll_ref ref, uint= 32_t events, > const struct timespec *now); > int udp_tap_handler(struct ctx *c, uint8_t pif, sa_family_t af, > const void *saddr, const void *daddr, --=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 --777j0PYLacl3Y1gb Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEO+dNsU4E3yXUXRK2zQJF27ox2GcFAmZpP/AACgkQzQJF27ox 2GeK6w/9FRQ38Eb+7YvKEIlnKq0HoavnF4c3it3Gxsu109dH8whZ9NRwGw2Sax8w am/Wk24CWm73k7kHx1Ig/hKlonrpl1DYuwPfytsY7Perfc4bbLm/MnXqu0TKGcHZ qM7Lr6tcRrvsyCpU0BIanhNt74+QouLwMa89h/vF+5F2SmV+h1/1i330JdG6+H2X C0epRvj2u8l8eXlUP2i02ca2Kh2T9GAPJ0TBhlmAf6k6AT45Iqrb6J7zoz0/HINc fwGhmrgQTqbFa2ClkK0DyOsNh3nH0MMOAN2qarhhnob7j7X+sWliRzqlsXcUMR5p gX7x8NlNZ9PjyJIX6/lYp4t2eJR7fIfWplIYojpK9Zh72ZsXlCL8kEWhtJUu5OsZ JFA1WWIfTtqtyOjYkUiJE0SYhz4hv57IzHbiVqgxvhLPvDPMEkXVBJJ7/HSiP9zf spW+qwzMahk5xRuuRQShohTUVOTRfIWtxpOxMHWKzT8DmKOXCIWLDzmRgrqdG5oY j9IZG9h3HUQz878JwxySfq6UPA8A6uarCaOkwSkZO8guBqPme+IprhIKk2CBJc0+ bArKTD98Ksg/FIttQIh5kXlMxt7RUVgH32UU4ctc0UsoVBgnUmfDWb83Tzmg615b 0er+SZbeEyivZyqYrC2sd04LZDEkmyFoDktfHN/cZDZdLrhhXRU= =I7Yr -----END PGP SIGNATURE----- --777j0PYLacl3Y1gb--