]> git.proxmox.com Git - mirror_qemu.git/commit - block/monitor/block-hmp-cmds.c
block/export: Add node-name to BlockExportOptions
authorKevin Wolf <kwolf@redhat.com>
Thu, 24 Sep 2020 15:27:01 +0000 (17:27 +0200)
committerKevin Wolf <kwolf@redhat.com>
Fri, 2 Oct 2020 13:46:40 +0000 (15:46 +0200)
commitb6076afcabc7a3947d0b212b956f4575e6795c56
tree08a52b07e0496abdcaff8e3ee7a1db1cd7e41aba
parent8612c6867341e52416e63fce8b19ede8501c159a
block/export: Add node-name to BlockExportOptions

Every block export needs a block node to export, so add a 'node-name'
option to BlockExportOptions and remove the replaced option 'device'
from BlockExportOptionsNbd.

To maintain compatibility in nbd-server-add, BlockExportOptionsNbd needs
to be wrapped by a new type NbdServerAddOptions that adds 'device' back
because nbd-server-add doesn't use the BlockExportOptions base type at
all (so even without changing it to a 'node-name' option in
block-export-add, this compatibility code would be necessary).

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Message-Id: <20200924152717.287415-16-kwolf@redhat.com>
Acked-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
block/monitor/block-hmp-cmds.c
blockdev-nbd.c
qapi/block-export.json
qemu-nbd.c