From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:50610) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a8skj-0006ZO-MX for qemu-devel@nongnu.org; Tue, 15 Dec 2015 11:47:06 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a8skf-00034D-62 for qemu-devel@nongnu.org; Tue, 15 Dec 2015 11:47:05 -0500 Received: from mx1.redhat.com ([209.132.183.28]:54464) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a8ske-00033z-W0 for qemu-devel@nongnu.org; Tue, 15 Dec 2015 11:47:01 -0500 Received: from int-mx13.intmail.prod.int.phx2.redhat.com (int-mx13.intmail.prod.int.phx2.redhat.com [10.5.11.26]) by mx1.redhat.com (Postfix) with ESMTPS id 15884550DC for ; Tue, 15 Dec 2015 16:47:00 +0000 (UTC) References: <1450179992-15959-1-git-send-email-thuth@redhat.com> <56700CBA.5010505@redhat.com> <56703969.9050905@redhat.com> <56703E09.5000504@redhat.com> From: Eric Blake Message-ID: <567043FB.20109@redhat.com> Date: Tue, 15 Dec 2015 09:46:51 -0700 MIME-Version: 1.0 In-Reply-To: <56703E09.5000504@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="uuougmjBSDTTOlxBfMmk4OO8dW4bmDIJc" Subject: Re: [Qemu-devel] [PATCH] net: Inform the user about deprecated -net options List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini , Thomas Huth , qemu-devel@nongnu.org, Jason Wang This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --uuougmjBSDTTOlxBfMmk4OO8dW4bmDIJc Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 12/15/2015 09:21 AM, Paolo Bonzini wrote: >=20 > In fact there isn't much shared code in the is_netdev=3D0 and is_netdev= =3D1 > cases. Perhaps you could just make a shared function with just >=20 > if (net_client_init_fun[opts->type](opts, name, peer, errp) < 0) { > /* FIXME drop when all init functions store an Error */ > if (errp && !*errp) { > error_setg(errp, QERR_DEVICE_INIT_FAILED, > NetClientOptionsKind_lookup[opts->type]); > } > return -1; > } >=20 >=20 > and inline all the rest of net_client_init1, net_visit, net_client_init= > into two functions netdev_add and net_legacy_add. Then -net handling > (including HMP) can be moved into a separate file which no one looks at= =2E There's also some pending patches from qapi refactoring and from Zoltan's work towards audio unification (which spilled over into netdev refactoring), which may impact things here. For my latest version, see: http://repo.or.cz/qemu/ericb.git/shortlog/refs/heads/qapi --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --uuougmjBSDTTOlxBfMmk4OO8dW4bmDIJc Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJWcEP7AAoJEKeha0olJ0Nqo0IH+wRe1/5u/XL2BmzPvcREhrrc FLM+KNnzkEgEAZGzrcRjGNoTN2x3pTOUWM2TBo8eKI4bZhmWdU2dyCzRrK9/ryGr A4fk4nAFUI9oTWIEH8hP4cO2n+tLxGQScoZ16a2PXqfBLVm04L2FlwHtiA4C6gUq bT4TcbW5sYTXZDxRAaPjUefJkFvJYh0qqe0cvZxNAwB3ew/2Gi7T0k8c20xGDciO f3SPVZuzhxPHfwFGA6aSKkbtmAPU94piNwny6+Ft0yn95GeSCysjVBWaEOk/ur2R kFFoKWBC9pwFJNkoJuI/5walvDTSGGqXmxAwzJ3EoG6VBzapJPjBhcmU7y+Exms= =3thf -----END PGP SIGNATURE----- --uuougmjBSDTTOlxBfMmk4OO8dW4bmDIJc--