diff options
author | xiaoqiang zhao | 2020-05-16 05:13:25 +0200 |
---|---|---|
committer | Daniel P. Berrangé | 2020-05-20 11:34:40 +0200 |
commit | 776b97d3605ed0fc94443048fdf988c7725e38a9 (patch) | |
tree | 2d8f731e49c1900ccb7c7f4e1e63d6a9c3590125 /qapi/sockets.json | |
parent | Merge remote-tracking branch 'remotes/stefanha/tags/block-pull-request' into ... (diff) | |
download | qemu-776b97d3605ed0fc94443048fdf988c7725e38a9.tar.gz qemu-776b97d3605ed0fc94443048fdf988c7725e38a9.tar.xz qemu-776b97d3605ed0fc94443048fdf988c7725e38a9.zip |
qemu-sockets: add abstract UNIX domain socket support
unix_listen/connect_saddr now support abstract address types
two aditional BOOL switches are introduced:
tight: whether to set @addrlen to the minimal string length,
or the maximum sun_path length. default is TRUE
abstract: whether we use abstract address. default is FALSE
cli example:
-monitor unix:/tmp/unix.socket,abstract,tight=off
OR
-chardev socket,path=/tmp/unix.socket,id=unix1,abstract,tight=on
Signed-off-by: xiaoqiang zhao <zxq_yx_007@163.com>
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Diffstat (limited to 'qapi/sockets.json')
-rw-r--r-- | qapi/sockets.json | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/qapi/sockets.json b/qapi/sockets.json index ea933ed4b2..cbd6ef35d0 100644 --- a/qapi/sockets.json +++ b/qapi/sockets.json @@ -73,12 +73,18 @@ # Captures a socket address in the local ("Unix socket") namespace. # # @path: filesystem path to use +# @tight: pass a socket address length confined to the minimum length of the +# abstract string, rather than the full sockaddr_un record length +# (only matters for abstract sockets, default true). (Since 5.1) +# @abstract: whether this is an abstract address, default false. (Since 5.1) # # Since: 1.3 ## { 'struct': 'UnixSocketAddress', 'data': { - 'path': 'str' } } + 'path': 'str', + '*tight': 'bool', + '*abstract': 'bool' } } ## # @VsockSocketAddress: |