Received: from eggs.gnu.org ([2001:4830:134:3::10]:39725) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V53v0-0005Je-CR for qemu-devel@nongnu.org; Thu, 01 Aug 2013 21:12:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1V4xmx-0002RK-Sh for qemu-devel@nongnu.org; Thu, 01 Aug 2013 14:40:00 -0400 Received: from mx1.redhat.com ([209.132.183.28]:46582) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1V4tfm-0001I7-Da for qemu-devel@nongnu.org; Thu, 01 Aug 2013 10:16:10 -0400 Date: Thu, 1 Aug 2013 22:16:07 +0800 From: Amos Kong Message-ID: <20130801141607.GA25267@amosk.info> References: <1372055699-13501-1-git-send-email-akong@redhat.com> <20130626031532.GA2341@amosk.info> <87vc51i3ra.fsf@blackfin.pond.sub.org> <20130701025528.GB1946@amosk.info> <51FA630D.7050504@suse.de> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline In-Reply-To: <51FA630D.7050504@suse.de> Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH for mst/pci] output nc->name in NIC_RX_FILTER_CHANGED event List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Andreas =?iso-8859-1?Q?F=E4rber?= Cc: mst@redhat.com, Markus Armbruster , qemu-devel@nongnu.org On Thu, Aug 01, 2013 at 03:30:53PM +0200, Andreas F=E4rber wrote: > Am 01.07.2013 04:55, schrieb Amos Kong: > > On Wed, Jun 26, 2013 at 12:07:53PM +0200, Markus Armbruster wrote: > >> Amos Kong writes: > >> > >>> On Mon, Jun 24, 2013 at 02:34:59PM +0800, Amos Kong wrote: > >>>> netclient 'name' entry in event is useful for management to know > >>>> which device is changed. n->netclient_name is not always set. > >>>> This patch changes to use nc->name. If we don't assign 'id', > >>>> qemu will set a generated name to nc->name. > >>> > >>> > >>> IRC: akong, what do other events include? name or id? > >>> > >>> I just checked QMP/qmp-event.txt, they all use 'device name'. > >>> (eg: BLOCK_IO_ERROR, DEVICE_DELETED, DEVICE_TRAY_MOVED, BLOCK_JOB_*= ) > >>> > >>> If we assign 'id' for -device, device name will be set to id. > >>> Otherwise, a generated device name will set to some device. > >> > >> DEVICE_DELETED uses "device" (the qdev ID) and "path" (the QOM path). > >> > >> For reasons I don't understand, it sets "path" only when the device = has > >> no qdev ID. That should be cleaned up. > >=20 > > The path are alwasy set. > >=20 > > example: > > (have id) > > "path": "/machine/peripheral-anon/vnet0/virtio-backend" >=20 > You hopefully meant "/machine/peripheral/vnet0/virtio-backend"? > Otherwise we have a bug somewhere. =20 Just my typo in mail. // -device virtio-net-pci,netdev=3Dh1,id=3Dvnet0 -netdev tap,id=3Dh1 { "timestamp": { "seconds": 1375366321,=20 "microseconds": 595727 },=20 "event": "NIC_RX_FILTER_CHANGED",=20 "data": { "name": "vnet0",=20 "path": "/machine/peripheral/vnet0/virtio-backend" } } > Andreas >=20 > >=20 > > (no id) > > "path": "/machine/peripheral-anon/device[0]/virtio-backend" > >=20 > > It's enough to just use path to distinguish the changed device. > > So we ignore this patch. > >=20 >=20 >=20 > --=20 > SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 N=FCrnberg, Germany > GF: Jeff Hawn, Jennifer Guild, Felix Imend=F6rffer; HRB 16746 AG N=FCrn= berg --=20 Amos.