[PATCH v2 1/6] target/riscv: add check for supported privilege modes conbinations

2022-07-11 Thread Weiwei Li
- There are 3 suggested privilege modes conbinations listed in the spec: 1) M, 2) M, U 3) M, S, U Signed-off-by: Weiwei Li Signed-off-by: Junqiang Wang Reviewed-by: Alistair Francis --- target/riscv/cpu.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/target/riscv/cpu.c b/target/ris

[PATCH v2 0/6] Improve the U/S/H extension related check

2022-07-11 Thread Weiwei Li
This patchset tries to improve the U/S/H related check: * add check for the supported privilege modes conbinations: only supporting M, S mode is not a suggested combination * add check for "H extension depends on I extension" * add check for "H extension implicitly requires S mode" * add check for

Re: [RFC v4 4/9] file-posix: introduce get_sysfs_str_val for device zoned model.

2022-07-11 Thread Damien Le Moal
On 7/12/22 15:17, Hannes Reinecke wrote: > On 7/12/22 04:13, Sam Li wrote: >> Signed-off-by: Sam Li >> --- >> block/file-posix.c | 60 >> include/block/block-common.h | 4 +-- >> 2 files changed, 62 insertions(+), 2 deletions(-) >> >> diff --git

[PATCH v2 2/6] target/riscv: H extension depends on I extension

2022-07-11 Thread Weiwei Li
- add check for "H depends on an I base integer ISA with 32 x registers" Signed-off-by: Weiwei Li Signed-off-by: Junqiang Wang Reviewed-by: Alistair Francis --- target/riscv/cpu.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/target/riscv/cpu.c b/target/riscv/cpu.c index 36c1b26fb3

[PATCH v2 4/6] target/riscv: add check for csrs existed with U extension

2022-07-11 Thread Weiwei Li
- add umode/umode32 predicate for mcounteren,menvcfg/menvcfgh Signed-off-by: Weiwei Li Signed-off-by: Junqiang Wang Reviewed-by: Alistair Francis --- target/riscv/csr.c | 25 ++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/target/riscv/csr.c b/target/ri

[PATCH v2 6/6] target/riscv: simplify the check in hmode to resue the check in riscv_csrrw_check

2022-07-11 Thread Weiwei Li
Just add 1 to the effective privledge level when in HS mode, then reuse the check 'effective_priv < csr_priv' in riscv_csrrw_check to replace the privilege level related check in hmode. Then, hmode will only check whether H extension is supported. when accessing Hypervior CSRs: 1) if access f

[PATCH v2 3/6] target/riscv: fix checkpatch warning may triggered in csr_ops table

2022-07-11 Thread Weiwei Li
- fix the lines with over 80 characters - fix the lines which is obviously misalgined with other lines in same the group Signed-off-by: Weiwei Li Signed-off-by: Junqiang Wang --- target/riscv/csr.c | 441 - 1 file changed, 234 insertions(+), 207 delet

[PULL 2/2] accel/tcg: Fix unaligned stores to s390x low-address-protected lowcore

2022-07-11 Thread Richard Henderson
From: Ilya Leoshkevich If low-address-protection is active, unaligned stores to non-protected parts of lowcore lead to protection exceptions. The reason is that in such cases tlb_fill() call in store_helper_unaligned() covers [0, addr + size) range, which contains the protected portion of lowcore

[PATCH v2 5/6] target/riscv: fix checks in hmode/hmode32

2022-07-11 Thread Weiwei Li
- add check for the implicit dependence between H and S - Csrs only existed in RV32 will not trigger virtual instruction fault when not in RV32 Signed-off-by: Weiwei Li Signed-off-by: Junqiang Wang --- target/riscv/cpu.c | 5 + target/riscv/csr.c | 9 ++--- 2 files changed, 7 insertions

[PULL 0/2] tcg patch queue

2022-07-11 Thread Richard Henderson
The following changes since commit 9fed1bca6bc643ce91b6117f4974421aaede4751: Merge tag 'pull-target-arm-20220711' of https://git.linaro.org/people/pmaydell/qemu-arm into staging (2022-07-11 22:02:09 +0530) are available in the Git repository at: https://gitlab.com/rth7680/qem

Re: [RFC v4 3/9] file-posix: introduce get_sysfs_long_val for a block queue of sysfs attribute

2022-07-11 Thread Hannes Reinecke
On 7/12/22 04:13, Sam Li wrote: Use sysfs attribute files to get the zoned device information in case that ioctl() commands of zone management interface won't work. Signed-off-by: Sam Li --- block/file-posix.c | 38 +++--- 1 file changed, 27 insertions(+), 11

[PULL 1/2] tcg: Fix returned type in alloc_code_gen_buffer_splitwx_memfd()

2022-07-11 Thread Richard Henderson
From: Shaobo Song This fixes a bug in POSIX-compliant environments. Since we had allocated a buffer named 'tcg-jit' with read-write access protections we need a int type to combine these access flags and return it, whereas we had inexplicably return a bool type. It may cause an unnecessary protec

Re: [RFC v4 1/9] block: add block layer APIs resembling Linux ZonedBlockDevice ioctls.

2022-07-11 Thread Sam Li
Hannes Reinecke 于2022年7月12日周二 14:10写道: > > On 7/12/22 04:13, Sam Li wrote: > > By adding zone management operations in BlockDriver, storage > > controller emulation can use the new block layer APIs including > > zone_report and zone_mgmt(open, close, finish, reset). > > > > Signed-off-by: Sam Li

Re: [RFC v4 4/9] file-posix: introduce get_sysfs_str_val for device zoned model.

2022-07-11 Thread Hannes Reinecke
On 7/12/22 04:13, Sam Li wrote: Signed-off-by: Sam Li --- block/file-posix.c | 60 include/block/block-common.h | 4 +-- 2 files changed, 62 insertions(+), 2 deletions(-) diff --git a/block/file-posix.c b/block/file-posix.c index 3161d39ea4..4

Re: [RFC v4 1/9] block: add block layer APIs resembling Linux ZonedBlockDevice ioctls.

2022-07-11 Thread Hannes Reinecke
On 7/12/22 04:13, Sam Li wrote: By adding zone management operations in BlockDriver, storage controller emulation can use the new block layer APIs including zone_report and zone_mgmt(open, close, finish, reset). Signed-off-by: Sam Li --- block/block-backend.c| 41 ++ block/c

Re: [RFC v4 2/9] qemu-io: add zoned block device operations.

2022-07-11 Thread Hannes Reinecke
On 7/12/22 04:13, Sam Li wrote: Add zoned storage commands of the device: zone_open(zo), zone_close(zc), zone_reset(zs), zone_report(zp), zone_finish(zf). For example, it can be called by: ./build/qemu-io --image-opts driver=zoned_host_device, filename=/dev/nullb0 -c "zone_report 0 0 1" Signed-

Re: [PATCH 0/2] gitlab-ci: msys2 improvements

2022-07-11 Thread Richard Henderson
On 7/12/22 09:24, Richard Henderson wrote: On 7/11/22 13:26, marcandre.lur...@redhat.com wrote: From: Marc-André Lureau Hi This is a small series to attempt to debug "Intermittent meson failures on msys2" and improve a bit msys2/gitlab reports. Thanks.  I've pushed this to staging for a tes

Re: [PATCH v4 2/2] ui/gtk: a new array param monitor to specify the target displays

2022-07-11 Thread Markus Armbruster
Dongwon Kim writes: > New integer array parameter, 'monitor' is for specifying the target > monitors where individual GTK windows are placed upon launching. > > Monitor numbers in the array are associated with virtual consoles > in the order of [VC0, VC1, VC2 ... VCn]. > > Every GTK window contai

Re: [RFC v4 0/9] Add support for zoned device

2022-07-11 Thread Sam Li
Markus Armbruster 于2022年7月12日周二 13:47写道: > > Sam Li writes: > > > This patch series adds support for zoned device to virtio-blk emulation. > > Zoned > > Storage can support sequential writes, which reduces write amplification in > > SSD, > > leading to higher write throughput and increased capa

Re: [RFC v4 0/9] Add support for zoned device

2022-07-11 Thread Markus Armbruster
Sam Li writes: > This patch series adds support for zoned device to virtio-blk emulation. Zoned > Storage can support sequential writes, which reduces write amplification in > SSD, > leading to higher write throughput and increased capacity. Forgive me if this has already been discussed, or is

Re: [PATCH] target/riscv: move zmmul out of the experimental properties

2022-07-11 Thread Alistair Francis
On Sun, Jul 10, 2022 at 8:16 PM Weiwei Li wrote: > > - Zmmul is ratified and is now version 1.0 > > Signed-off-by: Weiwei Li > Signed-off-by: Junqiang Wang Thanks! Applied to riscv-to-apply.next Alistair > --- > target/riscv/cpu.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) >

Re: [PATCH] target/riscv: move zmmul out of the experimental properties

2022-07-11 Thread Alistair Francis
On Sun, Jul 10, 2022 at 8:16 PM Weiwei Li wrote: > > - Zmmul is ratified and is now version 1.0 > > Signed-off-by: Weiwei Li > Signed-off-by: Junqiang Wang Reviewed-by: Alistair Francis Alistair > --- > target/riscv/cpu.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --

Re: [PATCH 1/3] accel/tcg: Fix unaligned stores to s390x low-address-protected lowcore

2022-07-11 Thread Richard Henderson
On 7/12/22 00:26, Ilya Leoshkevich wrote: If low-address-protection is active, unaligned stores to non-protected parts of lowcore lead to protection exceptions. The reason is that in such cases tlb_fill() call in store_helper_unaligned() covers [0, addr + size) range, which contains the protected

Re: [PATCH 2/3] hw/misc: Add mmio-debug-exit device

2022-07-11 Thread Richard Henderson
On 7/12/22 00:26, Ilya Leoshkevich wrote: System tests on x86 use isa-debug-exit device in order to signal success or failure to the test runner. Unfortunately it's not easily usable on other architectures, since a guest needs to access address_space_io, which may not be as straightforward as on

Re: [PATCH v2] target/riscv: fix shifts shamt value for rv128c

2022-07-11 Thread Alistair Francis
On Sun, Jul 10, 2022 at 9:05 PM Frédéric Pétrot wrote: > > For rv128c shifts, a shamt of 0 is a shamt of 64, while for rv32c/rv64c > it stays 0 and is a hint instruction that does not change processor state. > For rv128c right shifts, the 6-bit shamt is in addition sign extended to > 7 bits. > > S

Re: [PATCH] [PATCH] linux-user/aarch64: Reset target data on MADV_DONTNEED

2022-07-11 Thread Richard Henderson
On 7/12/22 03:30, Vitaly Buka wrote: aarch64 stores MTE tags in target_date, and they should be reset by MADV_DONTNEED. Signed-off-by: Vitaly Buka --- accel/tcg/translate-all.c | 24 include/exec/cpu-all.h| 1 + linux-user/mmap.c | 2 ++ 3 files chang

Re: Booting bare-metal RISC-V virt (Was: [PATCH] Add some documentation for "dtb" devices tree blobs)

2022-07-11 Thread Alistair Francis
On Mon, Jun 27, 2022 at 4:15 PM Simon Sapin wrote: > > On 27/06/2022 07:40, Alistair Francis wrote: > > We have previously kept the addresses backwards compatible. So that > > software for an older virt machine will work on a newer one. There is > > currently talks about changing the virt machine

Re: [PATCH 3/3] tests/tcg/s390x: test signed vfmin/vfmax

2022-07-11 Thread Richard Henderson
On 7/12/22 07:27, Ilya Leoshkevich wrote: +/* + * vfmin/vfmax code generation. + */ +extern const char vfminmax_template[]; +extern const int vfminmax_template_size; +extern const int vfminmax_offset; +asm(".globl vfminmax_template\n" +"vfminmax_template:\n" +"vl %v25,0(%r3)\n" +"vl %

Re: [PATCH 2/3] target/s390x: fix NaN propagation rules

2022-07-11 Thread Richard Henderson
On 7/12/22 07:27, Ilya Leoshkevich wrote: s390x has the same NaN propagation rules as ARM, and not as x86. Signed-off-by: Ilya Leoshkevich --- fpu/softfloat-specialize.c.inc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) Yes, I think no one has those x86 rules, including x86. :-)

Re: [PATCH v4 09/12] tests/vm: Remove docker cross-compile test from CentOS VM

2022-07-11 Thread Richard Henderson
On 7/8/22 21:05, John Snow wrote: The fedora container has since been split apart, so there's no suitable nearby target that would support "test-mingw" as it requires both x32 and x64 support -- so either fedora-cross-win32 nor fedora-cross-win64 would be truly suitable. Just remove this test as

Re: [PATCH 1/3] target/s390x: fix handling of zeroes in vfmin/vfmax

2022-07-11 Thread Richard Henderson
On 7/12/22 07:27, Ilya Leoshkevich wrote: vfmin_res() / vfmax_res() are trying to check whether a and b are both zeroes, but in reality they check that they are the same kind of zero. This causes incorrect results when comparing positive and negative zeroes. Fixes: da4807527f3b ("s390x/tcg: Impl

Re: [RFC PATCH v9 19/23] vdpa: Extract get features part from vhost_vdpa_get_max_queue_pairs

2022-07-11 Thread Jason Wang
在 2022/7/7 02:40, Eugenio Pérez 写道: To know the device features is needed for CVQ SVQ, so SVQ knows if it can handle all commands or not. Extract from vhost_vdpa_get_max_queue_pairs so we can reuse it. Signed-off-by: Eugenio Pérez Acked-by: Jason Wang --- net/vhost-vdpa.c | 30 ++

Re: [PATCH v4 08/12] tests/vm: add 1GB extra memory per core

2022-07-11 Thread Richard Henderson
On 7/8/22 21:04, John Snow wrote: If you try to run a 16 or 32 threaded test, you're going to run out of memory very quickly with qom-test and a few others. Bump the memory limit to try to scale with larger-core machines. Granted, this means that a 16 core processor is going to ask for 16GB, but

Re: [PATCH v4 07/12] tests/vm: remove duplicate 'centos' VM test

2022-07-11 Thread Richard Henderson
On 7/8/22 21:04, John Snow wrote: This is listed twice by accident; we require genisoimage to run the test, so remove the unconditional entry. Signed-off-by: John Snow Reviewed-by: Thomas Huth Reviewed-by: Daniel P. Berrangé --- tests/vm/Makefile.include | 2 +- 1 file changed, 1 insertion(+)

Re: [PATCH v4 03/12] tests/vm: switch CentOS 8 to CentOS 8 Stream

2022-07-11 Thread Richard Henderson
On 7/8/22 21:04, John Snow wrote: The old CentOS image didn't work anymore because it was already EOL at the beginning of 2022. Signed-off-by: John Snow Reviewed-by: Thomas Huth Reviewed-by: Daniel P. Berrangé --- tests/vm/centos | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) R

Re: [PATCH v4 06/12] tests/vm: remove ubuntu.i386 VM test

2022-07-11 Thread Richard Henderson
On 7/8/22 21:04, John Snow wrote: Ubuntu 18.04 is out of our support window, and Ubuntu 20.04 does not support i386 anymore. The debian project does, but they do not provide any cloud images for it, a new expect-style script would have to be written. Since we have i386 cross-compiler tests hoste

Re: [PATCH v4 05/12] tests/vm: upgrade Ubuntu 18.04 VM to 20.04

2022-07-11 Thread Richard Henderson
On 7/8/22 21:04, John Snow wrote: 18.04 has fallen out of our support window, so move ubuntu.aarch64 forward to ubuntu 20.04, which is now our oldest supported Ubuntu release. Notes: This checksum changes periodically; use a fixed point image with a known checksum so that the image isn't re-dow

Re: [PATCH v4 04/12] tests/vm: switch centos.aarch64 to CentOS 8 Stream

2022-07-11 Thread Richard Henderson
On 7/8/22 21:04, John Snow wrote: Switch this test over to using a cloud image like the base CentOS8 VM test, which helps make this script a bit simpler too. Note: At time of writing, this test seems pretty flaky when run without KVM support for aarch64. Certain unit tests like migration-test, v

Re: [PATCH v4 02/12] tests/vm: use 'cp' instead of 'ln' for temporary vm images

2022-07-11 Thread Richard Henderson
On 7/8/22 21:04, John Snow wrote: If the initial setup fails, you've permanently altered the state of the downloaded image in an unknowable way. Use 'cp' like our other test setup scripts do. Signed-off-by: John Snow Reviewed-by: Thomas Huth Reviewed-by: Daniel P. Berrangé --- tests/vm/centos

Re: [PATCH] ui/cocoa: Fix switched_to_fullscreen warning

2022-07-11 Thread Akihiko Odaki
On 2022/07/12 9:05, Peter Delevoryas wrote: On Wed, Jul 06, 2022 at 05:58:38PM -0700, Peter Delevoryas wrote: On Sat, Jul 02, 2022 at 11:30:16PM +0900, Akihiko Odaki wrote: Reviewed-by: Akihiko Odaki Just checking in on the status of this: do I need to submit a pull request? Or will this pat

Re: [PATCH] meson: place default firmware path under .../share

2022-07-11 Thread Richard Henderson
On 7/11/22 13:37, Paolo Bonzini wrote: Fixes: c09c1ce7e9 ("configure: switch directory options to automatic parsing", 2022-05-07) Signed-off-by: Paolo Bonzini --- meson_options.txt | 2 +- scripts/meson-buildoptions.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) Re

Re: [PATCH 0/2] gitlab-ci: msys2 improvements

2022-07-11 Thread Richard Henderson
On 7/11/22 13:26, marcandre.lur...@redhat.com wrote: From: Marc-André Lureau Hi This is a small series to attempt to debug "Intermittent meson failures on msys2" and improve a bit msys2/gitlab reports. Thanks. I've pushed this to staging for a test run: https://gitlab.com/qemu-project/qemu

Re: [PATCH v2] target/riscv: fix shifts shamt value for rv128c

2022-07-11 Thread Richard Henderson
On 7/12/22 01:24, Frédéric Pétrot wrote:   Agreed, on the non compressed insns, but the compressed ones have a 6-bit   shamt only as visible on page 18.6 page 125. The explanation for rv128 shifts   is further detailed in the emphasized paragraph on top of page 120. I see. I should have rea

[PATCH v3 2/3] hw/gpio/aspeed: Don't let guests modify input pins

2022-07-11 Thread Peter Delevoryas
Up until now, guests could modify input pins by overwriting the data value register. The guest OS should only be allowed to modify output pin values, and the QOM property setter should only be permitted to modify input pins. This change also updates the gpio input pin test to match this expectatio

[PATCH v3 0/3] hw/gpio/aspeed: Don't let guests modify input pins

2022-07-11 Thread Peter Delevoryas
v3: - Replaced fix in v2 with change suggested by arj - Removed all changes to the body of the aspeed_gpio_update loop - Removed guest error messages from v2 Peter Delevoryas (3): qtest/aspeed_gpio: Add input pin modification test hw/gpio/aspeed: Don't let guests modify input pins aspeed: Ad

[PATCH v3 3/3] aspeed: Add fby35-bmc slot GPIO's

2022-07-11 Thread Peter Delevoryas
Signed-off-by: Peter Delevoryas --- hw/arm/aspeed.c | 14 +- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/hw/arm/aspeed.c b/hw/arm/aspeed.c index 6fe9b13548..0ce9a42c2b 100644 --- a/hw/arm/aspeed.c +++ b/hw/arm/aspeed.c @@ -1343,11 +1343,23 @@ static void fby35_reset(

[PATCH v3 1/3] qtest/aspeed_gpio: Add input pin modification test

2022-07-11 Thread Peter Delevoryas
Verify the current behavior, which is that input pins can be modified by guest OS register writes. Signed-off-by: Peter Delevoryas --- tests/qtest/aspeed_gpio-test.c | 27 +++ 1 file changed, 27 insertions(+) diff --git a/tests/qtest/aspeed_gpio-test.c b/tests/qtest/aspe

[RFC v4 9/9] qapi: add support for zoned host device

2022-07-11 Thread Sam Li
--- block/file-posix.c | 8 +++- qapi/block-core.json | 7 +-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/block/file-posix.c b/block/file-posix.c index e9ad1d8e1e..4e0aa02acf 100644 --- a/block/file-posix.c +++ b/block/file-posix.c @@ -3737,6 +3737,12 @@ static void

[RFC v4 8/9] include: add support for zoned block devices

2022-07-11 Thread Sam Li
This is the virtio_blk.h header file from Dmitry's "virtio-blk: add support for zoned block devices" patch. It introduces virtio_blk_zoned_characteristics struct from Dmitry's virtio-blk zoned storage spec. Signed-off-by: Dmitry Fomichev Signed-off-by: Sam Li --- include/standard-headers/linux/

Re: [PULL 00/45] target-arm queue

2022-07-11 Thread Richard Henderson
it.linaro.org/people/pmaydell/qemu-arm into staging (2022-07-08 06:17:11 +0530) are available in the Git repository at: https://git.linaro.org/people/pmaydell/qemu-arm.git tags/pull-target-arm-20220711 for you to fetch changes up to f9982ceaf26df27d15547a3a7990a95019e9e3a8: linux-user/aarc

[RFC v4 6/9] raw-format: add zone operations

2022-07-11 Thread Sam Li
Signed-off-by: Sam Li --- block/raw-format.c | 13 + 1 file changed, 13 insertions(+) diff --git a/block/raw-format.c b/block/raw-format.c index 69fd650eaf..96bdb6c1e2 100644 --- a/block/raw-format.c +++ b/block/raw-format.c @@ -314,6 +314,17 @@ static int coroutine_fn raw_co_pdiscar

[RFC v4 7/9] config: add check to block layer

2022-07-11 Thread Sam Li
Putting zoned/non-zoned BlockDrivers on top of each other is not allowed. Signed-off-by: Sam Li --- block.c | 7 +++ block/file-posix.c | 2 ++ include/block/block_int-common.h | 5 + 3 files changed, 14 insertions(+) diff --git a/block.c b/block.c

[RFC v4 5/9] qemu-iotests: test new zone operations.

2022-07-11 Thread Sam Li
We have added new block layer APIs of zoned block devices. Test it with: (1) Create a null_blk device, run each zone operation on it and see whether reporting right zone information. Signed-off-by: Sam Li --- tests/qemu-iotests/tests/zoned.sh | 69 +++ 1 file changed,

[RFC v4 4/9] file-posix: introduce get_sysfs_str_val for device zoned model.

2022-07-11 Thread Sam Li
Signed-off-by: Sam Li --- block/file-posix.c | 60 include/block/block-common.h | 4 +-- 2 files changed, 62 insertions(+), 2 deletions(-) diff --git a/block/file-posix.c b/block/file-posix.c index 3161d39ea4..42708012ff 100644 --- a/block/file-pos

[RFC v4 2/9] qemu-io: add zoned block device operations.

2022-07-11 Thread Sam Li
Add zoned storage commands of the device: zone_open(zo), zone_close(zc), zone_reset(zs), zone_report(zp), zone_finish(zf). For example, it can be called by: ./build/qemu-io --image-opts driver=zoned_host_device, filename=/dev/nullb0 -c "zone_report 0 0 1" Signed-off-by: Sam Li --- block/io.c

[RFC v4 0/9] Add support for zoned device

2022-07-11 Thread Sam Li
This patch series adds support for zoned device to virtio-blk emulation. Zoned Storage can support sequential writes, which reduces write amplification in SSD, leading to higher write throughput and increased capacity. v4: - add block layer APIs (revision) - add configurations for zoned block devi

[RFC v4 1/9] block: add block layer APIs resembling Linux ZonedBlockDevice ioctls.

2022-07-11 Thread Sam Li
By adding zone management operations in BlockDriver, storage controller emulation can use the new block layer APIs including zone_report and zone_mgmt(open, close, finish, reset). Signed-off-by: Sam Li --- block/block-backend.c| 41 ++ block/coroutines.h | 5 + b

[PATCH 2/2] i386/cpuid: Remove subleaf constraint on CPUID leaf 1F

2022-07-11 Thread Xiaoyao Li
No such constraint that subleaf index needs to be less than 64. Signed-off-by: Xiaoyao Li --- target/i386/kvm/kvm.c | 4 1 file changed, 4 deletions(-) diff --git a/target/i386/kvm/kvm.c b/target/i386/kvm/kvm.c index a0b412a1129f..3efa524b4b93 100644 --- a/target/i386/kvm/kvm.c +++ b/targe

[RFC v4 3/9] file-posix: introduce get_sysfs_long_val for a block queue of sysfs attribute

2022-07-11 Thread Sam Li
Use sysfs attribute files to get the zoned device information in case that ioctl() commands of zone management interface won't work. Signed-off-by: Sam Li --- block/file-posix.c | 38 +++--- 1 file changed, 27 insertions(+), 11 deletions(-) diff --git a/block/fil

[PATCH 0/2] i386/cpuid: Minor fixes for CPUID leaf 1f setup

2022-07-11 Thread Xiaoyao Li
The issue that fixed by Patch 1 looks fatal though it doesn't appear on KVM because KVM always searches with assending order and hit with the correct cpuid leaf 0. Patch 2 removes the wrong constraint on CPUID leaf 1f Xiaoyao Li (2): i386/cpuid: Decrease cpuid_i when skipping CPUID leaf 1F i3

[PATCH 1/2] i386/cpuid: Decrease cpuid_i when skipping CPUID leaf 1F

2022-07-11 Thread Xiaoyao Li
Decrease array index cpuid_i when CPUID leaf 1F is skipped, otherwise it will get an all zero'ed CPUID entry with leaf 0 and subleaf 0. It conflicts with correct leaf 0. Signed-off-by: Xiaoyao Li --- target/i386/kvm/kvm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/target/i386/kvm/kvm.c

[PATCH 3/3] tests/tcg/s390x: test signed vfmin/vfmax

2022-07-11 Thread Ilya Leoshkevich
Add a test to prevent regressions. Try all floating point value sizes and all combinations of floating point value classes. Verify the results against PoP tables, which are represented as close to the original as possible - this produces a lot of checkpatch complaints, but it seems to be justified

Re: [PATCH 1/2] hw/gpio/aspeed: Don't let guests modify input pins

2022-07-11 Thread Peter Delevoryas
On Mon, Jul 11, 2022 at 10:56:08PM +0930, Andrew Jeffery wrote: > > > On Fri, 8 Jul 2022, at 04:34, Peter Delevoryas wrote: > > On Thu, Jul 07, 2022 at 10:53:57AM -0700, Peter Delevoryas wrote: > >> On Thu, Jul 07, 2022 at 10:56:02AM +0200, Cédric Le Goater wrote: > >> > On 7/7/22 09:17, Peter De

[PATCH 2/3] target/s390x: fix NaN propagation rules

2022-07-11 Thread Ilya Leoshkevich
s390x has the same NaN propagation rules as ARM, and not as x86. Signed-off-by: Ilya Leoshkevich --- fpu/softfloat-specialize.c.inc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/fpu/softfloat-specialize.c.inc b/fpu/softfloat-specialize.c.inc index 943e3301d2..a43ff5e02e 1

[PATCH 1/3] target/s390x: fix handling of zeroes in vfmin/vfmax

2022-07-11 Thread Ilya Leoshkevich
vfmin_res() / vfmax_res() are trying to check whether a and b are both zeroes, but in reality they check that they are the same kind of zero. This causes incorrect results when comparing positive and negative zeroes. Fixes: da4807527f3b ("s390x/tcg: Implement VECTOR FP (MAXIMUM|MINIMUM)") Co-devel

[PATCH 0/3] target/s390x: vfmin/vfmax fixes

2022-07-11 Thread Ilya Leoshkevich
Hi, Uli has found an issue with finding maximum of different kinds of 0s; I wrote a test and found another one with finding maximum of different kinds of NaNs. Patches 1 and 2 fix those issues, patch 3 adds a vfmin/vfmax test. Best regards, Ilya Ilya Leoshkevich (3): target/s390x: fix handlin

Re: [PATCH RESEND] python/machine: Fix AF_UNIX path too long on macOS

2022-07-11 Thread Peter Delevoryas
On Mon, Jul 11, 2022 at 04:56:28PM -0400, John Snow wrote: > On Thu, Jul 7, 2022 at 2:46 PM Peter Delevoryas wrote: > > > > On Wed, Jul 06, 2022 at 05:52:48PM -0700, Peter Delevoryas wrote: > > > On Wed, Jul 06, 2022 at 09:46:48AM -0700, Peter Delevoryas wrote: > > > > On Wed, Jul 06, 2022 at 09:0

Re: [PATCH v2] scsi/lsi53c895a: fix use-after-free in lsi_do_msgout (CVE-2022-0216)

2022-07-11 Thread Alexander Bulekov
On 220711 1433, Mauro Matteo Cascella wrote: > Set current_req to NULL to prevent reusing a free'd buffer in case of repeated > SCSI cancel requests. Thanks to Thomas Huth for suggesting the first version > of > the patch and Alexander Bulekov for providing a reproducer. > > Fixes: CVE-2022-0216

Re: [PATCH] ui/cocoa: Fix switched_to_fullscreen warning

2022-07-11 Thread Peter Delevoryas
On Wed, Jul 06, 2022 at 05:58:38PM -0700, Peter Delevoryas wrote: > On Sat, Jul 02, 2022 at 11:30:16PM +0900, Akihiko Odaki wrote: > > Reviewed-by: Akihiko Odaki > > Just checking in on the status of this: do I need to submit a pull request? > Or will this patch be picked up in a miscellaneous pu

[PATCH v4 2/2] ui/gtk: a new array param monitor to specify the target displays

2022-07-11 Thread Dongwon Kim
New integer array parameter, 'monitor' is for specifying the target monitors where individual GTK windows are placed upon launching. Monitor numbers in the array are associated with virtual consoles in the order of [VC0, VC1, VC2 ... VCn]. Every GTK window containing each VC will be placed in the

[PATCH v4 1/2] ui/gtk: detach VCs for additional guest displays

2022-07-11 Thread Dongwon Kim
Detaching any addtional guest displays in case multiple displays are assigned to the guest OS (e.g. max_outputs=n) so that all of them are visible upon lauching. Cc: Daniel P. Berrangé Cc: Markus Armbruster Cc: Philippe Mathieu-Daudé Cc: Paolo Bonzini Cc: Gerd Hoffmann Cc: Vivek Kasireddy Si

[PATCH v4 0/2] handling guest multiple displays

2022-07-11 Thread Dongwon Kim
This patch seires is for adding some useful features for the guest os with multi-displays. First patch is to make all of guest displays visible when guest os is launched using "detach". Second patch is for providing a method to assign each guest display to specific physical monitor, which would be

[RFC PATCH v3 5/7] tests: add 'check-venv' as a dependency of 'make check'

2022-07-11 Thread John Snow
This patch adds the 'check-venv' target as a requisite of all meson driven check-* targets. As of this commit, it will only install the "qemu" namespace package from the source tree, and nothing else. In the future, the "qemu" namespace package in qemu.git will begin to require an external qemu.qm

[RFC PATCH v3 7/7] iotests: self-bootstrap testing venv

2022-07-11 Thread John Snow
When iotests are invoked manually from e.g. $build/tests/qemu-iotests/check, it is not necessarily guaranteed that we'll have run 'check-venv' yet. With this patch, teach testenv.py how to create its own environment. Note: this self-bootstrapping is fairly rudimentary and will miss certain trigge

[RFC PATCH v3 1/7] tests: create optional tests/venv dependency groups

2022-07-11 Thread John Snow
This patch uses a dummy package and setup.cfg/setup.py files to manage optional dependency groups for the test venv specification. Now, there's a core set of dependencies which for now includes just "qemu" (but soon, qemu.qmp) and a separate, optional 'avocado' group that includes avocado-framework

[RFC PATCH v3 4/7] tests/vm: add venv pre-requisites to VM building recipes

2022-07-11 Thread John Snow
NetBSD needs "py37-pip" in order to create virtual environments. Signed-off-by: John Snow --- tests/vm/netbsd | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/vm/netbsd b/tests/vm/netbsd index 45aa9a7fda7..53fe508e487 100755 --- a/tests/vm/netbsd +++ b/tests/vm/netbsd @@ -31,6 +31,7 @@

[RFC PATCH v3 3/7] tests: Remove spurious pip warnings on Ubuntu20.04

2022-07-11 Thread John Snow
The version of pip ("20.0.2") that ships with Ubuntu 20.04 has a bug where it will try to attempt building a wheel even if the "wheel" python package that enables it to do so is not installed. Even though pip continues gracefully from source, The result is a lot of irrelevant failure output. Upstr

[RFC PATCH v3 6/7] iotests: use tests/venv for running tests

2022-07-11 Thread John Snow
Essentially, the changes to testenv.py here mimic the changes that occur when you "source venv/bin/activate.fish" or similar. (1) update iotest's internal notion of which python binary to use, (2) export the VIRTUAL_ENV variable, (3) front-load the venv/bin directory to PATH. If the venv director

[RFC PATCH v3 2/7] tests: pythonize test venv creation

2022-07-11 Thread John Snow
This splits the venv creation logic out of the Makefile and into a Python script. One reason for doing this is to be able to call the venv bootstrapper from places outside of the Makefile, e.g. configure and iotests. Another reason is to be able to add "offline" logic to modify the behavior of the

[RFC PATCH v3 0/7] tests: run python tests under a venv

2022-07-11 Thread John Snow
Hi, here's another RFC for bringing external Python dependencies to the QEMU test suite. This is mostly a refresh of a version I sent out before, but mixes in my VM improvement test as an optional pre-requisite to improve VM test stability to ensure that the BSDs all pass with the new infrastructu

Re: [PATCH v6 03/10] i386/pc: pass pci_hole64_size to pc_memory_init()

2022-07-11 Thread B
Am 11. Juli 2022 10:01:49 UTC schrieb Joao Martins : >On 7/9/22 21:51, B wrote: >> Am 1. Juli 2022 16:10:07 UTC schrieb Joao Martins >> : >>> Use the pre-initialized pci-host qdev and fetch the >>> pci-hole64-size into pc_memory_init() newly added argument. >>> piix needs a bit of care given al

Re: Regarding QEMU on eclipse IDE:

2022-07-11 Thread Vaidehi Deshpande
On Mon, 11 Jul 2022 at 13:34, Vaidehi Deshpande < vaidehideshpand...@gmail.com> wrote: > Hello, > > I am Vaidehi and I am new to QEMU. I am working on emulating STM32F407 > board on QEMU and I am using eclipse IDE v4.24.0 and QEMU v7.0.0. I am > trying to check the SPI loopback but the loop gets s

[PATCH] [PATCH] linux-user/aarch64: Reset target data on MADV_DONTNEED

2022-07-11 Thread Vitaly Buka
aarch64 stores MTE tags in target_date, and they should be reset by MADV_DONTNEED. Signed-off-by: Vitaly Buka --- accel/tcg/translate-all.c | 24 include/exec/cpu-all.h| 1 + linux-user/mmap.c | 2 ++ 3 files changed, 27 insertions(+) diff --git a/accel/tc

Re: [PATCH] target/ppc/kvm: Skip ".." directory in kvmppc_find_cpu_dt

2022-07-11 Thread Daniel Henrique Barboza
On 7/11/22 16:37, Murilo Opsfelder Araujo wrote: Some systems have /proc/device-tree/cpus/../clock-frequency. However, this is not the expected path for a CPU device tree directory. Signed-off-by: Murilo Opsfelder Araujo Signed-off-by: Fabiano Rosas --- Reviewed-by: Daniel Henrique Barboz

Re: [PATCH] iotests: fix source directory location

2022-07-11 Thread John Snow
On Fri, May 27, 2022, 12:29 PM Kevin Wolf wrote: > Am 26.05.2022 um 16:21 hat John Snow geschrieben: > > On Thu, May 26, 2022, 3:54 AM Daniel P. Berrangé > > wrote: > > > > > On Wed, May 25, 2022 at 08:25:12PM -0400, John Snow wrote: > > > > If you invoke the check script from outside of the tes

Re: [PATCH] python: QEMUMachine: enable qmp accept timeout by default

2022-07-11 Thread John Snow
On Mon, Jul 11, 2022 at 5:16 PM John Snow wrote: > > On Fri, Jun 24, 2022 at 3:53 PM Vladimir Sementsov-Ogievskiy > wrote: > > > > I've spent much time trying to debug hanging pipeline in gitlab. I > > started from and idea that I have problem in code in my series (which > > has some timeouts). F

Re: [PATCH] python: QEMUMachine: enable qmp accept timeout by default

2022-07-11 Thread John Snow
On Fri, Jun 24, 2022 at 3:53 PM Vladimir Sementsov-Ogievskiy wrote: > > I've spent much time trying to debug hanging pipeline in gitlab. I > started from and idea that I have problem in code in my series (which > has some timeouts). Finally I found that the problem is that I've used > QEMUMachine

[PATCH v4 3/3] migration/multifd: Report to user when zerocopy not working

2022-07-11 Thread Leonardo Bras
Some errors, like the lack of Scatter-Gather support by the network interface(NETIF_F_SG) may cause sendmsg(...,MSG_ZEROCOPY) to fail on using zero-copy, which causes it to fall back to the default copying mechanism. After each full dirty-bitmap scan there should be a zero-copy flush happening, wh

[PATCH v4 2/3] Add dirty-sync-missed-zero-copy migration stat

2022-07-11 Thread Leonardo Bras
Signed-off-by: Leonardo Bras Acked-by: Markus Armbruster Reviewed-by: Daniel P. Berrangé --- qapi/migration.json | 7 ++- migration/migration.c | 2 ++ monitor/hmp-cmds.c| 5 + 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/qapi/migration.json b/qapi/migration.json

[PATCH v4 1/3] QIOChannelSocket: Fix zero-copy flush returning code 1 when nothing sent

2022-07-11 Thread Leonardo Bras
If flush is called when no buffer was sent with MSG_ZEROCOPY, it currently returns 1. This return code should be used only when Linux fails to use MSG_ZEROCOPY on a lot of sendmsg(). Fix this by returning early from flush if no sendmsg(...,MSG_ZEROCOPY) was attempted. Fixes: 2bc58ffc2926 ("QIOCha

[PATCH v4 0/3] Zero copy improvements (QIOChannel + multifd)

2022-07-11 Thread Leonardo Bras
The first patch avoid spuriously returning 1 [*] when zero-copy flush is attempted before any buffer was sent using MSG_ZEROCOPY. [*] zero-copy not being used, even though it's enabled and supported by kernel The second patch introduces a new migration stat (dirty-sync-missed-zero-copy) that will

Re: [PATCH RESEND] python/machine: Fix AF_UNIX path too long on macOS

2022-07-11 Thread John Snow
On Thu, Jul 7, 2022 at 2:46 PM Peter Delevoryas wrote: > > On Wed, Jul 06, 2022 at 05:52:48PM -0700, Peter Delevoryas wrote: > > On Wed, Jul 06, 2022 at 09:46:48AM -0700, Peter Delevoryas wrote: > > > On Wed, Jul 06, 2022 at 09:02:14AM +0100, Daniel P. Berrangé wrote: > > > > On Tue, Jul 05, 2022

Re: [PATCH v2 10/11] pytest: add pytest to the meson build system

2022-07-11 Thread John Snow
On Sun, Jul 10, 2022 at 1:01 PM Ani Sinha wrote: > > Integrate the pytest framework with the meson build system. This will make > meson > run all the pytests under the pytest directory. > > Signed-off-by: Ani Sinha > --- > tests/Makefile.include | 4 +++- > tests/meson.build| 1 + >

Re: [PATCH v2 07/11] acpi/tests/bits: add python test that exercizes QEMU bios tables using biosbits

2022-07-11 Thread John Snow
On Sun, Jul 10, 2022 at 1:01 PM Ani Sinha wrote: > > This change adds python based test environment that can be used to run pytest > from within a virtual environment. A bash script sets up a virtual environment > and then runs the python based tests from within that environment. > All dependent p

Re: [PATCH v2 01/11] acpi/tests/bits: initial commit of test scripts that are run by biosbits

2022-07-11 Thread John Snow
On Sun, Jul 10, 2022 at 1:01 PM Ani Sinha wrote: > > This is initial commit of cpuid, acpi and smbios python test scripts for > biosbits to execute. No change has been made to them from the original code > written by the biosbits author Josh Triplett. They are required to be > installed > into th

Re: [PATCH] python/qemu/qmp/legacy: Replace 'returns-whitelist' with the correct type

2022-07-11 Thread John Snow
On Mon, Jul 11, 2022 at 4:30 PM John Snow wrote: > > On Mon, Jul 11, 2022 at 5:57 AM Thomas Huth wrote: > > > > 'returns-whitelist' has been renamed to 'command-returns-exceptions' in > > commit b86df3747848 ("qapi: Rename pragma *-whitelist to *-exceptions"). > > > > Signed-off-by: Thomas Huth

Re: [PATCH] python/qemu/qmp/legacy: Replace 'returns-whitelist' with the correct type

2022-07-11 Thread John Snow
On Mon, Jul 11, 2022 at 5:57 AM Thomas Huth wrote: > > 'returns-whitelist' has been renamed to 'command-returns-exceptions' in > commit b86df3747848 ("qapi: Rename pragma *-whitelist to *-exceptions"). > > Signed-off-by: Thomas Huth > --- > python/qemu/qmp/legacy.py | 2 +- > 1 file changed, 1 i

Re: [PATCH] Replace 'whitelist' with 'allow'

2022-07-11 Thread John Snow
On Mon, Jul 11, 2022 at 5:53 AM Thomas Huth wrote: > > Let's use more inclusive language here and avoid terms > that are frowned upon nowadays. > > Signed-off-by: Thomas Huth Reviewed-by: John Snow > --- > docs/devel/submitting-a-patch.rst | 2 +- > docs/tools/qemu-nbd.rst | 2 +- >

Re: [PATCH v6 09/10] i386/pc: relocate 4g start to 1T where applicable

2022-07-11 Thread Joao Martins
On 7/11/22 16:31, Joao Martins wrote: > On 7/11/22 15:52, Joao Martins wrote: >> On 7/11/22 13:56, Igor Mammedov wrote: >>> On Fri, 1 Jul 2022 17:10:13 +0100 >>> Joao Martins wrote: >>> diff --git a/hw/i386/pc.c b/hw/i386/pc.c index a79fa1b6beeb..07025b510540 100644 --- a/hw/i386/p

Re: [PATCH v2] target/riscv: fix shifts shamt value for rv128c

2022-07-11 Thread Frédéric Pétrot
Hi Richard, Le 11/07/2022 à 06:44, Richard Henderson a écrit : On Sun, 10 July 2022, 16:36 Frédéric Pétrot, > wrote: For rv128c shifts, a shamt of 0 is a shamt of 64, while for rv32c/rv64c it stays 0 and is a hint instruction that does not

  1   2   3   >