From 993b301e77e28d43023c1154f5b8765a83b38270 Mon Sep 17 00:00:00 2001 Message-Id: <993b301e77e28d43023c1154f5b8765a83b38270.1374754301.git.minovotn@redhat.com> In-Reply-To: <5d75a8513d08b33975bdf5971871c0c977167cd1.1374754301.git.minovotn@redhat.com> References: <5d75a8513d08b33975bdf5971871c0c977167cd1.1374754301.git.minovotn@redhat.com> From: Gerd Hoffmann Date: Mon, 24 Jun 2013 07:05:21 +0200 Subject: [PATCH 10/65] qapi: add socket address types RH-Author: Gerd Hoffmann Message-id: <1372057576-26450-11-git-send-email-kraxel@redhat.com> Patchwork-id: 52126 O-Subject: [RHEL-6.5 qemu-kvm PATCH v2 10/65] qapi: add socket address types Bugzilla: 676568 RH-Acked-by: Laszlo Ersek RH-Acked-by: Hans de Goede RH-Acked-by: Luiz Capitulino From: Paolo Bonzini Acked-by: Luiz Capitulino Signed-off-by: Paolo Bonzini (cherry picked from commit 5be8c759f008947514fbf7d8df9a30eebe496b6d) Conflicts: qapi-schema.json --- qapi-schema.json | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) Signed-off-by: Michal Novotny --- qapi-schema.json | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) diff --git a/qapi-schema.json b/qapi-schema.json index b413400..9ea8977 100644 --- a/qapi-schema.json +++ b/qapi-schema.json @@ -355,3 +355,56 @@ 'data': { 'str': 'str' } } +## +# @InetSocketAddress +# +# Captures a socket address or address range in the Internet namespace. +# +# @host: host part of the address +# +# @port: port part of the address, or lowest port if @to is present +# +# @to: highest port to try +# +# @ipv4: whether to accept IPv4 addresses, default try both IPv4 and IPv6 +# #optional +# +# @ipv6: whether to accept IPv6 addresses, default try both IPv4 and IPv6 +# #optional +# +# Since 1.3 +## +{ 'type': 'InetSocketAddress', + 'data': { + 'host': 'str', + 'port': 'str', + '*to': 'uint16', + '*ipv4': 'bool', + '*ipv6': 'bool' } } + +## +# @UnixSocketAddress +# +# Captures a socket address in the local ("Unix socket") namespace. +# +# @path: filesystem path to use +# +# Since 1.3 +## +{ 'type': 'UnixSocketAddress', + 'data': { + 'path': 'str' } } + +## +# @SocketAddress +# +# Captures the address of a socket, which could also be a named file descriptor +# +# Since 1.3 +## +{ 'union': 'SocketAddress', + 'data': { + 'inet': 'InetSocketAddress', + 'unix': 'UnixSocketAddress', + 'fd': 'String' } } + -- 1.7.11.7