qemu-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-commits] [qemu/qemu] c27025: runstate: cleanup reboot and panic ac


From: Peter Maydell
Subject: [Qemu-commits] [qemu/qemu] c27025: runstate: cleanup reboot and panic actions
Date: Sun, 24 Jan 2021 09:00:44 -0800

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: c27025e0448f65b67c36f962dd9e5f23f9ade735
      
https://github.com/qemu/qemu/commit/c27025e0448f65b67c36f962dd9e5f23f9ade735
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2021-01-21 (Thu, 21 Jan 2021)

  Changed paths:
    M qapi/run-state.json
    M qemu-options.hx
    M softmmu/runstate-action.c
    M softmmu/runstate.c
    M softmmu/vl.c

  Log Message:
  -----------
  runstate: cleanup reboot and panic actions

The possible choices for panic, reset and watchdog actions are inconsistent.

"-action panic=poweroff" should be renamed to "-action panic=shutdown"
on the command line.  This is because "-action panic=poweroff" and
"-action watchdog=poweroff" have slightly different semantics, the first
does an unorderly exit while the second goes through qemu_cleanup().  With
this change, -no-shutdown would not have to change "-action panic=pause"
"pause", just like it does not have to change the reset action.

"-action reboot=none" should be renamed to "-action reboot=reset".
This should be self explanatory, since for example "-action panic=none"
lets the guest proceed without taking any action.

Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 15588a62451fc8e911372c52beb9560f2616ca02
      
https://github.com/qemu/qemu/commit/15588a62451fc8e911372c52beb9560f2616ca02
  Author: Joshua Watt <jpewhacker@gmail.com>
  Date:   2021-01-21 (Thu, 21 Jan 2021)

  Changed paths:
    M configure

  Log Message:
  -----------
  configure: MinGW respect --bindir argument

There are two cases that need to be accounted for when compiling QEMU
for MinGW32:
 1) A standalone distribution, where QEMU is self contained and
    extracted by the user, such as a user would download from the QEMU
    website. In this case, all the QEMU executable files should be
    rooted in $prefix to ensure they can be easily found by the user
 2) QEMU integrated into a distribution image/sysroot/SDK and
    distributed with other programs. In this case, the provided
    arguments for bindir/datadir/etc. should be respected as they for a
    Linux build.

Restructures the MinGW path configuration so that all of the paths
except bindir use the same rules as when building for other platforms.
This satisfies #2 and #1 since these files do not need to be directly in
$prefix anyway.

The handling for --bindir is changed so that it defaults to $prefix on
MinGW (maintaining the compatibility with #1), but if the user specifies
a specific path when configuring it can also satisfy #2.

Signed-off-by: Joshua Watt <JPEWhacker@gmail.com>
Message-Id: <20210112210239.28836-1-JPEWhacker@gmail.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 5a140b255df922b98a165f0a2919602943c9062f
      
https://github.com/qemu/qemu/commit/5a140b255df922b98a165f0a2919602943c9062f
  Author: Yang Weijiang <weijiang.yang@intel.com>
  Date:   2021-01-21 (Thu, 21 Jan 2021)

  Changed paths:
    M target/i386/cpu.c

  Log Message:
  -----------
  x86/cpu: Use max host physical address if -cpu max option is applied

QEMU option -cpu max(max_features) means "Enables all features supported by
the accelerator in the current host", this looks true for all the features
except guest max physical address width, so add this patch to enable it.

Signed-off-by: Yang Weijiang <weijiang.yang@intel.com>
Message-Id: <20210113090430.26394-1-weijiang.yang@intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 23a77b2d18b84e410478e88f11c54911f7a649fc
      
https://github.com/qemu/qemu/commit/23a77b2d18b84e410478e88f11c54911f7a649fc
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2021-01-21 (Thu, 21 Jan 2021)

  Changed paths:
    M configure
    M disas/meson.build
    M meson.build
    M meson_options.txt

  Log Message:
  -----------
  build-system: clean up TCG/TCI configury

Make CONFIG_TCG_INTERPRETER a Meson option, and enable TCI (though with
a warning) if the host CPU is unsupported, making it more similar to
other --enable-* options.

Remove TCG-specific include paths from !CONFIG_TCG builds.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: acd15fc2e83ca224cbff3f3548630e67122bfdcd
      
https://github.com/qemu/qemu/commit/acd15fc2e83ca224cbff3f3548630e67122bfdcd
  Author: Gan Qixin <ganqixin@huawei.com>
  Date:   2021-01-21 (Thu, 21 Jan 2021)

  Changed paths:
    M util/cacheflush.c

  Log Message:
  -----------
  util/cacheflush: Fix error generated by clang

When compiling qemu-fuzz-i386 on aarch64 host, clang reported the following
error:

../util/cacheflush.c:38:44: error: value size does not match register size
specified by the constraint and modifier [-Werror,-Wasm-operand-widths]
    asm volatile("mrs\t%0, ctr_el0" : "=r"(save_ctr_el0));
                                           ^
../util/cacheflush.c:38:24: note: use constraint modifier "w"
    asm volatile("mrs\t%0, ctr_el0" : "=r"(save_ctr_el0));
                       ^~
                       %w0

Modify the type of save_ctr_el0 to uint64_t to fix it.

Reported-by: Euler Robot <euler.robot@huawei.com>
Signed-off-by: Gan Qixin <ganqixin@huawei.com>
Message-Id: <20210115075656.717957-1-ganqixin@huawei.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: bbf901914170c6ee423beb3b8c510038c16d082f
      
https://github.com/qemu/qemu/commit/bbf901914170c6ee423beb3b8c510038c16d082f
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M softmmu/physmem.c

  Log Message:
  -----------
  softmmu/physmem: Silence GCC 10 maybe-uninitialized error

When building with GCC 10.2 configured with --extra-cflags=-Os, we get:

  softmmu/physmem.c: In function 'address_space_translate_for_iotlb':
  softmmu/physmem.c:643:26: error: 'notifier' may be used uninitialized in this 
function [-Werror=maybe-uninitialized]
    643 |         notifier->active = true;
        |                          ^
  softmmu/physmem.c:608:23: note: 'notifier' was declared here
    608 |     TCGIOMMUNotifier *notifier;
        |                       ^~~~~~~~

Initialize 'notifier' to silence the warning.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20210117170411.4106949-1-f4bug@amsat.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: b8d7f1bc59276fec85e4d09f1567613a3e14d31e
      
https://github.com/qemu/qemu/commit/b8d7f1bc59276fec85e4d09f1567613a3e14d31e
  Author: Prasad J Pandit <pjp@fedoraproject.org>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M hw/ide/atapi.c

  Log Message:
  -----------
  ide: atapi: check logical block address and read size (CVE-2020-29443)

While processing ATAPI cmd_read/cmd_read_cd commands,
Logical Block Address (LBA) maybe invalid OR closer to the last block,
leading to an OOB access issues. Add range check to avoid it.

Fixes: CVE-2020-29443
Reported-by: Wenxiang Qian <leonwxqian@gmail.com>
Suggested-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Prasad J Pandit <pjp@fedoraproject.org>
Message-Id: <20210118115130.457044-1-ppandit@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 1df783eab50177e0510452cce99e49011dff4e5a
      
https://github.com/qemu/qemu/commit/1df783eab50177e0510452cce99e49011dff4e5a
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M configure

  Log Message:
  -----------
  build-sys: remove unused LIBS

Since meson switch and commit feabc71dfa58 ("configure: do not include
dependency flags in QEMU_CFLAGS and LIBS"), LIBS is unused.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Acked-by: Paolo Bonzini <pbonzini@redhat.com>
Message-Id: <20210114125605.1227742-2-marcandre.lureau@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 5fc0617f134c7ce870a2b30762e099f6fedd4979
      
https://github.com/qemu/qemu/commit/5fc0617f134c7ce870a2b30762e099f6fedd4979
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M meson.build

  Log Message:
  -----------
  build-sys: set global arguments for cflags/ldflags

As we want subprojects to share those arguments

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Acked-by: Paolo Bonzini <pbonzini@redhat.com>
Message-Id: <20210114125605.1227742-3-marcandre.lureau@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 0ba781957e693cf71dbec395061de85c88d05acf
      
https://github.com/qemu/qemu/commit/0ba781957e693cf71dbec395061de85c88d05acf
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M subprojects/libvhost-user/meson.build

  Log Message:
  -----------
  build-sys: add libvhost-user missing dependencies

This help fixing static compilation issues.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Acked-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210114125605.1227742-4-marcandre.lureau@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 3a489d38fd0076d2f9fc8c60b70aa66290a0a199
      
https://github.com/qemu/qemu/commit/3a489d38fd0076d2f9fc8c60b70aa66290a0a199
  Author: Philippe Mathieu-Daudé <philmd@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M fsdev/meson.build
    M meson.build

  Log Message:
  -----------
  meson: Declare have_virtfs_proxy_helper in main meson.build

have_virtfs_proxy_helper is used from docs/meson.build, and can be
not declared when including it before fsdev/meson.build. This fixes:

  ../docs/meson.build:54:2: ERROR: Unknown variable "have_virtfs_proxy_helper".

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210120151539.1166252-1-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 70903cc2fbea7ffe95bd39dfc490b85125004b85
      
https://github.com/qemu/qemu/commit/70903cc2fbea7ffe95bd39dfc490b85125004b85
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M qemu.nsi

  Log Message:
  -----------
  nsis: adjust for new MinGW paths

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: b846ab7c9593197367361fb1110586ba4d311c23
      
https://github.com/qemu/qemu/commit/b846ab7c9593197367361fb1110586ba4d311c23
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M Makefile
    M configure
    M meson.build
    M meson_options.txt
    M qga/meson.build

  Log Message:
  -----------
  meson: convert wixl detection to Meson

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 983d0a75c00a7f11b4b00a752fbd7da42fc47aa8
      
https://github.com/qemu/qemu/commit/983d0a75c00a7f11b4b00a752fbd7da42fc47aa8
  Author: Philippe Mathieu-Daudé <philmd@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M meson.build

  Log Message:
  -----------
  meson: Summarize information related to directories first

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210121095616.1471869-2-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: e11a0e17c4f063047d86e8959d78f09473b46a86
      
https://github.com/qemu/qemu/commit/e11a0e17c4f063047d86e8959d78f09473b46a86
  Author: Philippe Mathieu-Daudé <philmd@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M meson.build

  Log Message:
  -----------
  meson: Display host binaries information altogether

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210121095616.1471869-3-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 1d718865f42945b4d287b7dd28357074413ea3d3
      
https://github.com/qemu/qemu/commit/1d718865f42945b4d287b7dd28357074413ea3d3
  Author: Philippe Mathieu-Daudé <philmd@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M meson.build

  Log Message:
  -----------
  meson: Summarize overall features altogether

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210121095616.1471869-4-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 2e864b8b8da0714767f23d562077083584ea5148
      
https://github.com/qemu/qemu/commit/2e864b8b8da0714767f23d562077083584ea5148
  Author: Philippe Mathieu-Daudé <philmd@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M meson.build

  Log Message:
  -----------
  meson: Summarize compilation-related information altogether

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210121095616.1471869-5-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: aa3ca634279dbcfa87d74f84e932db9124c99d80
      
https://github.com/qemu/qemu/commit/aa3ca634279dbcfa87d74f84e932db9124c99d80
  Author: Philippe Mathieu-Daudé <philmd@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M meson.build

  Log Message:
  -----------
  meson: Display accelerators and selected targets altogether

Display accelerators and selected targets altogether,
avoid to display unuseful information when not relevant.

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210121095616.1471869-6-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 813803aadf13fc7adf1bda414199b42829a1f7eb
      
https://github.com/qemu/qemu/commit/813803aadf13fc7adf1bda414199b42829a1f7eb
  Author: Philippe Mathieu-Daudé <philmd@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M meson.build

  Log Message:
  -----------
  meson: Display block layer information altogether

Display block layer information altogether,
when it is relevant.

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210121095616.1471869-7-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: aa58028afb643ef3dc4a8b7ed33929f45ba043a6
      
https://github.com/qemu/qemu/commit/aa58028afb643ef3dc4a8b7ed33929f45ba043a6
  Author: Philippe Mathieu-Daudé <philmd@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M meson.build

  Log Message:
  -----------
  meson: Display crypto-related information altogether

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210121095616.1471869-8-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 69a78ccea9964190dd1f1d053a975fad1395b0aa
      
https://github.com/qemu/qemu/commit/69a78ccea9964190dd1f1d053a975fad1395b0aa
  Author: Philippe Mathieu-Daudé <philmd@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M meson.build

  Log Message:
  -----------
  meson: Add a section header for library dependencies

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210121095616.1471869-9-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: eae9a1d18beb2bfe42fc48330a009339dc7e8eee
      
https://github.com/qemu/qemu/commit/eae9a1d18beb2bfe42fc48330a009339dc7e8eee
  Author: Philippe Mathieu-Daudé <philmd@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M meson.build
    M pc-bios/descriptors/meson.build
    M pc-bios/meson.build

  Log Message:
  -----------
  meson.build: Declare global edk2_targets / install_edk2_blobs variables

Globally declare in the main meson.build:
- the list of EDK2 targets,
- whether the EDK2 blobs have to be installed.

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210114174509.2944817-2-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 45b545dd190422570f92ecdb50f844e59732a955
      
https://github.com/qemu/qemu/commit/45b545dd190422570f92ecdb50f844e59732a955
  Author: Philippe Mathieu-Daudé <philmd@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M meson.build
    M pc-bios/meson.build

  Log Message:
  -----------
  meson.build: Detect bzip2 program

The --enable-bzip2/--disable-bzip2 configure arguments are
somehow misleading, they check for the bzip2 library, not
the bzip2 program.

We need the bzip2 program to install the EDK2 firmware blobs
(see commit 623ef637a2e "configure: Check bzip2 is available").

Check if the bzip2 program in the global meson.build to avoid
the configuration to succeed, but a later when trying to install
the firmware blobs:

    ../pc-bios/meson.build:5:2: ERROR: Program 'bzip2' not found

Reported-by: John Snow <jsnow@redhat.com>
Suggested-by: Paolo Bonzini <pbonzini@redhat.com>
Fixes: c8d5450bba3 ("configure: move install_blobs from configure to meson")
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210114174509.2944817-3-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 3e3267a9d799788338e7e8120f289c3924fc4e47
      
https://github.com/qemu/qemu/commit/3e3267a9d799788338e7e8120f289c3924fc4e47
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M tests/acceptance/vnc.py

  Log Message:
  -----------
  acceptance: switch to QMP change-vnc-password command

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: cfb5387a1de2acda23fb5c97d2378b9e7ddf8025
      
https://github.com/qemu/qemu/commit/cfb5387a1de2acda23fb5c97d2378b9e7ddf8025
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M docs/system/removed-features.rst
    M hmp-commands.hx
    M monitor/hmp-cmds.c

  Log Message:
  -----------
  hmp: remove "change vnc TARGET" command

The HMP command \"change vnc TARGET\" is messy:

- it takes an ugly shortcut to determine if the option has an "id",
with incorrect results if "id=" is not preceded by an unescaped
comma.

- it deletes the existing QemuOpts and does not try to rollback
if the parsing fails (which is not causing problems, but only due to
how VNC options are parsed)

- because it uses the same parsing function as "-vnc", it forces
the latter to not support "-vnc help".

On top of this, it uses a deprecated QMP command, thus getting in
the way of removing the QMP command.  Since the usecase for the
command is not clear, just remove it and send "change vnc password"
directly to the QMP "change-vnc-password" command.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
Message-Id: <20210120144235.345983-2-pbonzini@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 0afec75734331a0b52fa3aa4235220eda8c7846f
      
https://github.com/qemu/qemu/commit/0afec75734331a0b52fa3aa4235220eda8c7846f
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M docs/system/deprecated.rst
    M docs/system/removed-features.rst
    M monitor/qmp-cmds.c
    M qapi/misc.json

  Log Message:
  -----------
  qmp: remove deprecated "change" command

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210120144235.345983-3-pbonzini@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 653c97473530b4d0e79950103447bad99b64ed79
      
https://github.com/qemu/qemu/commit/653c97473530b4d0e79950103447bad99b64ed79
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M include/ui/console.h
    M softmmu/vl.c
    M ui/vnc-stubs.c
    M ui/vnc.c

  Log Message:
  -----------
  vnc: support "-vnc help"

Use qemu_opts_parse_noisily now that HMP does not call
vnc_parse anymore.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
Message-Id: <20210120144235.345983-4-pbonzini@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: 63758d1073970db0a98fdf975b77eeb6eb02e30d
      
https://github.com/qemu/qemu/commit/63758d1073970db0a98fdf975b77eeb6eb02e30d
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M util/qemu-option.c

  Log Message:
  -----------
  qemu-option: clean up id vs. list->merge_lists

Looking at all merge-lists QemuOptsList, here is how they access their
QemuOpts:

reopen_opts in qemu-io-cmds.c ("qemu-img reopen -o")
        qemu_opts_find(&reopen_opts, NULL)

empty_opts in qemu-io.c ("qemu-io open -o")
        qemu_opts_find(&empty_opts, NULL)

qemu_rtc_opts ("-rtc")
        qemu_find_opts_singleton("rtc")

qemu_machine_opts ("-M")
        qemu_find_opts_singleton("machine")

qemu_action_opts ("-name")
        qemu_opts_foreach->process_runstate_actions

qemu_boot_opts ("-boot")
        in hw/nvram/fw_cfg.c and hw/s390x/ipl.c:
          QTAILQ_FIRST(&qemu_find_opts("bootopts")->head)
        in softmmu/vl.c:
          qemu_opts_find(qemu_find_opts("boot-opts"), NULL)

qemu_name_opts ("-name")
        qemu_opts_foreach->parse_name
        parse_name does not use id

qemu_mem_opts ("-m")
        qemu_find_opts_singleton("memory")

qemu_icount_opts ("-icount")
        qemu_opts_foreach->do_configure_icount
        do_configure_icount->icount_configure
        icount_configure does not use id

qemu_smp_opts ("-smp")
        qemu_opts_find(qemu_find_opts("smp-opts"), NULL)

qemu_spice_opts ("-spice")
        QTAILQ_FIRST(&qemu_spice_opts.head)

i.e. they don't need an id.  Sometimes its presence is ignored
(e.g. when using qemu_opts_foreach), sometimes all the options
with the id are skipped, sometimes only the first option on the
command line is considered.  -boot does two different things
depending on who's looking at the options.

With this patch we just forbid id on merge-lists QemuOptsLists; if the
command line still works, it has the same semantics as before.

qemu_opts_create's fail_if_exists parameter is now unnecessary:

- it is unused if id is NULL

- opts_parse only passes false if reached from qemu_opts_set_defaults,
in which case this patch enforces that id must be NULL

- other callers that can pass a non-NULL id always set it to true

Assert that it is true in the only case where "fail_if_exists" matters,
i.e. "id && !lists->merge_lists".  This means that if an id is present,
duplicates are always forbidden, which was already the status quo.

Discounting the case that aborts as it's not user-controlled (it's
"just" a matter of inspecting qemu_opts_create callers), the paths
through qemu_opts_create can be summarized as:

- merge_lists = true: singleton opts with NULL id; non-NULL id fails

- merge_lists = false: always return new opts; non-NULL id fails if dup

Reviewed-by: Kevin Wolf <kwolf@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: afd736252f106ec54734d4e412220a978f668430
      
https://github.com/qemu/qemu/commit/afd736252f106ec54734d4e412220a978f668430
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M util/qemu-option.c

  Log Message:
  -----------
  qemu-option: move help handling to get_opt_name_value

Right now, help options are parsed normally and then checked
specially in opt_validate, but only if coming from
qemu_opts_parse_noisily.  has_help_option does the check on its own.

opt_validate() has two callers: qemu_opt_set(), which passes null and is
therefore unaffected, and opts_do_parse(), which is affected.

opts_do_parse() is called by qemu_opts_do_parse(), which passes null and
is therefore unaffected, and opts_parse().

opts_parse() is called by qemu_opts_parse() and qemu_opts_set_defaults(),
which pass null and are therefore unaffected, and
qemu_opts_parse_noisily().

Move the check from opt_validate to the parsing workhorse of QemuOpts,
get_opt_name_value.  This will come in handy in the next patch, which
will raise a warning for "-object memory-backend-ram,share" ("flag" option
with no =on/=off part) but not for "-object memory-backend-ram,help".

As a result:

- opts_parse and opts_do_parse do not return an error anymore
  when help is requested; qemu_opts_parse_noisily does not have
  to work around that anymore.

- various crazy ways to request help are not recognized anymore:
  - "help=..."
  - "nohelp" (sugar for "help=off")
  - "?=..."
  - "no?" (sugar for "?=off")

- "help" would be recognized as help request even if there is a (foolishly
  named) parameter "help".  No such parameters exist, though.

Reviewed-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: ccd3b3b8112b670fdccf8a392b8419b173ffccb4
      
https://github.com/qemu/qemu/commit/ccd3b3b8112b670fdccf8a392b8419b173ffccb4
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M docs/system/deprecated.rst
    M tests/test-qemu-opts.c
    M util/qemu-option.c

  Log Message:
  -----------
  qemu-option: warn for short-form boolean options

Options such as "server" or "nowait", that are commonly found in -chardev,
are sugar for "server=on" and "wait=off".  This is quite surprising and
also does not have any notion of typing attached.  It is even possible to
do "-device e1000,noid" and get a device with "id=off".

Deprecate it and print a warning when it is encountered.  In general,
this short form for boolean options only seems to be in wide use for
-chardev and -spice.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>


  Commit: e81eb5e6d108008445821e4f891fb9563016c71b
      
https://github.com/qemu/qemu/commit/e81eb5e6d108008445821e4f891fb9563016c71b
  Author: Peter Maydell <peter.maydell@linaro.org>
  Date:   2021-01-23 (Sat, 23 Jan 2021)

  Changed paths:
    M Makefile
    M configure
    M disas/meson.build
    M docs/system/deprecated.rst
    M docs/system/removed-features.rst
    M fsdev/meson.build
    M hmp-commands.hx
    M hw/ide/atapi.c
    M include/ui/console.h
    M meson.build
    M meson_options.txt
    M monitor/hmp-cmds.c
    M monitor/qmp-cmds.c
    M pc-bios/descriptors/meson.build
    M pc-bios/meson.build
    M qapi/misc.json
    M qapi/run-state.json
    M qemu-options.hx
    M qemu.nsi
    M qga/meson.build
    M softmmu/physmem.c
    M softmmu/runstate-action.c
    M softmmu/runstate.c
    M softmmu/vl.c
    M subprojects/libvhost-user/meson.build
    M target/i386/cpu.c
    M tests/acceptance/vnc.py
    M tests/test-qemu-opts.c
    M ui/vnc-stubs.c
    M ui/vnc.c
    M util/cacheflush.c
    M util/qemu-option.c

  Log Message:
  -----------
  Merge remote-tracking branch 'remotes/bonzini-gitlab/tags/for-upstream' into 
staging

* Make MinGW respect --bindir (Joshua)
* Switch MinGW to a "deep" installation (Joshua + NSIS fixes by myself)
* Fix compilation errors/warnings (Qixin, Philippe)
* QemuOpts cleanups (myself)
* Consistency improvements for -action (myself)
* remove deprecated "change vnc TARGET" functionality (myself)
* meson cleanups (Marc-André, Philippe, myself)
* IDE out-of-bounds access (Prasad)
* LA57 fix for -cpu max (Weijiang)

# gpg: Signature made Sat 23 Jan 2021 20:55:59 GMT
# gpg:                using RSA key F13338574B662389866C7682BFFBD25F78C7AE83
# gpg:                issuer "pbonzini@redhat.com"
# gpg: Good signature from "Paolo Bonzini <bonzini@gnu.org>" [full]
# gpg:                 aka "Paolo Bonzini <pbonzini@redhat.com>" [full]
# Primary key fingerprint: 46F5 9FBD 57D6 12E7 BFD4  E2F7 7E15 100C CD36 69B1
#      Subkey fingerprint: F133 3857 4B66 2389 866C  7682 BFFB D25F 78C7 AE83

* remotes/bonzini-gitlab/tags/for-upstream: (30 commits)
  qemu-option: warn for short-form boolean options
  qemu-option: move help handling to get_opt_name_value
  qemu-option: clean up id vs. list->merge_lists
  vnc: support "-vnc help"
  qmp: remove deprecated "change" command
  hmp: remove "change vnc TARGET" command
  acceptance: switch to QMP change-vnc-password command
  meson.build: Detect bzip2 program
  meson.build: Declare global edk2_targets / install_edk2_blobs variables
  meson: Add a section header for library dependencies
  meson: Display crypto-related information altogether
  meson: Display block layer information altogether
  meson: Display accelerators and selected targets altogether
  meson: Summarize compilation-related information altogether
  meson: Summarize overall features altogether
  meson: Display host binaries information altogether
  meson: Summarize information related to directories first
  meson: convert wixl detection to Meson
  nsis: adjust for new MinGW paths
  meson: Declare have_virtfs_proxy_helper in main meson.build
  ...

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>


Compare: https://github.com/qemu/qemu/compare/e93c65a6c64f...e81eb5e6d108



reply via email to

[Prev in Thread] Current Thread [Next in Thread]