Make qemu-img/qemu-nbd/qemu-io CLI more flexible
Status from this message: Thanks, applied to the block branch.
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v7 Latest8 patches 1 replyApplied
- v6 posting 2/210 patches 9 repliesApplied
- v6 posting 1/216 patches 6 repliesApplied
Earlier versions · 8
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v5 posting 2/2 | 16 patches | 2 replies | Superseded | |
| v5 posting 1/2 | 10 patches | 19 replies | Superseded | |
| v4 posting 2/2 | 10 patches | 8 replies | Superseded | |
| v4 posting 1/2 | 14 patches | 1 reply | Superseded | |
| v3 posting 2/2 | 13 patches | 9 replies | Superseded | |
| v3 posting 1/2 | 10 patches | 1 reply | Superseded | |
| v2 | 15 patches | 1 reply | Superseded | |
| v1 | 15 patches | 7 replies | Superseded |
Changes in v7 from the cover letter
- Rebase to resolve conflicts vs recent NBD patches
Patches in v7 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/8 | qemu-io: add support for --object command line argqemu-io.c | +34 | 0 replies | |
| 2/8 | qemu-img: add support for --object command line argqemu-img-cmds.hx qemu-img.c qemu-img.texi | +282 | 0 replies | |
| 3/8 | qemu-io: allow specifying image as a set of options argsqemu-io.c | +51 | 0 replies | |
| 4/8 | qemu-nbd: allow specifying image as a set of options argsqemu-nbd.c qemu-nbd.texi | +44 | 0 replies | |
| 5/8 | qemu-img: allow specifying image as a set of options argsqemu-img-cmds.hx qemu-img.c qemu-img.texi | +195 | 0 replies | |
| 6/8 | qemu-nbd: don't overlap long option values with short optionsqemu-nbd.c | +7 | 0 replies | |
| 7/8 | qemu-nbd: use no_argument/required_argument constantsqemu-nbd.c | +26 | 0 replies | |
| 8/8 | qemu-io: use no_argument/required_argument constantsqemu-io.c | +15 | 0 replies |
Reviews trailers per patch
5 of 8 patches have a Reviewed-by or Acked-by.
| Patch | Eric Blake |
|---|---|
| 1/8 | R-b |
| 2/8 | R-b |
| 3/8 | |
| 4/8 | |
| 5/8 | |
| 6/8 | R-b |
| 7/8 | R-b |
| 8/8 | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [Qemu-devel] [PATCH v7 0/8] Make qemu-img/qemu-nbd/qemu-io CLI more flexible
This series of patches expands the syntax of the qemu-img, qemu-nbd and qemu-io commands to make them more flexible.
v0: https://lists.gnu.org/archive/html/qemu-devel/2015-10/msg04365.html
v1: https://lists.gnu.org/archive/html/qemu-devel/2015-12/msg04014.html
v2: https://lists.gnu.org/archive/html/qemu-devel/2015-12/msg04354.html
v3: https://lists.gnu.org/archive/html/qemu-devel/2016-01/msg03381.html
v4: https://lists.gnu.org/archive/html/qemu-devel/2016-01/msg04984.html
v5: https://lists.gnu.org/archive/html/qemu-block/2016-02/msg00022.html
v6: https://lists.gnu.org/archive/html/qemu-devel/2016-02/msg03141.html
First all three gain a --object parameter, which allows instantiation of user creatable object types. The immediate use case is to allow for creation of the 'secret' object type to pass passwords for curl, iscsi and rbd drivers. For qemu-nbd this will also be needed to create TLS certificates for encryption support.
Then all three gain a '--image-opts' parameter which causes the positional filenames to be interepreted as option strings rather tha nplain filenames. This avoids the need to use the JSON syntax, or to add custom CLI args for each block backend option that exists. The immediate use case is to allow the user to specify the ID of the 'secret' object they just created.
Finally, there are a few small cleanup patches
NB, this series will conflict with my series adding TLS support to NBD. After one of the series wins the race to merge, I will rebase the other series. I don't mind which merges first really, but the sooner the better considering the forthcoming soft-freeze and that this is a dep for several other patch series.
Changed in v7:
- Rebase to resolve conflicts vs recent NBD patches
Changed in v6:
- Add missing docs of --image-opts for qemu-nbd man page (Eric)
- Remove left over special casing of 'file' in QemuOpts (Kevin)
- Pass NULL to getopt_long when optionindex is not needed (Eric)
- Misc typos in qemu-img docs (Eric)
- Fix qemu-io logic error checking argv/argc opt bounds (Eric)
- Ensure 'id' is passed into blk_open in qemu-img (Kevin)
- Share code for doing block dev passwd prompting
Changed in v5:
- Move more common object creation code into qom/ (Kevin)
- Add missing @var{} syntax in CLI help definition (Kevin)
- Declare QemuOpts closer to time of use (Kevin)
- Directly reference registered opts instead of calling qemu_find_opts (Kevin)
- Use consistent exit/return/goto pattern in qemu-img (Kevin)
- Remove special casing of 'file' in QemuOpts handling for bdrv_open (Kevin)
- Split file file opening code out into separate method (Kevin)
Changed in v4:
- Fix error reporting when object_create fails
Changed in v3:
- Rebase to resolve with conflicts against recently merged code
- Remove use of errx()
Changed in v2:
- Share more common code in qom/object_interfaces.c to avoid duplicating so much of 'object_create' in each command
- Remove previously added '--source optstring' parameter which replaced the positional filenames, in favour of keeping the positional filenames but using a --image-opts boolean arg to change their interpretation
- Added docs for --image-opts to qemu-img man page
- Use printf instead of echo -n in examples
- Line wrap help string based on user terminal width not source code width
- Update qemu-nbd/qemu-io to use constants for options
- Update qemu-nbd to avoid overlapping option values
Daniel P. Berrange (8):
qemu-io: add support for --object command line arg
qemu-img: add support for --object command line arg
qemu-io: allow specifying image as a set of options args
qemu-nbd: allow specifying image as a set of options args
qemu-img: allow specifying image as a set of options args
qemu-nbd: don't overlap long option values with short options
qemu-nbd: use no_argument/required_argument constants
qemu-io: use no_argument/required_argument constants
qemu-img-cmds.hx | 44 +++--- qemu-img.c | 465 +++++++++++++++++++++++++++++++++++++++++++++++++------ qemu-img.texi | 14 ++ qemu-io.c | 115 +++++++++++--- qemu-nbd.c | 104 ++++++++----- qemu-nbd.texi | 7 +- 6 files changed, 627 insertions(+), 122 deletions(-)
Signature · 1 line
2.5.0