From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=32813 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OPizp-0006Vq-5B for qemu-devel@nongnu.org; Fri, 18 Jun 2010 17:21:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OPizo-0003WU-3Z for qemu-devel@nongnu.org; Fri, 18 Jun 2010 17:21:05 -0400 Received: from mail-yw0-f198.google.com ([209.85.211.198]:62637) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OPizn-0003WM-VH for qemu-devel@nongnu.org; Fri, 18 Jun 2010 17:21:04 -0400 Received: by ywh36 with SMTP id 36so1217675ywh.4 for ; Fri, 18 Jun 2010 14:21:03 -0700 (PDT) Message-ID: <4C1BE338.5010709@codemonkey.ws> Date: Fri, 18 Jun 2010 16:20:56 -0500 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH v2] QMP: Introduce the documentation for query-netdev and info netdev References: <1276878387-9489-1-git-send-email-miguel.filho@gmail.com> <4C1BD6FA.7020502@codemonkey.ws> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Miguel Di Ciurcio Filho Cc: avi@redhat.com, lcapitulino@redhat.com, qemu-devel@nongnu.org, armbru@redhat.com On 06/18/2010 04:15 PM, Miguel Di Ciurcio Filho wrote: > On Fri, Jun 18, 2010 at 5:28 PM, Anthony Liguori wrote: > >> On 06/18/2010 11:26 AM, Miguel Di Ciurcio Filho wrote: >> >>> These commands show the information about active backend network devices. >>> >>> Signed-off-by: Miguel Di Ciurcio Filho >>> --- >>> qemu-monitor.hx | 105 >>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++ >>> 1 files changed, 105 insertions(+), 0 deletions(-) >>> >>> diff --git a/qemu-monitor.hx b/qemu-monitor.hx >>> index 9f62b94..8fc5ed6 100644 >>> --- a/qemu-monitor.hx >>> +++ b/qemu-monitor.hx >>> @@ -1674,6 +1674,111 @@ show the various VLANs and the associated devices >>> ETEXI >>> >>> STEXI >>> +@item info netdev >>> +show information about the current backend network devices >>> +ETEXI >>> +SQMP >>> +query-netdev >>> +------------ >>> + >>> +Each device is represented by a json-object. The returned value is a >>> json-array >>> +of all devices. >>> + >>> +Each json-object contains the following: >>> + >>> +- "id": the device's ID, must be unique (json-string) >>> +- "type": device type (json-string) >>> + - Possible values: "tap", "user", "vde", "socket" >>> +- "vlan": QEMU's internal vlan identification. Only present if the device >>> is >>> + attached to a VLAN (json-int, optional) >>> +- "peer": ID of the frontend device when on a 1:1 relationship >>> (json-string, >>> + optional) >>> >>> >> I think we should only return items with a valid peer property and drop >> anything attached to vlans. The current info network already provides vlan >> information. >> >> > We need a strong compromise that sometime in the future, the qemu > "vlan" concept will be removed, deprecated, or something like that. > Otherwise we will end up with QMP not exporting networking > configuration that can be setup by a user or management software. > One way or another, vlan will go away in the form it exists today. I'm not sure how we're going to replace it yet but the notion that every device is always connected to a hub is not something that we can reasonably live with. netdev has already killed it. TBH, I don't think netdev should have a vlan tag. In fact, I think a patch to remove that from the user interface would be a very good thing. Regards, Anthony Liguori