From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gandalf.ozlabs.org (gandalf.ozlabs.org [150.107.74.76]) by passt.top (Postfix) with ESMTPS id D9C975A0289 for ; Tue, 16 May 2023 06:06:58 +0200 (CEST) Received: by gandalf.ozlabs.org (Postfix, from userid 1007) id 4QL2k461DYz4x4F; Tue, 16 May 2023 14:06:52 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gibson.dropbear.id.au; s=201602; t=1684210012; bh=zRE/EJPQAGvPFsD9Hy26kZHDIe8hcZuBNB37n5sXtGw=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=H1PwTkP4j6+PgFcS010vqxFZGYQeZhedwhTTADGZRjS2IijfnGmhn7SYS7TuNCIqA VrtDSvZY+eXALHxZBbO9ub4klwwEEkUWEzKVHS/IbbJQRKFgw7qmGSpBjxvktGd3/B sItqiMbJ0dMW6ux9a/giD7cfdESnUKmXOFXQWKTU= Date: Tue, 16 May 2023 13:59:03 +1000 From: David Gibson To: Stefano Brivio Subject: Re: [PATCH 04/10] conf: --config-net option is for pasta mode only Message-ID: References: <20230514181415.313420-1-sbrivio@redhat.com> <20230514181415.313420-5-sbrivio@redhat.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="T9/Isb9HlDoQ5XNp" Content-Disposition: inline In-Reply-To: <20230514181415.313420-5-sbrivio@redhat.com> Message-ID-Hash: TIIIIFMLJWPBGZ5A4WC5IBVY565VP2MA X-Message-ID-Hash: TIIIIFMLJWPBGZ5A4WC5IBVY565VP2MA 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, Callum Parsey , me@yawnt.com, lemmi@nerd2nerd.org 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: --T9/Isb9HlDoQ5XNp Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, May 14, 2023 at 08:14:09PM +0200, Stefano Brivio wrote: > Reported-by: Andrea Arcangeli > Signed-off-by: Stefano Brivio Reviewed-by: David Gibson Also makes sense regardless of the rest of the series. > --- > conf.c | 8 +++++++- > 1 file changed, 7 insertions(+), 1 deletion(-) >=20 > diff --git a/conf.c b/conf.c > index aad2b00..bc1ae99 100644 > --- a/conf.c > +++ b/conf.c > @@ -1198,7 +1198,6 @@ void conf(struct ctx *c, int argc, char **argv) > {"userns", required_argument, NULL, 2 }, > {"netns", required_argument, NULL, 3 }, > {"netns-only", no_argument, &netns_only, 1 }, > - {"config-net", no_argument, &c->pasta_conf_ns, 1 }, > {"ns-mac-addr", required_argument, NULL, 4 }, > {"dhcp-dns", no_argument, NULL, 5 }, > {"no-dhcp-dns", no_argument, NULL, 6 }, > @@ -1212,6 +1211,7 @@ void conf(struct ctx *c, int argc, char **argv) > {"version", no_argument, NULL, 14 }, > {"outbound-if4", required_argument, NULL, 15 }, > {"outbound-if6", required_argument, NULL, 16 }, > + {"config-net", no_argument, NULL, 17 }, > { 0 }, > }; > struct get_bound_ports_ns_arg ns_ports_arg =3D { .c =3D c }; > @@ -1369,6 +1369,12 @@ void conf(struct ctx *c, int argc, char **argv) > if (ret <=3D 0 || ret >=3D (int)sizeof(c->ip6.ifname_out)) > die("Invalid interface name: %s", optarg); > =20 > + break; > + case 17: > + if (c->mode !=3D MODE_PASTA) > + die("--config-net is for pasta mode only"); > + > + c->pasta_conf_ns =3D 1; > break; > case 'd': > if (c->debug) --=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 --T9/Isb9HlDoQ5XNp Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEO+dNsU4E3yXUXRK2zQJF27ox2GcFAmRi/4EACgkQzQJF27ox 2Gflkg//curnwVazhuFy8+VB5jNqCWwoUIoX7HjujVOAJGeFcHvG7fX4Mta6OMIX 90q+d+fSaf0XfiZ/zfVinuj2O99wBeEYyxNFdLqhgzoO+zhTxo69Ut5H/vMyxPmG w5xovxQW+rZ02+De9EU8DiTd2WDhzFNs4V8zXuLL4x0UbP93qW/bkaTsmNySOn7/ OtWFX7ZGWuJ4LLwtK46EP/1hnPaE+y6ZDs1oVRjdaFbWAIxF+tCRYz+nOWnNYrdI 3ne51PQT+Wok6YafZw5Tg1eLI4ub5Va4Dn0JelNPGLXL7tXwY/IchE1Wa7B9BJJk RCdr87TCi02dghMtgN1SvDfB5nvAv34FJJ63EbUfr85XI5NAp4rA2h148kz0h2Zs MDGrR9q3+e5fzG5RePjIbgj0+ZYiBLYaTAhwJyBZTTzAR1nu2b3V1BIkAoWanv7E RX0b+FGnd/NcOaTzfCsh7XFf7F6XCqJn6IKjsmNEviUtCtpKp8U2ki6bAOkEOkiW j+HUR2VhQJefbyGVGh8wtLsEZSS4Lj2eAMdDimaeOH5sye//1QMgMPuVy2wq1WD8 tMXlvf7oWCPW4tMZ1AYm9aL98O4rYA+AKpR2CotyB5aET7r41fVAbU3M9j88IVMh pE2VmPyZe28wMvJ1mU7a1AEtUysA3QOEtYJJi2dxlO7tUec2c8M= =OlFI -----END PGP SIGNATURE----- --T9/Isb9HlDoQ5XNp--