From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:46743) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UfrXG-00011M-LN for qemu-devel@nongnu.org; Fri, 24 May 2013 08:56:00 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UfrX9-0002eM-Qx for qemu-devel@nongnu.org; Fri, 24 May 2013 08:55:54 -0400 Received: from mx1.redhat.com ([209.132.183.28]:39654) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UfrX9-0002e8-J5 for qemu-devel@nongnu.org; Fri, 24 May 2013 08:55:47 -0400 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r4OCtk97020125 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Fri, 24 May 2013 08:55:46 -0400 Message-ID: <519F6350.1040502@redhat.com> Date: Fri, 24 May 2013 06:55:44 -0600 From: Eric Blake MIME-Version: 1.0 References: <1369300080-31377-1-git-send-email-akong@redhat.com> <1369300080-31377-3-git-send-email-akong@redhat.com> <20130523120325.3113c687@redhat.com> <20130524030813.GB1550@t430s.nay.redhat.com> <20130524082326.452cc9f0@redhat.com> In-Reply-To: <20130524082326.452cc9f0@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="----enig2QKSDOITTIMMLSTKESWGB" Subject: Re: [Qemu-devel] [PATCH v3 2/2] net: introduce command to query rx-filter information List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Luiz Capitulino Cc: Amos Kong , qemu-devel@nongnu.org, stefanha@redhat.com, mst@redhat.com This is an OpenPGP/MIME signed message (RFC 4880 and 3156) ------enig2QKSDOITTIMMLSTKESWGB Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 05/24/2013 06:23 AM, Luiz Capitulino wrote: >>> I don't think we need this argument. This command is quite simple in = its >>> response, let's do this filtering in HMP only. >> >> Event message contains the net client name, management might only want= >> to query the single net client. >=20 > The client can do the filtering itself. If we're arguing that we want this to be as responsive as possible, then the less data we send over the wire, the faster management can react to the guest's request for a particular NIC. That is, if libvirt is listening to events that says NIC2 wants to change rx-filter, libvirt would rather do a filtered query where it knows the JSON array of 1 element matches NIC2 data, rather than do a global query and search through the returned array until it finds NIC2. Filtering is relatively easy to add, whether you do it in QMP or make every client add it. Libvirt will survive if you don't have filtering, but I don't see why we can't have it in QMP. Also, if you DO decide to rip filtering out of QMP, you STILL need to keep a per-NIC flag. Since the events say which NIC is requesting a change, even if the query reads all nics, libvirt will only change the macvtap settings of the nic(s) for which it has received an event (it doesn't make sense to waste time requesting a (no-op) change to macvtap settings on a nic that hasn't requested a change). But if you argue that having no filtering in the QMP command means that you can get away with a single flag instead of a per-nic flag, then you will fail to emit an event for NIC2 if it changes in between the time that NIC1 fired an event and libvirt finally does the query, and libvirt wouldn't realize that NIC2 also needs a macvtap change. --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org ------enig2QKSDOITTIMMLSTKESWGB Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.13 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJRn2NQAAoJEKeha0olJ0NqoAwH/i+zqXOfhoC8k3bk2bBCbU/U ZnT2OMYZUzVTzN1k4Mk77hfWQh4U8+uGVv1d6z2aPKe/qY2KC+TQZ/yarQziecY5 y3HsR8Rz0BiQjWBw/eGtLIM9mR3l8XookmWBFgvA9PT7TfJxBorpnmcQ9PNOMJwE b8FDPQHEqrBXNUqrZ8fPiASK35uaZPFf3oASAkqS4UHDPmXbjs9vFMSj1Hk1n3Ef C61dsEhMMz8BGAcQjOQmAXzB44zFTHgsCRLGqDx1dmutVm81P3FGjXM0XFDemRWv 9jk7cDkQ176ap4l4aIeS7gbqrbf51N81lhmYdbTI7rFkDxBdldwUhTdeBg0SmHU= =ZHnt -----END PGP SIGNATURE----- ------enig2QKSDOITTIMMLSTKESWGB--