From: Paolo Bonzini <pbonzini@redhat.com>
To: Laszlo Ersek <lersek@redhat.com>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH 06/16] qapi schema: add Netdev types
Date: Tue, 05 Jun 2012 23:08:01 +0200 [thread overview]
Message-ID: <4FCE7531.9090807@redhat.com> (raw)
In-Reply-To: <1337683555-13301-7-git-send-email-lersek@redhat.com>
Il 22/05/2012 12:45, Laszlo Ersek ha scritto:
> NetdevTapOptions::sndbuf and NetdevDumpOptions::len use the new "size"
> type.
>
> Signed-off-by: Laszlo Ersek <lersek@redhat.com>
> ---
> qapi-schema.json | 275 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
> 1 files changed, 275 insertions(+), 0 deletions(-)
>
> diff --git a/qapi-schema.json b/qapi-schema.json
> index a8b3803..fae2596 100644
> --- a/qapi-schema.json
> +++ b/qapi-schema.json
> @@ -1840,3 +1840,278 @@
> # Since: 0.14.0
> ##
> { 'command': 'netdev_del', 'data': {'id': 'str'} }
> +
> +##
> +# @NetdevNoneOptions
> +#
> +# Use it alone to have zero network devices.
> +#
> +# Since 1.2
> +##
> +{ 'type': 'NetdevNoneOptions',
> + 'data': { } }
> +
> +##
> +# @NetLegacyNicOptions
> +#
> +# Create a new Network Interface Card.
> +#
> +# @netdev: #optional id of -netdev to connect to
> +#
> +# @macaddr: #optional MAC address
> +#
> +# @model: #optional device model (e1000, rtl8139, virtio etc.)
> +#
> +# @addr: #optional PCI device address
> +#
> +# @vectors: #optional number of MSI-x vectors, 0 to disable MSI-X
> +#
> +# Since 1.2
> +##
> +{ 'type': 'NetLegacyNicOptions',
> + 'data': {
> + '*netdev': 'str',
> + '*macaddr': 'str',
> + '*model': 'str',
> + '*addr': 'str',
> + '*vectors': 'int' } }
> +
> +##
> +# @String
> +#
> +# A fat type wrapping 'str', to be embedded in lists.
> +#
> +# Since 1.2
> +##
> +{ 'type': 'String',
> + 'data': {
> + 'str': 'str' } }
> +
> +##
> +# @NetdevUserOptions
> +#
> +# Use the user mode network stack which requires no administrator privilege to
> +# run.
> +#
> +# @hostname: #optional client hostname reported by the builtin DHCP server
> +#
> +# @restrict: #optional isolate the guest from the host
> +#
> +# @ip: #optional legacy parameter, use net= instead
> +#
> +# @net: #optional IP address and optional netmask
> +#
> +# @host: #optional guest-visible address of the host
> +#
> +# @tftp: #optional root directory of the built-in TFTP server
> +#
> +# @bootfile: #optional BOOTP filename, for use with tftp=
> +#
> +# @dhcpstart: #optional the first of the 16 IPs the built-in DHCP server can
> +# assign
> +#
> +# @dns: #optional guest-visible address of the virtual nameserver
> +#
> +# @smb: #optional root directory of the built-in SMB server
> +#
> +# @smbserver: #optional IP address of the built-in SMB server
> +#
> +# @hostfwd: #optional redirect incoming TCP or UDP host connections to guest
> +# endpoints
> +#
> +# @guestfwd: #optional forward guest TCP connections
> +#
> +# Since 1.2
> +##
> +{ 'type': 'NetdevUserOptions',
> + 'data': {
> + '*hostname': 'str',
> + '*restrict': 'bool',
> + '*ip': 'str',
> + '*net': 'str',
> + '*host': 'str',
> + '*tftp': 'str',
> + '*bootfile': 'str',
> + '*dhcpstart': 'str',
> + '*dns': 'str',
> + '*smb': 'str',
> + '*smbserver': 'str',
> + '*hostfwd': ['String'],
> + '*guestfwd': ['String'] } }
> +
> +##
> +# @NetdevTapOptions
> +#
> +# Connect the host TAP network interface name to the VLAN.
> +#
> +# @ifname: #optional interface name
> +#
> +# @fd: #optional file descriptor of an already opened tap
> +#
> +# @script: #optional script to initialize the interface
> +#
> +# @downscript: #optional script to shut down the interface
> +#
> +# @helper: #optional command to execute to configure bridge
> +#
> +# @sndbuf: #optional send buffer limit. Understands [TGMKkb] suffixes.
> +#
> +# @vnet_hdr: #optional enable the IFF_VNET_HDR flag on the tap interface
> +#
> +# @vhost: #optional enable vhost-net network accelerator
> +#
> +# @vhostfd: #optional file descriptor of an already opened vhost net device
> +#
> +# @vhostforce: #optional vhost on for non-MSIX virtio guests
> +#
> +# Since 1.2
> +##
> +{ 'type': 'NetdevTapOptions',
> + 'data': {
> + '*ifname': 'str',
> + '*fd': 'str',
> + '*script': 'str',
> + '*downscript': 'str',
> + '*helper': 'str',
> + '*sndbuf': 'size',
> + '*vnet_hdr': 'bool',
> + '*vhost': 'bool',
> + '*vhostfd': 'str',
> + '*vhostforce': 'bool' } }
> +
> +##
> +# @NetdevSocketOptions
> +#
> +# Connect the VLAN to a remote VLAN in another QEMU virtual machine using a TCP
> +# socket connection.
> +#
> +# @fd: #optional file descriptor of an already opened socket
> +#
> +# @listen: #optional port number, and optional hostname, to listen on
> +#
> +# @connect: #optional port number, and optional hostname, to connect to
> +#
> +# @mcast: #optional UDP multicast address and port number
> +#
> +# @localaddr: #optional source address and port for multicast and udp packets
> +#
> +# @udp: #optional UDP unicast address and port number
> +#
> +# Since 1.2
> +##
> +{ 'type': 'NetdevSocketOptions',
> + 'data': {
> + '*fd': 'str',
> + '*listen': 'str',
> + '*connect': 'str',
> + '*mcast': 'str',
> + '*localaddr': 'str',
> + '*udp': 'str' } }
> +
> +##
> +# @NetdevVdeOptions
> +#
> +# Connect the VLAN to a vde switch running on the host.
> +#
> +# @sock: #optional socket path
> +#
> +# @port: #optional port number
> +#
> +# @group: #optional group owner of socket
> +#
> +# @mode: #optional permissions for socket
> +#
> +# Since 1.2
> +##
> +{ 'type': 'NetdevVdeOptions',
> + 'data': {
> + '*sock': 'str',
> + '*port': 'int',
> + '*group': 'str',
> + '*mode': 'int' } }
> +
> +##
> +# @NetdevDumpOptions
> +#
> +# Dump VLAN network traffic to a file.
> +#
> +# @len: #optional per-packet size limit (64k default). Understands [TGMKkb]
> +# suffixes.
> +#
> +# @file: #optional dump file path (default is qemu-vlan0.pcap)
> +#
> +# Since 1.2
> +##
> +{ 'type': 'NetdevDumpOptions',
> + 'data': {
> + '*len': 'size',
> + '*file': 'str' } }
> +
> +##
> +# @NetdevBridgeOptions
> +#
> +# Connect a host TAP network interface to a host bridge device.
> +#
> +# @br: #optional bridge name
> +#
> +# @helper: #optional command to execute to configure bridge
> +#
> +# Since 1.2
> +##
> +{ 'type': 'NetdevBridgeOptions',
> + 'data': {
> + '*br': 'str',
> + '*helper': 'str' } }
> +
> +##
> +# @NetClientOptions
> +#
> +# A discriminated record of network device traits.
> +#
> +# Since 1.2
> +##
> +{ 'union': 'NetClientOptions',
> + 'data': {
> + 'none': 'NetdevNoneOptions',
> + 'nic': 'NetLegacyNicOptions',
> + 'user': 'NetdevUserOptions',
> + 'tap': 'NetdevTapOptions',
> + 'socket': 'NetdevSocketOptions',
> + 'vde': 'NetdevVdeOptions',
> + 'dump': 'NetdevDumpOptions',
> + 'bridge': 'NetdevBridgeOptions' } }
> +
> +##
> +# @NetLegacy
> +#
> +# Captures the configuration of a network device; legacy.
> +#
> +# @vlan: #optional vlan number
> +#
> +# @name: #optional identifier for monitor commands
Optional?
> +# @traits: device type specific properties (legacy)
> +#
> +# Since 1.2
> +##
> +{ 'type': 'NetLegacy',
> + 'data': {
> + '*vlan': 'int',
> + 'name': 'str',
Or mandatory? :)
> + 'opts': 'NetClientOptions' } }
> +
> +##
> +# @Netdev
> +#
> +# Captures the configuration of a network device.
> +#
> +# @id: identifier for monitor commands.
> +#
> +# @traits: device type specific properties
> +#
> +# Since 1.2
> +##
> +{ 'type': 'Netdev',
> + 'data': {
> + 'id': 'str',
> + 'opts': 'NetClientOptions' } }
Otherwise looks good.
Paolo
next prev parent reply other threads:[~2012-06-05 21:08 UTC|newest]
Thread overview: 63+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-22 10:45 [Qemu-devel] [PATCH 00/16] introduce OptsVisitor, rebase -net/-netdev parsing Laszlo Ersek
2012-05-22 10:45 ` [Qemu-devel] [PATCH 01/16] qapi: fix error propagation Laszlo Ersek
2012-05-22 10:45 ` [Qemu-devel] [PATCH 02/16] qapi: introduce "size" type Laszlo Ersek
2012-06-05 20:39 ` Paolo Bonzini
2012-05-22 10:45 ` [Qemu-devel] [PATCH 03/16] expose QemuOpt and QemuOpts struct definitions to interested parties Laszlo Ersek
2012-06-05 20:40 ` Paolo Bonzini
2012-05-22 10:45 ` [Qemu-devel] [PATCH 04/16] qapi: introduce OptsVisitor Laszlo Ersek
2012-06-05 21:12 ` Paolo Bonzini
2012-06-06 11:12 ` Laszlo Ersek
2012-06-06 12:02 ` Paolo Bonzini
2012-05-22 10:45 ` [Qemu-devel] [PATCH 05/16] qapi schema: remove trailing whitespace Laszlo Ersek
2012-06-05 20:40 ` Paolo Bonzini
2012-05-22 10:45 ` [Qemu-devel] [PATCH 06/16] qapi schema: add Netdev types Laszlo Ersek
2012-06-05 21:08 ` Paolo Bonzini [this message]
2012-05-22 10:45 ` [Qemu-devel] [PATCH 07/16] hw, net: "net_client_type" -> "NetClientOptionsKind" (qapi-generated) Laszlo Ersek
2012-06-05 20:41 ` Paolo Bonzini
2012-05-22 10:45 ` [Qemu-devel] [PATCH 08/16] convert net_client_init() to OptsVisitor Laszlo Ersek
2012-06-05 20:46 ` Paolo Bonzini
2012-06-05 21:07 ` Paolo Bonzini
2012-05-22 10:45 ` [Qemu-devel] [PATCH 09/16] convert net_init_nic() to NetClientOptions Laszlo Ersek
2012-06-05 20:50 ` Paolo Bonzini
2012-05-22 10:45 ` [Qemu-devel] [PATCH 10/16] convert net_init_dump() " Laszlo Ersek
2012-06-05 20:51 ` Paolo Bonzini
2012-05-22 10:45 ` [Qemu-devel] [PATCH 11/16] convert net_init_slirp() " Laszlo Ersek
2012-06-05 20:53 ` Paolo Bonzini
2012-05-22 10:45 ` [Qemu-devel] [PATCH 12/16] convert net_init_socket() " Laszlo Ersek
2012-06-05 21:02 ` Paolo Bonzini
2012-06-05 21:14 ` Eric Blake
2012-06-05 21:27 ` Paolo Bonzini
2012-05-22 10:45 ` [Qemu-devel] [PATCH 13/16] convert net_init_vde() " Laszlo Ersek
2012-06-05 21:04 ` Paolo Bonzini
2012-05-22 10:45 ` [Qemu-devel] [PATCH 14/16] convert net_init_tap() " Laszlo Ersek
2012-05-22 10:45 ` [Qemu-devel] [PATCH 15/16] convert net_init_bridge() " Laszlo Ersek
2012-06-05 21:05 ` Paolo Bonzini
2012-06-06 12:16 ` Laszlo Ersek
2012-06-06 14:13 ` Paolo Bonzini
2012-05-22 10:45 ` [Qemu-devel] [PATCH 16/16] remove unused QemuOpts parameter from net init functions Laszlo Ersek
2012-06-05 21:06 ` Paolo Bonzini
2012-06-05 21:13 ` [Qemu-devel] [PATCH 00/16] introduce OptsVisitor, rebase -net/-netdev parsing Paolo Bonzini
2012-06-06 13:03 ` Laszlo Ersek
2012-06-06 13:31 ` Andreas Färber
2012-06-06 14:10 ` Paolo Bonzini
2012-06-06 14:34 ` Andreas Färber
2012-06-06 14:43 ` Paolo Bonzini
2012-06-06 15:16 ` Michael Roth
2012-06-06 15:30 ` Laszlo Ersek
2012-06-06 15:58 ` Michael Roth
2012-06-06 16:14 ` Michael Roth
2012-06-06 16:47 ` Paolo Bonzini
2012-06-06 16:49 ` Laszlo Ersek
2012-06-06 17:05 ` Laszlo Ersek
2012-06-06 20:09 ` Michael Roth
2012-06-06 20:59 ` Andreas Färber
2012-06-07 11:32 ` Laszlo Ersek
2012-06-07 12:17 ` Andreas Färber
2012-06-07 11:29 ` Laszlo Ersek
2012-06-07 15:29 ` Michael Roth
2012-06-07 15:46 ` Paolo Bonzini
2012-06-09 11:21 ` Laszlo Ersek
2012-06-06 15:31 ` Michael Roth
2012-06-06 14:09 ` Paolo Bonzini
2012-06-09 15:30 ` Laszlo Ersek
2012-06-11 7:06 ` Paolo Bonzini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4FCE7531.9090807@redhat.com \
--to=pbonzini@redhat.com \
--cc=lersek@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).