Commit graph

89619 commits

Author SHA1 Message Date
Peter Maydell e3152d02da target/arm: Fix VPT advance when ECI is non-zero
We were not paying attention to the ECI state when advancing the VPT
state.  Architecturally, VPT state advance happens for every beat
(see the pseudocode VPTAdvance()), so on every beat the 4 bits of
VPR.P0 corresponding to the current beat are inverted if required,
and at the end of beats 1 and 3 the VPR MASK fields are updated.
This means that if the ECI state says we should not be executing all
4 beats then we need to skip some of the updating of the VPR that we
currently do in mve_advance_vpt().

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2021-08-25 10:48:49 +01:00
Peter Maydell e0d40070e1 target/arm: Factor out mve_eci_mask()
In some situations we need a mask telling us which parts of the
vector correspond to beats that are not being executed because of
ECI, separately from the combined "which bytes are predicated away"
mask.  Factor this mask calculation out of mve_element_mask() into
its own function.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2021-08-25 10:48:49 +01:00
Peter Maydell 3f4f1880c2 target/arm: Fix calculation of LTP mask when LR is 0
In mve_element_mask(), we calculate a mask for tail predication which
should have a number of 1 bits based on the value of LR.  However,
our MAKE_64BIT_MASK() macro has undefined behaviour when passed a
zero length.  Special case this to give the all-zeroes mask we
require.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2021-08-25 10:48:48 +01:00
Peter Maydell fdcf2269c4 target/arm: Fix MVE 48-bit SQRSHRL for small right shifts
We got an edge case wrong in the 48-bit SQRSHRL implementation: if
the shift is to the right, although it always makes the result
smaller than the input value it might not be within the 48-bit range
the result is supposed to be if the input had some bits in [63..48]
set and the shift didn't bring all of those within the [47..0] range.

Handle this similarly to the way we already do for this case in
do_uqrshl48_d(): extend the calculated result from 48 bits,
and return that if not saturating or if it doesn't change the
result; otherwise fall through to return a saturated value.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2021-08-25 10:48:48 +01:00
Peter Maydell 95351aa76c target/arm: Fix 48-bit saturating shifts
In do_sqrshl48_d() and do_uqrshl48_d() we got some of the edge
cases wrong and failed to saturate correctly:

(1) In do_sqrshl48_d() we used the same code that do_shrshl_bhs()
does to obtain the saturated most-negative and most-positive 48-bit
signed values for the large-shift-left case.  This gives (1 << 47)
for saturate-to-most-negative, but we weren't sign-extending this
value to the 64-bit output as the pseudocode requires.

(2) For left shifts by less than 48, we copied the "8/16 bit" code
from do_sqrshl_bhs() and do_uqrshl_bhs().  This doesn't do the right
thing because it assumes the C type we're working with is at least
twice the number of bits we're saturating to (so that a shift left by
bits-1 can't shift anything off the top of the value).  This isn't
true for bits == 48, so we would incorrectly return 0 rather than the
most-positive value for situations like "shift (1 << 44) right by
20".  Instead check for saturation by doing the shift and signextend
and then testing whether shifting back left again gives the original
value.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2021-08-25 10:48:48 +01:00
Peter Maydell a5e59e8dcb target/arm: Fix mask handling for MVE narrowing operations
In the MVE helpers for the narrowing operations (DO_VSHRN and
DO_VSHRN_SAT) we were using the wrong bits of the predicate mask for
the 'top' versions of the insn.  This is because the loop works over
the double-sized input elements and shifts the predicate mask by that
many bits each time, but when we write out the half-sized output we
must look at the mask bits for whichever half of the element we are
writing to.

Correct this by shifting the whole mask right by ESIZE bits for the
'top' insns.  This allows us also to simplify the saturation bit
checking (where we had noticed that we needed to look at a different
mask bit for the 'top' insn.)

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2021-08-25 10:48:48 +01:00
Peter Maydell ed5a59d61f target/arm: Fix signed VADDV
A cut-and-paste error meant we handled signed VADDV like
unsigned VADDV; fix the type used.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2021-08-25 10:48:48 +01:00
Peter Maydell c88ff88498 target/arm: Fix MVE VSLI by 0 and VSRI by <dt>
In the MVE shift-and-insert insns, we special case VSLI by 0
and VSRI by <dt>. VSRI by <dt> means "don't update the destination",
which is what we've implemented. However VSLI by 0 is "set
destination to the input", so we don't want to use the same
special-casing that we do for VSRI by <dt>.

Since the generic logic gives the right answer for a shift
by 0, just use that.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2021-08-25 10:48:48 +01:00
Peter Maydell aa29190826 target/arm: Print MVE VPR in CPU dumps
Include the MVE VPR register value in the CPU dumps produced by
arm_cpu_dump_state() if we are printing FPU information. This
makes it easier to interpret debug logs when predication is
active.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2021-08-25 10:48:48 +01:00
Peter Maydell 9dacf0764b target/arm: Note that we handle VMOVL as a special case of VSHLL
Although the architecture doesn't define it as an alias, VMOVL
(vector move long) is encoded as a VSHLL with a zero shift.
Add a comment in the decode file noting that we handle VMOVL
as part of VSHLL.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
2021-08-25 10:48:48 +01:00
Yanan Wang 7f697d7b68 docs/about: Add the missing release record in the subject
Commit 29e0447551
(docs/about/removed-features: Document removed CLI options from QEMU v3.1)
has recorded some CLI options as replaced/removed from QEMU v3.1, but one
of the subjects has missed the release record. Let's fix it.

Reported-by: Cornelia Huck <cohuck@redhat.com>
Signed-off-by: Yanan Wang <wangyanan55@huawei.com>
Reviewed-by: Andrew Jones <drjones@redhat.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-Id: <20210823030005.165668-4-wangyanan55@huawei.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-25 11:34:03 +02:00
Yanan Wang e2cc363bbb docs/about: Unify the subject format
There is a mixture of "since/removed in X.Y" vs "since/removed in X.Y.Z"
in the subjects in deprecated.rst/removed-features.rst. It will be better
to use an unified format. It seems unlikely that we will ever deprecate
something in a stable release, and even more unlikely that we'll remove
something in one, so the short versions look like the thing we want to
standardize on.

So here we unify the subject format in deprecated.rst to "since X.Y", and
unify the subject format in removed-features.rst to "removed in X.Y".

Signed-off-by: Yanan Wang <wangyanan55@huawei.com>
Reviewed-by: Cornelia Huck <cohuck@redhat.com>
Reviewed-by: Andrew Jones <drjones@redhat.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-Id: <20210823030005.165668-3-wangyanan55@huawei.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-25 11:34:03 +02:00
Yanan Wang 3ce105c5bf docs/about: Remove the duplicated doc
There are two places describing the same thing about deprecation
of invalid topologies of -smp CLI, so remove the duplicated one.

Signed-off-by: Yanan Wang <wangyanan55@huawei.com>
Reviewed-by: Cornelia Huck <cohuck@redhat.com>
Reviewed-by: Andrew Jones <drjones@redhat.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-Id: <20210823030005.165668-2-wangyanan55@huawei.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-25 11:34:03 +02:00
Peter Maydell d426857656 Open 6.2 development tree
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-25 10:25:12 +01:00
Peter Maydell f9baca549e Update version for v6.1.0 release
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-24 17:59:52 +01:00
Peter Maydell ecf2706e27 Update version for v6.1.0-rc4 release
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-17 19:14:08 +01:00
David Hildenbrand 1c4c685936 softmmu/physmem: fix wrong assertion in qemu_ram_alloc_internal()
When adding RAM_NORESERVE, we forgot to remove the old assertion when
adding the updated one, most probably when reworking the patches or
rebasing. We can easily crash QEMU by adding
  -object memory-backend-ram,id=mem0,size=500G,reserve=off
to the QEMU cmdline:
  qemu-system-x86_64: ../softmmu/physmem.c:2146: qemu_ram_alloc_internal:
  Assertion `(ram_flags & ~(RAM_SHARED | RAM_RESIZEABLE | RAM_PREALLOC))
  == 0' failed.

Fix it by removing the old assertion.

Fixes: 8dbe22c686 ("memory: Introduce RAM_NORESERVE and wire it up in qemu_ram_mmap()")
Reviewed-by: Peter Xu <peterx@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Tested-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Reviewed-by: Pankaj Gupta <pankaj.gupta@ionos.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
Message-id: 20210805092350.31195-1-david@redhat.com
Cc: Paolo Bonzini <pbonzini@redhat.com>
Cc: Peter Xu <peterx@redhat.com>
Cc: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: David Hildenbrand <david@redhat.com>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-17 16:51:39 +01:00
Andrew Jones 0572edc55b qapi/machine.json: Remove zero value reference from SMPConfiguration documentation
Commit 1e63fe6858 ("machine: pass QAPI struct to mc->smp_parse")
introduced documentation stating that a zero input value for an SMP
parameter indicates that its value should be automatically configured.
This is indeed how things work today, but we'd like to change that.
Avoid documenting behaviors we want to leave undefined for the time
being, giving us freedom to change it later.

Fixes: 1e63fe6858 ("machine: pass QAPI struct to mc->smp_parse")
Signed-off-by: Andrew Jones <drjones@redhat.com>
Acked-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Cornelia Huck <cohuck@redhat.com>
Reviewed-by: Yanan Wang <wangyanan55@huawei.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-17 16:26:47 +01:00
Peter Maydell bd44d64a38 * Fixes for the gitlab-CI (fix the hanging build-oss-fuzz pipeline)
* Add documentation about features that have been removed in older versions
 -----BEGIN PGP SIGNATURE-----
 
 iQJFBAABCAAvFiEEJ7iIR+7gJQEY8+q5LtnXdP5wLbUFAmET1KQRHHRodXRoQHJl
 ZGhhdC5jb20ACgkQLtnXdP5wLbWX8A/9FK6r1lRWLx9KVFyIuwCpNJFA97hdC0su
 OQKWJm1lanipb0hvD+URAQvOK/NqfF+2CHRAtEFR48MQeKhyjdAFXmFD7oNXHcun
 CKMFlBMSWnQlWftB9YsYG69n+90oad9IRCS7j4oq7NH3kmg9UPtMnrVviMSBW4q3
 HDBNJGISN88Zt07WFjsvuiGjUtLOZEKzh8xcjohKeODhq70HfzakdbXedxRf/Nhk
 8iqntRsHjSJ1+bE/Ozw5erlfMGk0RsBb+fzAFQEc70qD8eUKUgrIDfXSBNLufnRK
 06FeTobWL4cF3di5FUjr1o0Af4mM0h/sUU7FfZ0W2WQrtXOpfpSMthVbdnBMxYhr
 FRWGFGTtzgCHuDL/WiJ8yAwfYlKj3f7ZmFvt+kzUq2O+c+klGX8jeyJ2FjNtV0HM
 KtWmw6S3vQvh1STUH57LtyH2f+BVtGPtIJClfqLcyzibUbyr7JgtxR3rHQaQ9nml
 03mdzRgQq7RNpsFkqPvBPhDg4D7D09Nq9tiLnHfyrHcV/3VmifHr6cXJGiZsvY7x
 f2+u/6H+q8yN3EmMbrtpUOENmLYsro8vaNvXsnnwpCYS2j5ZAYp8fmhYswUcV1LD
 jxMw0+YNWycV6Ra8s4WGjH6hYn6ylv86+O0uUK7x+PaSUW/vJ6SymJ4joX16nr2i
 0QA1xlxizoM=
 =VXhO
 -----END PGP SIGNATURE-----

Merge remote-tracking branch 'remotes/thuth-gitlab/tags/pull-request-2021-08-11' into staging

* Fixes for the gitlab-CI (fix the hanging  build-oss-fuzz pipeline)
* Add documentation about features that have been removed in older versions

# gpg: Signature made Wed 11 Aug 2021 14:46:12 BST
# gpg:                using RSA key 27B88847EEE0250118F3EAB92ED9D774FE702DB5
# gpg:                issuer "thuth@redhat.com"
# gpg: Good signature from "Thomas Huth <th.huth@gmx.de>" [full]
# gpg:                 aka "Thomas Huth <thuth@redhat.com>" [full]
# gpg:                 aka "Thomas Huth <huth@tuxfamily.org>" [full]
# gpg:                 aka "Thomas Huth <th.huth@posteo.de>" [unknown]
# Primary key fingerprint: 27B8 8847 EEE0 2501 18F3  EAB9 2ED9 D774 FE70 2DB5

* remotes/thuth-gitlab/tags/pull-request-2021-08-11:
  docs/about/removed-features: Document removed machines from older QEMU versions
  docs/about/removed-features: Document removed devices from older QEMU versions
  docs/about/removed-features: Document removed HMP commands from QEMU v2.12
  docs/about/removed-features: Document removed CLI options from QEMU v3.1
  docs/about/removed-features: Document removed CLI options from QEMU v3.0
  docs/about/removed-features: Document removed CLI options from QEMU v2.12
  fuzz: avoid building twice, when running on gitlab
  tests/qtest/vhost-user-blk-test: Check whether qemu-storage-daemon is available
  storage-daemon: Add missing build dependency to the vhost-user-blk-test
  gitlab: skip many more targets in windows cross builds
  gitlab: exclude sparc-softmmu and riscv32-softmmu from cross builds

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-15 16:46:23 +01:00
Peter Maydell 80c9d104a1 MAINTAINERS: update kraxel's entries.
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEoDKM/7k6F6eZAf59TLbY7tPocTgFAmETcQMACgkQTLbY7tPo
 cTiEiA//R8dN8YrhRQiLF8KIpdJi6sGVEIKAS42p0pz+h72tc2dmW1j+PKYgupyR
 o3VCmTMYkDo+KWwHqWoBxqR6bPjIpCItPisChMu/TdCFF+LQd3llltRmT/b7Ng0p
 fulFne0YB7efTMgTamN+l9ZRrtwOKjMxMc0Ix7BFkbIHtWhdEV1d4Whls8wYBRcS
 cfRe7rDKYu+hnIjA4F8AldXcjcXuNCO2hDtHRJcmNo2lNUX3eh00A20UDZM3MhBe
 0ss1lXg/IfFy9+0siyKLQSB2+81K97RZjuLNmBO4F2lnbl4AXPlKK6Kh97d+sXMs
 PVSasI6U/9Axi/HTSlneNXN7O42+lOckL1XTfC0NWxRbYqh1RvfKwacRi+QddAk2
 qisN69AKv1y55STShb+O+dfmnZoHaaUwR5vrRgBVhtL1pQ6RG05mzzm2o3A8kYOI
 9VP+AMwElgObxK5E/ujg3spIu9Xvtghr4geFupXGcL4cbcxjq9cTCgNejXCRfuan
 qZaWWZFQTergodaDcRoYyTWJCS9wNP4NX2BYKLexpqRX5sqL0+WN8go9mE4oABpZ
 oHJd2uj3Ok8zwZIDXeJw4qCNogTo48EC6DjlVPa8bHQBAKYAyqJh0IthQZgjCd7Y
 79y+U7EV0JnPnF9KefHPEvf1RpYYll9bSrlRnVNU3n1qgLD3MLI=
 =3zRs
 -----END PGP SIGNATURE-----

Merge remote-tracking branch 'remotes/kraxel/tags/maintainers-20210811-pull-request' into staging

MAINTAINERS: update kraxel's entries.

# gpg: Signature made Wed 11 Aug 2021 07:41:07 BST
# gpg:                using RSA key A0328CFFB93A17A79901FE7D4CB6D8EED3E87138
# gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" [full]
# gpg:                 aka "Gerd Hoffmann <gerd@kraxel.org>" [full]
# gpg:                 aka "Gerd Hoffmann (private) <kraxel@gmail.com>" [full]
# Primary key fingerprint: A032 8CFF B93A 17A7 9901  FE7D 4CB6 D8EE D3E8 7138

* remotes/kraxel/tags/maintainers-20210811-pull-request:
  MAINTAINERS: update virtio-gpu entry.
  MAINTAINERS: update virtio-input entry.
  MAINTAINERS: update usb entries.
  MAINTAINERS: update spice entry.
  MAINTAINERS: update audio entry.
  MAINTAINERS: update sockets entry.
  MAINTAINERS: update edk2 entry.

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-15 13:23:20 +01:00
Peter Maydell f1a1a93646 Hexagon (disas/hexagon.c) fix memory leak for early exit
Don't allocate the string until error conditions have been checked
 
 Fixes: a00cfed0e ("Hexagon (disas) disassembler")
 Eliminate Coverity CID 1460121 (Resource leak)
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1
 
 iQEcBAABAgAGBQJhFeDkAAoJEHsCRPsS3kQiCTsH/RvpPwHd+Nkm+nnueTUbOWfJ
 Jra+JUzuu7bNYwrFJcQUoetbplUXqDgHnY5VBaAltrgInaZ1Xt/QtWWNBdDc2MU6
 WEs5JWAZn4/3mWaglZZ8ESDx/OjCKunfYYR6fZSlXG4WgVER6O8+A+ri0h3TWoRw
 i/WzlvAROB3bUDvum+tqskT3zkH73NgHCcJhVAG/FiV232aDR9TJMN+OlgZ8n32Y
 tnfSeATTZos6ms9em1kI4ccM8KWemehnxCY+GvohMdcnxF3kvsxyWgbUfcY3JuKz
 4OVnXyGZhDD5ow1ORQcqlvF1MiIst1EbKtImNifalG39lMRCTpwupWIzggo7AuA=
 =SZsl
 -----END PGP SIGNATURE-----

Merge remote-tracking branch 'remotes/quic/tags/pull-hex-20210812' into staging

Hexagon (disas/hexagon.c) fix memory leak for early exit

Don't allocate the string until error conditions have been checked

Fixes: a00cfed0e ("Hexagon (disas) disassembler")
Eliminate Coverity CID 1460121 (Resource leak)

# gpg: Signature made Fri 13 Aug 2021 04:03:00 BST
# gpg:                using RSA key 7B0244FB12DE4422
# gpg: Good signature from "Taylor Simpson (Rock on) <tsimpson@quicinc.com>" [undefined]
# gpg: WARNING: This key is not certified with a trusted signature!
# gpg:          There is no indication that the signature belongs to the owner.
# Primary key fingerprint: 3635 C788 CE62 B91F D4C5  9AB4 7B02 44FB 12DE 4422

* remotes/quic/tags/pull-hex-20210812:
  Hexagon (disas/hexagon.c) fix memory leak for early exit cases

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-15 11:14:23 +01:00
Peter Maydell 2edf8ac5bd Fixes for -smp, and for x86 TCG on Windows.
-----BEGIN PGP SIGNATURE-----
 
 iQFIBAABCAAyFiEE8TM4V0tmI4mGbHaCv/vSX3jHroMFAmEWaQIUHHBib256aW5p
 QHJlZGhhdC5jb20ACgkQv/vSX3jHroO0igf/SH8lcWEiqSxhS+FDfawBjfHn7m6c
 YOVMZHxeNE+ApHm7S8H9zc7V1LgOBk1nZdnFTZFxUY/Q5FJv1Kql/hGAkwyj+7ve
 ssXcg5n8uwIbWCL7i+JmVnAtORL4vhLhwqEQBIh1HzMtepkl2Y1BTKAy9RpfLENg
 v8/NQ1++nxCAhlOKqQVZ0etEWRsUoJ+7s3VYFLnVV0HQ3q9kt92TTBNH7fRJwyjH
 3qwWhznAdTZEX/383n5Io3471WyZ2c8VAbp98Q6o6Md/orbFq6iWj9wfirJCO3+r
 b8knqUqDY3N4BQA1QNeJKkGI6pYEQLPWub/G6goIIhwRnMSoImO7x9rv2w==
 =3nSh
 -----END PGP SIGNATURE-----

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

Fixes for -smp, and for x86 TCG on Windows.

# gpg: Signature made Fri 13 Aug 2021 13:43:46 BST
# 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:
  hw/core: fix error checking in smp_parse
  hw/core: Add missing return on error
  target/i386: Fixed size of constant for Windows

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-13 17:52:19 +01:00
Daniel P. Berrangé ea0aa1752c hw/core: fix error checking in smp_parse
machine_set_smp() mistakenly checks 'errp' not '*errp',
and so thinks there is an error every single time it runs.
This causes it to jump to the end of the method, skipping
the max CPUs checks. The caller meanwhile sees no error
and so carries on execution. The result of all this is:

 $ qemu-system-x86_64 -smp -1
 qemu-system-x86_64: GLib: ../glib/gmem.c:142: failed to allocate 481036337048 bytes

instead of

 $ qemu-system-x86_64 -smp -1
 qemu-system-x86_64: Invalid SMP CPUs -1. The max CPUs supported by machine 'pc-i440fx-6.1' is 255

This is a regression from

  commit fe68090e8f
  Author: Paolo Bonzini <pbonzini@redhat.com>
  Date:   Thu May 13 09:03:48 2021 -0400

    machine: add smp compound property

Closes: https://gitlab.com/qemu-project/qemu/-/issues/524
Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20210812175353.4128471-1-berrange@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2021-08-13 14:43:42 +02:00
Philippe Mathieu-Daudé 0b46318170 hw/core: Add missing return on error
If dies is not supported by this machine's CPU topology, don't
keep processing options and return directly.

Fixes: 0aebebb561 ("machine: reject -smp dies!=1 for non-PC machines")
Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Message-Id: <20210813112608.1452541-2-philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2021-08-13 14:43:35 +02:00
Lara Lazier 24d84c7e48 target/i386: Fixed size of constant for Windows
~0UL has 64 bits on Linux and 32 bits on Windows.

Fixes: https://gitlab.com/qemu-project/qemu/-/issues/512
Reported-by: Volker Rümelin <vr_qemu@t-online.de>
Signed-off-by: Lara Lazier <laramglazier@gmail.com>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-Id: <20210812111056.26926-1-laramglazier@gmail.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2021-08-13 14:31:49 +02:00
Taylor Simpson a7686d5d85 Hexagon (disas/hexagon.c) fix memory leak for early exit cases
Don't allocate the string until error conditions have been checked

Fixes: a00cfed0e ("Hexagon (disas) disassembler")
Eliminate Coverity CID 1460121 (Resource leak)

Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Philippe Mathieu-Daud? <f4bug@amsat.org>
Signed-off-by: Taylor Simpson <tsimpson@quicinc.com>
2021-08-12 09:06:05 -05:00
Thomas Huth 36b508993c docs/about/removed-features: Document removed machines from older QEMU versions
These machines had been removed in the QEMU v2.6 up to 4.0 time frame.

Message-Id: <20210811084103.74832-7-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-11 15:39:09 +02:00
Thomas Huth 5643fcdd42 docs/about/removed-features: Document removed devices from older QEMU versions
These devices had been removed/replaced in QEMU v2.12 and v4.0.

Message-Id: <20210811084103.74832-6-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-11 15:39:06 +02:00
Thomas Huth 5d82c10160 docs/about/removed-features: Document removed HMP commands from QEMU v2.12
These HMP commands had been removed/replaced in QEMU v2.12. Still, some
people might want to update from older versions to the recent QEMU version,
so we should give some recommendations for the replacements in our
documentation.

Message-Id: <20210811084103.74832-5-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-11 15:39:01 +02:00
Thomas Huth 29e0447551 docs/about/removed-features: Document removed CLI options from QEMU v3.1
These CLI options had been removed/replaced in QEMU v3.1. Still, some
people might want to update from older versions to the recent QEMU version,
so we should give some recommendations for the replacements in our
documentation.

Message-Id: <20210811084103.74832-4-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-11 15:38:57 +02:00
Thomas Huth 8cc461c185 docs/about/removed-features: Document removed CLI options from QEMU v3.0
These CLI options had been removed/replaced in QEMU v3.0. Still, some
people might want to update from older versions to the recent QEMU version,
so we should give some recommendations for the replacements in our
documentation.

Message-Id: <20210811084103.74832-3-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-11 15:38:54 +02:00
Thomas Huth 3d9c7ec955 docs/about/removed-features: Document removed CLI options from QEMU v2.12
These CLI options had been removed/replaced in QEMU v2.12. Still, some
people might want to update from older versions to the recent QEMU version,
so we should give some recommendations for the replacements in our
documentation.

Message-Id: <20210811084103.74832-2-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-11 15:38:50 +02:00
Alexander Bulekov 3973e7ae63 fuzz: avoid building twice, when running on gitlab
On oss-fuzz, we build twice, to put together a build that is portable to
the runner containers. On gitlab ci, this is wasteful and contributes to
timeouts on the build-oss-fuzz job. Avoid building twice on gitlab, at
the remote cost of potentially missing some cases that break oss-fuzz
builds.

Signed-off-by: Alexander Bulekov <alxndr@bu.edu>
Reviewed-by: Darren Kenny <darren.kenny@oracle.com>
Message-Id: <20210809111621.54454-1-alxndr@bu.edu>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-11 13:40:01 +02:00
Thomas Huth b063c290f3 tests/qtest/vhost-user-blk-test: Check whether qemu-storage-daemon is available
The vhost-user-blk-test currently hangs if QTEST_QEMU_STORAGE_DAEMON_BINARY
points to a non-existing binary. Let's improve this situation by checking
for the availability of the binary first, so we can fail gracefully if
it is not accessible.

Message-Id: <20210811095949.133462-1-thuth@redhat.com>
Reviewed-by: Alexander Bulekov <alxndr@bu.edu>
Tested-by: Alexander Bulekov <alxndr@bu.edu>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-11 13:40:01 +02:00
Thomas Huth cc1838c25d storage-daemon: Add missing build dependency to the vhost-user-blk-test
vhost-user-blk-test needs the qemu-storage-daemon, otherwise it
currently hangs. So make sure that we build the daemon before running
the tests.

Message-Id: <20210811094705.131314-1-thuth@redhat.com>
Tested-by: Alexander Bulekov <alxndr@bu.edu>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-11 13:39:50 +02:00
Daniel P. Berrangé a1f0f36838 gitlab: skip many more targets in windows cross builds
The windows cross builds still take way too long in gitlab CI, so need
more targets to be skipped. We don't want to hurt coverage of other
cross builds more though, so we let jobs fine tune with a new env
variale $CROSS_SKIP_TARGETS.

We take the set of targets that are considered relatively niche or
very old architectures, and skip approx half of them in win32 builds
and the other half of them in win64.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Willian Rampazzo <willianr@redhat.com>
Message-Id: <20210810140653.3969823-3-berrange@redhat.com>
[thuth: Swapped the "CROSS_SKIP_TARGETS:" lines as suggested by philmd]
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-11 08:52:31 +02:00
Gerd Hoffmann a4de5e8a06 MAINTAINERS: update virtio-gpu entry.
New maintainer wanted. Downgrade status to "Odd Fixes" for now.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Message-Id: <20210810083450.2377374-8-kraxel@redhat.com>
2021-08-11 08:39:16 +02:00
Gerd Hoffmann 1e2edb9866 MAINTAINERS: update virtio-input entry.
New maintainer wanted. Downgrade status to "Odd Fixes" for now.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Message-Id: <20210810083450.2377374-7-kraxel@redhat.com>
2021-08-11 08:39:16 +02:00
Gerd Hoffmann cd02c965c4 MAINTAINERS: update usb entries.
New maintainer wanted.  Switch role to "Reviewer" for usb-serial,
downgrade status to "Odd Fixes" for everything else.

Cc: Samuel Thibault <samuel.thibault@ens-lyon.org>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Message-Id: <20210810083450.2377374-6-kraxel@redhat.com>
2021-08-11 08:39:16 +02:00
Gerd Hoffmann 227b1638ba MAINTAINERS: update spice entry.
New maintainer wanted. Downgrade status to "Odd Fixes" for now.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Message-Id: <20210810083450.2377374-5-kraxel@redhat.com>
2021-08-11 08:39:16 +02:00
Gerd Hoffmann 6bc915f31a MAINTAINERS: update audio entry.
New maintainer wanted. Downgrade status to "Odd Fixes" for now.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Message-Id: <20210810083450.2377374-4-kraxel@redhat.com>
2021-08-11 08:39:16 +02:00
Gerd Hoffmann 8f6259055a MAINTAINERS: update sockets entry.
I have not touched the code for years.
Make the entry match reality and drop my name.

Cc: Daniel P. Berrange <berrange@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Message-Id: <20210810083450.2377374-3-kraxel@redhat.com>
2021-08-11 08:39:16 +02:00
Gerd Hoffmann f492bdf4ab MAINTAINERS: update edk2 entry.
I want keep an eye on the edk2 things happening in qemu.

Cc: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Message-Id: <20210810083450.2377374-2-kraxel@redhat.com>
2021-08-11 08:39:16 +02:00
Daniel P. Berrangé a62354915b gitlab: exclude sparc-softmmu and riscv32-softmmu from cross builds
We need to cut down compile time by excluding more targets. Both these
targets still have their 64-bit variant enabled, so the loss of coverage
is mitigated to some degree.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Willian Rampazzo <willianr@redhat.com>
Message-Id: <20210810140653.3969823-2-berrange@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
2021-08-11 07:52:43 +02:00
Peter Maydell 703e8cd618 Update version for v6.1.0-rc3 release
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-10 19:08:09 +01:00
Hanna Reitz b0c4798f97 MAINTAINERS: Name and email address change
I have changed my name and email address.  Update the MAINTAINERS file
to match, and .mailmap in case anyone wants to send me an email because
of some past commit I authored.  (As suggested by Philippe, I put the
.mailmap line into the "preferred name forms" section, considering it
counts as a git author config change.)

Signed-off-by: Hanna Reitz <hreitz@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-10 16:42:16 +01:00
Peter Maydell 02b8aeede2 fixes for gtk, sdl and audio live migration.
-----BEGIN PGP SIGNATURE-----
 
 iQIzBAABCgAdFiEEoDKM/7k6F6eZAf59TLbY7tPocTgFAmESbpYACgkQTLbY7tPo
 cThQuQ//X5kLamLlPjM6GAukCty5/15rs3lrjQuIwTxxWX//82pmGUwVPGm3oiqj
 6wb2ps4Exb5dCxpVs/smnPt9P3bkbrrbfCLxmWZ3Uf0+MTpadeaiG2V4KS9QqZYR
 o6lnl9hStt8P48zhLmKpJcQpmo6qDNrOnPPz3GBFnB4lJ6DtVGHDf0+BQYFLDQ6p
 t+/F9jbXn8IFoMwiMJd1x1A3mezJQ5wyf8rhMQh+FO2bki1IuZDdY2XwwBABNMrp
 1PIgZVSq69/CAjWTQuw2DEEhtcD/z1cI6mx08zIXHBgybkhZk1xjHLlakRuIfjzP
 KSpS2Dg8O1Tgkr1X+zjoS2LrqiM9okw0mSwOfnOXuz1wNgNj/JggRTV9c7FFA7SO
 D1fRpXOx1pq8Mo3YYIN31oxt2PELipR/Jn1PK29ezB06qY7Yv+zOBw5Ep+InEuz+
 O4g2mBzv1iZsZ7X1wfr8Fu9KfeMmxNaKjL/J6vD0hbjufno6WmVaexwVXBTMGW9q
 3mXCPkGu4dWbSBXjomV9GYmcpk23bR7oH57c3PFXM7STX4Nc0leABW0HwZ6XHeDu
 l4Wb5HC6kR5KkhemZ7ifUO2ElfFBn6XUQY1q/UPV/gzYKiMyot0GBlHjd6O0/NiQ
 sxU6QxrBDv3MjhzUQpBCrNeQm/f8PUAEgfXmznjx24HPJWorLL8=
 =qZFO
 -----END PGP SIGNATURE-----

Merge remote-tracking branch 'remotes/kraxel/tags/fixes-20210810-pull-request' into staging

fixes for gtk, sdl and audio live migration.

# gpg: Signature made Tue 10 Aug 2021 13:18:30 BST
# gpg:                using RSA key A0328CFFB93A17A79901FE7D4CB6D8EED3E87138
# gpg: Good signature from "Gerd Hoffmann (work) <kraxel@redhat.com>" [full]
# gpg:                 aka "Gerd Hoffmann <gerd@kraxel.org>" [full]
# gpg:                 aka "Gerd Hoffmann (private) <kraxel@gmail.com>" [full]
# Primary key fingerprint: A032 8CFF B93A 17A7 9901  FE7D 4CB6 D8EE D3E8 7138

* remotes/kraxel/tags/fixes-20210810-pull-request:
  ui/sdl2: Check return value from g_setenv()
  audio: Never send migration section
  ui/gtk: retry sending VTE console input

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-10 14:00:39 +01:00
Peter Maydell 6ff5b5d6d5 ui/sdl2: Check return value from g_setenv()
Setting environment variables can fail; check the return value
from g_setenv() and bail out if we couldn't set SDL_VIDEODRIVER.

Fixes: Coverity 1458798
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Message-Id: <20210809161424.32355-1-peter.maydell@linaro.org>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2021-08-10 10:56:39 +02:00
Dr. David Alan Gilbert da77adbaf6 audio: Never send migration section
The audio migration vmstate is empty, and always has been; we can't
just remove it though because an old qemu might send it us.
Changes with -audiodev now mean it's sometimes created when it didn't
used to be, and can confuse migration to old qemu.

Change it so that vmstate_audio is never sent; if it's received it
should still be accepted, and old qemu's shouldn't be too upset if it's
missing.

Signed-off-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Tested-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20210809170956.78536-1-dgilbert@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
2021-08-10 10:55:57 +02:00
Peter Maydell 1f3afa5da2 qemu-ga patch queue for hard-freeze
* fix memory leak in guest_exec
 -----BEGIN PGP SIGNATURE-----
 
 iQEzBAABCgAdFiEEzqzJ4VU066u4LT+gM1PJzvEItYQFAmER1ZcACgkQM1PJzvEI
 tYQuAgf9Haicx4FaFYUu7KuharaSlsaRpPdm5yjyITCGBUdktXZZoAPLwc18p0Wx
 euB8dQ+7OdXYWMYqVtJwoTyKNd0vKIDL+WmM1xJ2gnsrdOKq7vPthkx2Ci1DFZ2P
 V7UGVSVdH8s5tePxX+i0XNMDl8jBj1ugrmXwx8BxFct3u6mzvBm4Sto6qfPZGLPw
 FZNWQYLqYbws9Ig4QPKRmxcq96fKjzSvfGexZ/yiEgU+6Ln6ouAqaErvop/l3pY4
 hZOkb/FaseDyUsT7oyQnGZSrIrMrvKooes0Raus9ISnRjzA2y6qbFkibdR+n2sG1
 7YOBUSXthHoU8XL1zHRI7/ioRuBHtg==
 =73Wq
 -----END PGP SIGNATURE-----

Merge remote-tracking branch 'remotes/mdroth/tags/qga-pull-2021-08-09-tag' into staging

qemu-ga patch queue for hard-freeze

* fix memory leak in guest_exec

# gpg: Signature made Tue 10 Aug 2021 02:25:43 BST
# gpg:                using RSA key CEACC9E15534EBABB82D3FA03353C9CEF108B584
# gpg: Good signature from "Michael Roth <flukshun@gmail.com>" [full]
# gpg:                 aka "Michael Roth <mdroth@utexas.edu>" [full]
# gpg:                 aka "Michael Roth <mdroth@linux.vnet.ibm.com>" [full]
# Primary key fingerprint: CEAC C9E1 5534 EBAB B82D  3FA0 3353 C9CE F108 B584

* remotes/mdroth/tags/qga-pull-2021-08-09-tag:
  qga: fix leak of base64 decoded data on command error

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
2021-08-10 09:42:06 +01:00