[PATCH v2 0/2] python: a few improvements to qmp-shell

2022-01-18 Thread Daniel P . Berrangé
This makes the qmp-shell program a little more pleasant to use when you are just trying to spawn a throw-away QEMU process to query some info from. First it introduces a 'qmp-shell-wrap' command that takes a QEMU command line instead of QMP socket, and spawns QEMU automatically, so its life is

Re: [PATCH v2 1/2] target/ppc: Remove last user of .load_state_old

2022-01-18 Thread David Gibson
On Tue, Jan 18, 2022 at 11:41:49AM +0100, Cédric le Goater wrote: > This breaks migration compatibility from (very) old versions of > QEMU. This should not be a problem for the pseries machine for which > migration is only supported on recent QEMUs ( > 2.x). There is no > clear status on what is

Re: [PATCH v5 5/5] target/riscv: add support for svpbmt extension

2022-01-18 Thread Weiwei Li
在 2022/1/18 下午7:04, Anup Patel 写道: On Tue, Jan 18, 2022 at 2:40 PM Weiwei Li wrote: 在 2022/1/18 上午11:35, Anup Patel 写道: On Tue, Jan 18, 2022 at 6:47 AM Weiwei Li wrote: - add PTE_PBMT bits: It uses two PTE bits, but otherwise has no effect on QEMU, since QEMU is sequentially consistent

Re: [PATCH v5 1/5] target/riscv: Ignore reserved bits in PTE for RV64

2022-01-18 Thread Weiwei Li
在 2022/1/18 下午7:15, Guo Ren 写道: On Tue, Jan 18, 2022 at 4:51 PM Anup Patel wrote: On Tue, Jan 18, 2022 at 2:16 PM Guo Ren wrote: On Tue, Jan 18, 2022 at 11:32 AM Anup Patel wrote: On Tue, Jan 18, 2022 at 6:47 AM Weiwei Li wrote: From: Guo Ren Highest bits of PTE has been used for

[PULL 01/19] memory: Directly dispatch alias accesses on origin memory region

2022-01-18 Thread Philippe Mathieu-Daudé via
Since commit 2cdfcf272d ("memory: assign MemoryRegionOps to all regions"), all newly created regions are assigned with unassigned_mem_ops (which might be then overwritten). When using aliased container regions, and there is no region mapped at address 0 in the container, the

[PULL 11/19] hw/pci: Document pci_dma_map()

2022-01-18 Thread Philippe Mathieu-Daudé via
From: Philippe Mathieu-Daudé Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Michael S. Tsirkin Reviewed-by: Richard Henderson Message-Id: <2022084309.28637-5-f4...@amsat.org> Signed-off-by: Philippe Mathieu-Daudé --- include/hw/pci/pci.h | 12 1 file changed, 12

[PULL 03/19] memory: Have 'info mtree' remove duplicated Address Space information

2022-01-18 Thread Philippe Mathieu-Daudé via
From: Philippe Mathieu-Daudé Per Peter Maydell [*]: 'info mtree' monitor command was designed on the assumption that there's really only one or two interesting address spaces, and with more recent developments that's just not the case any more. Similarly about how the FlatView are sorted

[PULL 06/19] memory: Update description of memory_region_is_mapped()

2022-01-18 Thread Philippe Mathieu-Daudé via
From: David Hildenbrand Let's update the documentation, making it clearer what the semantics of memory_region_is_mapped() actually are. Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Peter Xu Signed-off-by: David Hildenbrand Message-Id: <20211102164317.45658-4-da...@redhat.com>

[PULL 4/9] tests: Fix typo in check-help output

2022-01-18 Thread Laurent Vivier
From: Philippe Mathieu-Daudé Fix typo in 'make check-help' output. Signed-off-by: Philippe Mathieu-Daudé Message-Id: <2022075528.22294-1-f4...@amsat.org> Signed-off-by: Laurent Vivier --- tests/Makefile.include | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PULL 9/9] linux-user: Remove MAX_SIGQUEUE_SIZE

2022-01-18 Thread Laurent Vivier
From: Warner Losh It's been unused for 7 years since 907f5fddaa67 when linux-user stopped queueing any signals. Signed-off-by: Warner Losh Reviewed-by: Peter Maydell Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20220116204423.16133-2-...@bsdimp.com> Signed-off-by: Laurent Vivier ---

Re: [RFC PATCH 3/3] tests/qtest/fuzz-sdcard-test: Add reproducer for OSS-Fuzz (Issue 29225)

2022-01-18 Thread Thomas Huth
On 15/12/2021 21.56, Philippe Mathieu-Daudé wrote: Include the qtest reproducer provided by Alexander Bulekov in https://gitlab.com/qemu-project/qemu/-/issues/451. Without the previous commit, we get: $ make check-qtest-i386 ... Running test qtest-i386/fuzz-sdcard-test

Re: [PATCH v2 1/3] qmp: Support for querying stats

2022-01-18 Thread Daniel P . Berrangé
On Tue, Jan 18, 2022 at 01:26:32PM +0100, Paolo Bonzini wrote: > On 1/17/22 16:17, Mark Kanda wrote: > > > > > > I agree except that I think this and StatsResults should be unions, > > > even if it means running multiple query-stats commands. > > > > IIUC, making StatsResults a union implies the

Re: [PATCH v3 3/3] meson: generate trace events for qmp commands

2022-01-18 Thread Markus Armbruster
Paolo Bonzini writes: > On 1/18/22 11:30, Markus Armbruster wrote: >>> +# Please keep ordering between 'qapi' and 'trace' subdirs: >>> +# We should first handle 'qapi' subdir, so that all >>> +# generated trace events be generated prior handling 'trace' >>> +# subdir. >> I naively expect

[PULL 12/31] ppc/pnv: move PCI registers to PnvPHB4

2022-01-18 Thread Cédric Le Goater
From: Daniel Henrique Barboza Previous patch changed pnv_pec_stk_pci_xscom_read() and pnv_pec_stk_pci_xscom_write() to use a PnvPHB4 opaque, making it easier to move both pci_regs[] and the pci_regs_mr MemoryRegion to the PnvHB4 object. Signed-off-by: Daniel Henrique Barboza Reviewed-by:

[PULL 02/31] docs: Rename ppc-spapr-hotplug.txt to ppc-spapr-hotplug.rst.

2022-01-18 Thread Cédric Le Goater
From: Leonardo Garcia Signed-off-by: Leonardo Garcia Reviewed-by: Daniel Henrique Barboza Message-Id: <1f5860217273f272fddadc68b5d205b4090f6b04.1641995058.git.lagar...@br.ibm.com> Signed-off-by: Cédric Le Goater --- docs/specs/{ppc-spapr-hotplug.txt => ppc-spapr-hotplug.rst} | 0 1 file

Re: [RFC PATCH 3/7] x86: Grant AMX permission for guest

2022-01-18 Thread Paolo Bonzini
Sorry, hit send on the wrong window. This is the only patch that will require a bit more work. On 1/18/22 13:52, Paolo Bonzini wrote: @@ -124,6 +150,8 @@ void x86_cpus_init(X86MachineState *x86ms, int default_cpu_version)   MachineState *ms = MACHINE(x86ms);   MachineClass *mc =

[PATCH v2 2/2] python: support recording QMP session to a file

2022-01-18 Thread Daniel P . Berrangé
When running QMP commands with very large response payloads, it is often not easy to spot the info you want. If we can save the response to a file then tools like 'grep' or 'jq' can be used to extract information. For convenience of processing, we merge the QMP command and response dictionaries

Re: [PATCH 5/8] hw/rdma/rdma_utils: Rename rdma_pci_dma_map 'len' argument

2022-01-18 Thread Yuval Shaia
On Fri, 31 Dec 2021 at 13:54, Philippe Mathieu-Daudé wrote: > Various APIs use 'pval' naming for 'pointer to val'. > rdma_pci_dma_map() uses 'plen' for 'PCI length', but since > 'PCI' is already explicit in the function name, simplify > and rename the argument 'len'. No logical change. > >

[PATCH v2 0/2] target/ppc: more cleanups around the 403 CPUs

2022-01-18 Thread Cédric Le Goater
Hello, This is a follow up of "target/ppc: Finish removal of 401/403 CPUs". To "finish" the removal, we need to get rid of the 403 protection registers under CPUPPCState. This is done after having removed the last user of .load_state_old. This change breaks migration compatibility with very old

Re: iotest 040, 041, intermittent failure in netbsd VM

2022-01-18 Thread Peter Maydell
On Mon, 17 Jan 2022 at 23:09, John Snow wrote: > Well, today I learned that: > > (1) vm-build-XXX targets use your host system's QEMU to run that VM > (2) my QMP library cannot talk to QEMU 2.11. Whoops, I hadn't realised I was running with that ancient a QEMU. For the scripted runs I set the

Re: [PATCH v2 1/2] target/ppc: Remove last user of .load_state_old

2022-01-18 Thread Peter Maydell
On Tue, 18 Jan 2022 at 11:18, Matheus K. Ferst wrote: > > On 18/01/2022 07:41, Cédric Le Goater wrote: > > This breaks migration compatibility from (very) old versions of > > QEMU. This should not be a problem for the pseries machine for which > > migration is only supported on recent QEMUs ( >

Re: [PATCH 2/3] linux-user: Rename user_force_sig tracepoint to match function name

2022-01-18 Thread Laurent Vivier
Le 14/01/2022 à 16:37, Peter Maydell a écrit : In commit c599d4d6d6e9bfdb64 in 2016 we renamed the old force_sig() function to dump_core_and_abort(), but we forgot to rename the associated tracepoint. Rename the tracepoint to to match the function it's called from. Signed-off-by: Peter Maydell

[PULL 04/19] machine: Use host_memory_backend_is_mapped() in machine_consume_memdev()

2022-01-18 Thread Philippe Mathieu-Daudé via
From: David Hildenbrand memory_region_is_mapped() is the wrong check, we actually want to check whether the backend is already marked mapped. For example, memory regions mapped via an alias, such as NVDIMMs, currently don't make memory_region_is_mapped() return "true". As the machine is

Re: [PATCH 0/3] ppc/pnv: Final refinements on PHB4s

2022-01-18 Thread Cédric Le Goater
On 1/17/22 13:27, Cédric Le Goater wrote: Hello, These are the last little tweaks on PHB4 to prepare ground for PHB5. Thanks, C. Cédric Le Goater (3): ppc/pnv: Move root port allocation under pnv_pec_default_phb_realize() ppc/pnv: Add a 'rp_model' class attribute for the PHB4 PEC

[PULL 13/19] hw/rdma/rdma_utils: Rename rdma_pci_dma_map 'len' argument

2022-01-18 Thread Philippe Mathieu-Daudé via
From: Philippe Mathieu-Daudé Various APIs use 'pval' naming for 'pointer to val'. rdma_pci_dma_map() uses 'plen' for 'PCI length', but since 'PCI' is already explicit in the function name, simplify and rename the argument 'len'. No logical change. Signed-off-by: Philippe Mathieu-Daudé

[PULL 00/19] Memory API patches for 2022-01-18

2022-01-18 Thread Philippe Mathieu-Daudé via
-20220118 for you to fetch changes up to 9d696cd50442327fd71ec7309e7b0c6fee693b1d: docs/devel: add some clarifying text for aliases (2022-01-18 12:56:29 +0100) Memory API patches - Directly dispatch MemoryRegion alias accesses - Remove

Re: [PATCH v3 3/3] meson: generate trace events for qmp commands

2022-01-18 Thread Paolo Bonzini
On 1/18/22 11:30, Markus Armbruster wrote: +# Please keep ordering between 'qapi' and 'trace' subdirs: +# We should first handle 'qapi' subdir, so that all +# generated trace events be generated prior handling 'trace' +# subdir. I naively expect explicit dependencies to be used for ordering,

[PULL 08/19] stubs: Restrict fw_cfg to system emulation

2022-01-18 Thread Philippe Mathieu-Daudé via
fw_cfg_arch_key_name() stub is only required for sysemu. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: David Hildenbrand Message-Id: <2022084309.28637-2-f4...@amsat.org> --- stubs/meson.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stubs/meson.build

Re: /usr/shared/qemu binaries

2022-01-18 Thread Paolo Bonzini
On 1/13/22 18:23, Peter Maydell wrote: On Thu, 13 Jan 2022 at 17:13, Paolo Bonzini wrote: On 1/12/22 14:56, Peter Maydell wrote: Those are UEFI firmware images which are suitable for using with the arm/aarch64 "virt" board. They're only used if the user specifically asks to use them on the

Re: [RFC PATCH 1/7] x86: Fix the 64-byte boundary enumeration for extended state

2022-01-18 Thread Paolo Bonzini
On 1/11/22 03:22, Yang Zhong wrote: Thanks Kevin, I will update this in next version. Also: The extended state subleaves (EAX=0Dh, ECX=n, n>1).ECX[1] indicate whether the extended state component locates on the next 64-byte boundary following the preceding state component

[PULL 5/9] softmmu: Provide a clue as to why device tree loading failed

2022-01-18 Thread Laurent Vivier
From: Bernhard Beschow fdt_open_into() obligingly returns an error code in case the operation failed. So be obliging as well and use it in the error message. Signed-off-by: Bernhard Beschow Reviewed-by: David Gibson Reviewed-by: Alistair Francis Reviewed-by: Philippe Mathieu-Daudé

[PULL 3/9] qdev-core.h: Fix wrongly named reference to TYPE_SPLIT_IRQ

2022-01-18 Thread Laurent Vivier
From: Peter Maydell Fix a comment in qdev-core.h where we incorrectly referred to TYPE_IRQ_SPLIT when we meant TYPE_SPLIT_IRQ. Signed-off-by: Peter Maydell Message-Id: <2022072655.3546766-1-peter.mayd...@linaro.org> Signed-off-by: Laurent Vivier --- include/hw/qdev-core.h | 2 +- 1 file

[PULL 16/31] ppc/pnv: move mmbar0/mmbar1 and friends to PnvPHB4

2022-01-18 Thread Cédric Le Goater
From: Daniel Henrique Barboza These 2 MemoryRegions, together with mmio(0|1)_base and mmio(0|1)_size variables, are used together in the same functions. We're better of moving them all in a single step. Signed-off-by: Daniel Henrique Barboza Reviewed-by: Cédric Le Goater Message-Id:

[PATCH v2 1/2] python: introduce qmp-shell-wrap convenience tool

2022-01-18 Thread Daniel P . Berrangé
With the current 'qmp-shell' tool developers must first spawn QEMU with a suitable -qmp arg and then spawn qmp-shell in a separate terminal pointing to the right socket. With 'qmp-shell-wrap' developers can ignore QMP sockets entirely and just pass the QEMU command and arguments they want. The

Re: [PATCH v5 5/5] target/riscv: add support for svpbmt extension

2022-01-18 Thread Anup Patel
On Tue, Jan 18, 2022 at 2:40 PM Weiwei Li wrote: > > > 在 2022/1/18 上午11:35, Anup Patel 写道: > > On Tue, Jan 18, 2022 at 6:47 AM Weiwei Li wrote: > >> - add PTE_PBMT bits: It uses two PTE bits, but otherwise has no effect on > >> QEMU, since QEMU is sequentially consistent and doesn't model PMAs

[PATCH v2 0/3] Improve RISC-V spike machine bios support

2022-01-18 Thread Anup Patel
This series aims at improving RISC-V spike machine BIOS support by allowing use of binary firmware as bios. Further, this also allows us to totally remove the ELF bios images shipped with QEMU RISC-V. These patches can also be found in riscv_spike_imp_v2 branch at:

[PATCH v2 2/3] hw/riscv: Remove macros for ELF BIOS image names

2022-01-18 Thread Anup Patel
Now that RISC-V Spike machine can use BIN BIOS images, we remove the macros used for ELF BIOS image names. Signed-off-by: Anup Patel --- hw/riscv/spike.c| 4 ++-- include/hw/riscv/boot.h | 2 -- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/hw/riscv/spike.c

Re: [PATCH v5 1/5] target/riscv: Ignore reserved bits in PTE for RV64

2022-01-18 Thread Anup Patel
On Tue, Jan 18, 2022 at 4:45 PM Guo Ren wrote: > > On Tue, Jan 18, 2022 at 4:51 PM Anup Patel wrote: > > > > On Tue, Jan 18, 2022 at 2:16 PM Guo Ren wrote: > > > > > > On Tue, Jan 18, 2022 at 11:32 AM Anup Patel wrote: > > > > > > > > On Tue, Jan 18, 2022 at 6:47 AM Weiwei Li wrote: > > > > >

Re: [PATCH v5 1/5] target/riscv: Ignore reserved bits in PTE for RV64

2022-01-18 Thread Guo Ren
On Tue, Jan 18, 2022 at 12:56 PM Alistair Francis wrote: > > On Tue, Jan 18, 2022 at 1:31 PM Anup Patel wrote: > > > > On Tue, Jan 18, 2022 at 6:47 AM Weiwei Li wrote: > > > > > > From: Guo Ren > > > > > > Highest bits of PTE has been used for svpbmt, ref: [1], [2], so we > > > need to ignore

[PULL 10/19] hw/pci: Restrict pci-bus stub to sysemu

2022-01-18 Thread Philippe Mathieu-Daudé via
From: Philippe Mathieu-Daudé Neither tools nor user-mode emulation require the PCI bus stub. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Michael S. Tsirkin Reviewed-by: Richard Henderson Reviewed-by: David Hildenbrand Message-Id: <2022084309.28637-4-f4...@amsat.org>

Re: [PATCH v2 0/8] remove PnvPhb4PecStack from Powernv9

2022-01-18 Thread Cédric Le Goater
On 1/14/22 19:07, Daniel Henrique Barboza wrote: Hi, This second version contains improvements suggested by Cedric in the v1 review. Patches 1-10 from v1 are already accepted and aren't included in this v2. Changes from v1: - v1 patches 1-10: already accepted, not included in the v2 -

Re: [PATCH v2 1/3] qmp: Support for querying stats

2022-01-18 Thread Paolo Bonzini
On 1/17/22 16:17, Mark Kanda wrote: I agree except that I think this and StatsResults should be unions, even if it means running multiple query-stats commands. IIUC, making StatsResults a union implies the filter is a required argument (currently it is optional - omitting it dumps all VM

[PULL 0/9] Trivial branch for 7.0 patches

2022-01-18 Thread Laurent Vivier
-branch-for-7.0-pull-request for you to fetch changes up to bfadf13f63d63d099bf2be14c9b1863f25a091a2: linux-user: Remove MAX_SIGQUEUE_SIZE (2022-01-18 12:44:44 +0100) trivial patches pull request 20220118 Fix comments and typos

Re: [RFC PATCH 3/7] x86: Grant AMX permission for guest

2022-01-18 Thread Paolo Bonzini
On 1/7/22 10:31, Yang Zhong wrote: +static void x86_xsave_req_perm(void) +{ +unsigned long bitmask; + +long rc = syscall(SYS_arch_prctl, ARCH_REQ_XCOMP_GUEST_PERM, + XSTATE_XTILE_DATA_BIT); +if (rc) { +/* + * The older kernel version(<5.15) can't

[PULL 00/31] ppc queue

2022-01-18 Thread Cédric Le Goater
The following changes since commit 6621441db50d5bae7e34dbd04bf3c57a27a71b32: Merge remote-tracking branch 'remotes/mcayland/tags/qemu-openbios-20220115' into staging (2022-01-16 20:12:23 +) are available in the Git repository at: https://github.com/legoater/qemu/ tags/pull-ppc-20220118

Re: [PATCH v3 2/3] scripts/qapi-gen.py: add --add-trace-events option

2022-01-18 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > Add and option to generate trace events. We should generate both trace > events and trace-events files for further trace events code generation. Can you explain why we want trace generation to be optional? > Signed-off-by: Vladimir Sementsov-Ogievskiy >

Re: [PATCH v3 1/3] scripts/qapi/gen.py: add .trace-events file for module

2022-01-18 Thread Vladimir Sementsov-Ogievskiy
18.01.2022 11:38, Markus Armbruster wrote: Vladimir Sementsov-Ogievskiy writes: We are going to generate trace events for qmp commands. We should generate both trace events and trace-events. What do you mean to say with the second sentence? "trace events" == the calls of generated

[PATCH v2 1/3] hw/riscv: spike: Allow using binary firmware as bios

2022-01-18 Thread Anup Patel
Currently, we have to use OpenSBI firmware ELF as bios for the spike machine because the HTIF console requires ELF for parsing "fromhost" and "tohost" symbols. The latest OpenSBI can now optionally pick-up HTIF register address from HTIF DT node so using this feature spike machine can now use

[PULL 1/2] seabios: update submodule to snapshot

2022-01-18 Thread Gerd Hoffmann
Most important update is smbios3 support being added, this update should help getting the qemu side of things (flip to smbios3 by default for new machine types) merged and tested. Not fully clear yet when the next 1.16 seabios version will be released, but it should be no later than end of

[PULL 0/2] Seabios 20220118 patches

2022-01-18 Thread Gerd Hoffmann
The following changes since commit 6621441db50d5bae7e34dbd04bf3c57a27a71b32: Merge remote-tracking branch 'remotes/mcayland/tags/qemu-openbios-20220115' into staging (2022-01-16 20:12:23 +) are available in the Git repository at: git://git.kraxel.org/qemu tags/seabios-20220118-pull

Re: [PATCH v3 2/3] scripts/qapi-gen.py: add --add-trace-events option

2022-01-18 Thread Vladimir Sementsov-Ogievskiy
18.01.2022 13:27, Markus Armbruster wrote: Vladimir Sementsov-Ogievskiy writes: Add and option to generate trace events. We should generate both trace events and trace-events files for further trace events code generation. Can you explain why we want trace generation to be optional?

[PULL 07/19] memory: Fix incorrect calls of log_global_start/stop

2022-01-18 Thread Philippe Mathieu-Daudé via
From: Peter Xu We should only call the log_global_start/stop when the global dirty track bitmask changes from zero<->non-zero. No real issue reported for this yet probably because no immediate user to enable both dirty rate measurement and migration at the same time. However it'll be good to

[PULL 09/19] hw/nvram: Restrict fw_cfg QOM interface to sysemu and tools

2022-01-18 Thread Philippe Mathieu-Daudé via
From: Philippe Mathieu-Daudé fw_cfg QOM interface is required by system emulation and qemu-storage-daemon. User-mode emulation doesn't need it. Signed-off-by: Philippe Mathieu-Daudé Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: David Hildenbrand Message-Id:

[PULL 04/31] rSTify ppc-spapr-uv-hcalls.txt.

2022-01-18 Thread Cédric Le Goater
From: Leonardo Garcia Signed-off-by: Leonardo Garcia Reviewed-by: Daniel Henrique Barboza Message-Id: <243a714d3861f7539d29b02a899ffc376757d668.1642446876.git.lagar...@br.ibm.com> Signed-off-by: Cédric Le Goater --- docs/specs/ppc-spapr-uv-hcalls.txt | 165 - 1

tracing.rst neglects to document syntax of trace-events files

2022-01-18 Thread Markus Armbruster
Almost[*] all trace-events files start with this line: # See docs/devel/tracing.rst for syntax documentation. But I can't find syntax documentation there. [*] Exceptions: $ git-ls-files \*/trace-events| xargs fgrep -L '# See docs/devel/tracing.rst for syntax documentation.'

Re: [PATCH v3 0/3] memory: memory_region_is_mapped() cleanups

2022-01-18 Thread David Hildenbrand
On 02.11.21 17:43, David Hildenbrand wrote: > Playing with memory_region_is_mapped(), I realized that memory regions > mapped via an alias behave a little bit "differently", as they don't have > their ->container set. > * memory_region_is_mapped() will never succeed for memory regions mapped >

Re: [PATCH v4 0/5] target/s390x: Fix shift instructions

2022-01-18 Thread Thomas Huth
On 12/01/2022 17.50, Ilya Leoshkevich wrote: v3: https://lists.nongnu.org/archive/html/qemu-devel/2022-01/msg02680.html v3 -> v4: Simplify cc_calc_sla(). Free temporaries. v2: https://lists.nongnu.org/archive/html/qemu-devel/2022-01/msg02488.html v2 -> v3: Unify CC_OP_SLA_32 and

Re: [PATCH 1/8] target/ppc: 405: Add missing MSR bits to msr_mask

2022-01-18 Thread David Gibson
On Mon, Jan 17, 2022 at 06:12:20PM -0300, Fabiano Rosas wrote: > Fabiano Rosas writes: > > > Some bits described in the user manual are missing from msr_mask. Add > > them. > > > > Signed-off-by: Fabiano Rosas > > --- > > target/ppc/cpu_init.c | 6 +- > > 1 file changed, 5 insertions(+), 1

Re: [RFC PATCH v3 7/7] gitlab-ci: Support macOS 12 via cirrus-run

2022-01-18 Thread Thomas Huth
On 13/01/2022 12.41, Philippe Mathieu-Daudé wrote: On 13/1/22 08:39, Thomas Huth wrote: On 10/01/2022 14.10, Philippe Mathieu-Daudé wrote: Add support for macOS 12 build on Cirrus-CI, similarly to commit 0e103a65ba1 ("gitlab: support for ... macOS 11 via cirrus-run"). Update the lcitool

Re: [PATCH v4] memory: Directly dispatch alias accesses on origin memory region

2022-01-18 Thread Philippe Mathieu-Daudé via
On 4/18/21 07:57, Philippe Mathieu-Daudé wrote: > Since commit 2cdfcf272d ("memory: assign MemoryRegionOps to all > regions"), all newly created regions are assigned with > unassigned_mem_ops (which might be then overwritten). > > When using aliased container regions, and there is no region

Re: [PATCH v3 3/3] meson: generate trace events for qmp commands

2022-01-18 Thread Markus Armbruster
Vladimir Sementsov-Ogievskiy writes: > 1. Use --add-trace-events when generate qmp commands > 2. Add corresponding .trace-events files as outputs in qapi_files >custom target > 3. Define global qapi_trace_events list of .trace-events file targets, >to fill in trace/qapi.build and to use

[PATCH v2 2/2] target/ppc: Finish removal of 401/403 CPUs

2022-01-18 Thread Cédric Le Goater
Commit c8f49e6b938e ("target/ppc: remove 401/403 CPUs") left a few things behind. Reviewed-by: Fabiano Rosas Reviewed-by: David Gibson Message-Id: <20220117091541.1615807-1-...@kaod.org> Signed-off-by: Cédric Le Goater --- Changes in v2: - Removal of the 403 protection registers

Re: [PATCH v2 1/2] target/ppc: Remove last user of .load_state_old

2022-01-18 Thread Matheus K. Ferst
On 18/01/2022 07:41, Cédric Le Goater wrote: This breaks migration compatibility from (very) old versions of QEMU. This should not be a problem for the pseries machine for which migration is only supported on recent QEMUs ( > 2.x). There is no clear status on what is supported or not for the

Re: [PATCH] softmmu: Provide a clue as to why device tree loading failed

2022-01-18 Thread Laurent Vivier
Le 16/01/2022 à 12:46, Bernhard Beschow a écrit : fdt_open_into() obligingly returns an error code in case the operation failed. So be obliging as well and use it in the error message. Signed-off-by: Bernhard Beschow --- softmmu/device_tree.c | 6 -- 1 file changed, 4 insertions(+), 2

Re: [PATCH] Remove unnecessary minimum_version_id_old fields

2022-01-18 Thread Peter Maydell
On Tue, 18 Jan 2022 at 10:44, Peter Maydell wrote: > > The migration code will not look at a VMStateDescription's > minimum_version_id_old field unless that VMSD has set the > load_state_old field to something non-NULL. (The purpose of > minimum_version_id_old is to specify what migration

Re: [RFC PATCH] linux-user: expand reserved brk space for 64bit guests

2022-01-18 Thread Thomas Huth
On 13/01/2022 17.55, Alex Bennée wrote: A recent change to fix commpage allocation issues on 32bit hosts revealed another intermittent issue on s390x. The root cause was the headroom we give for the brk space wasn't enough causing the guest to attempt to map something on top of QEMUs own pages.

Re: [PATCH] target/ppc: Fix 7748 support

2022-01-18 Thread Cédric Le Goater
On 1/17/22 10:25, Cédric Le Goater wrote: The 7448 CPU is an evolution of the PowerPC 7447A and the last of the G4 family. Change its family to reflect correctly its features. This fixes Linux boot. Cc: Fabiano Rosas Signed-off-by: Cédric Le Goater --- target/ppc/cpu-models.c | 8

Re: [PATCH RESEND] tests/avocado: ppc: Add smoke tests for MPC7400 and MPC7450 families

2022-01-18 Thread Cédric Le Goater
On 1/17/22 15:47, Fabiano Rosas wrote: These tests ensure that our emulation for these cpus is not completely broken and we can at least run OpenBIOS on them. $ make check-avocado AVOCADO_TESTS=../tests/avocado/ppc_74xx.py Signed-off-by: Fabiano Rosas Reviewed-by: Willian Rampazzo Applied

Re: [PATCH v2 0/2] target/ppc: more cleanups around the 403 CPUs

2022-01-18 Thread Cédric Le Goater
On 1/18/22 11:41, Cédric Le Goater wrote: Hello, This is a follow up of "target/ppc: Finish removal of 401/403 CPUs". To "finish" the removal, we need to get rid of the 403 protection registers under CPUPPCState. This is done after having removed the last user of .load_state_old. This change

Re: [PATCH 0/3] rSTify ppc-spapr-hotplug.txt

2022-01-18 Thread Cédric Le Goater
On 1/12/22 14:52, lagar...@linux.ibm.com wrote: From: Leonardo Garcia This patch series depend on previously sent patch "docs: Clarification and formatting changes in ppc docs." which is already included in latest pull request from Cédric. It is important to notice that I focused mainly in

[PULL 02/19] memory: Split mtree_info() as mtree_info_flatview() + mtree_info_as()

2022-01-18 Thread Philippe Mathieu-Daudé via
From: Philippe Mathieu-Daudé While mtree_info() handles both ASes and flatviews cases, the two cases share basically no code. Split mtree_info() as mtree_info_flatview() + mtree_info_as() to simplify. Suggested-by: Peter Maydell Reviewed-by: David Hildenbrand Reviewed-by: Peter Xu

[PULL 1/9] hw/timer/etraxfs_timer: Add vmstate for ETRAX timers

2022-01-18 Thread Laurent Vivier
From: Philippe Mathieu-Daudé Add the vmstate for the ETRAX timers. This is in theory a migration compatibility break for the 'AXIS devboard 88' CRIS machine. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Message-Id: <20211106105623.510868-1-f4...@amsat.org>

[PULL 17/19] hw/dma: Use dma_addr_t type definition when relevant

2022-01-18 Thread Philippe Mathieu-Daudé via
From: Philippe Mathieu-Daudé Update the obvious places where dma_addr_t should be used (instead of uint64_t, hwaddr, size_t, int32_t types). This allows to have _addr_t type portable on 32/64-bit hosts. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: David Hildenbrand Signed-off-by:

[PULL 12/19] hw/dma: Remove CONFIG_USER_ONLY check

2022-01-18 Thread Philippe Mathieu-Daudé via
From: Philippe Mathieu-Daudé DMA API should not be included in user-mode emulation. If so, build should fail. Remove the CONFIG_USER_ONLY check. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Reviewed-by: David Hildenbrand Message-Id:

Re: [RFC PATCH 2/7] x86: Add AMX XTILECFG and XTILEDATA components

2022-01-18 Thread Paolo Bonzini
On 1/10/22 09:23, Tian, Kevin wrote: AMX XTILECFG and XTILEDATA are managed by XSAVE feature set. State component 17 is used for 64-byte TILECFG register (XTILECFG state) and component 18 is used for 8192 bytes of tile data (XTILEDATA state). to be consistent, "tile data" -> "TILEDATA"

[PATCH] Remove unnecessary minimum_version_id_old fields

2022-01-18 Thread Peter Maydell
The migration code will not look at a VMStateDescription's minimum_version_id_old field unless that VMSD has set the load_state_old field to something non-NULL. (The purpose of minimum_version_id_old is to specify what migration version is needed for the code in the function pointed to by

[PATCH v2 1/2] target/ppc: Remove last user of .load_state_old

2022-01-18 Thread Cédric Le Goater
This breaks migration compatibility from (very) old versions of QEMU. This should not be a problem for the pseries machine for which migration is only supported on recent QEMUs ( > 2.x). There is no clear status on what is supported or not for the other machines. Let's move forward and remove the

Re: [PATCH v5 1/5] target/riscv: Ignore reserved bits in PTE for RV64

2022-01-18 Thread Guo Ren
On Tue, Jan 18, 2022 at 4:51 PM Anup Patel wrote: > > On Tue, Jan 18, 2022 at 2:16 PM Guo Ren wrote: > > > > On Tue, Jan 18, 2022 at 11:32 AM Anup Patel wrote: > > > > > > On Tue, Jan 18, 2022 at 6:47 AM Weiwei Li wrote: > > > > > > > > From: Guo Ren > > > > > > > > Highest bits of PTE has

Re: [PATCH v5 1/5] target/riscv: Ignore reserved bits in PTE for RV64

2022-01-18 Thread Anup Patel
On Tue, Jan 18, 2022 at 4:45 PM Guo Ren wrote: > > On Tue, Jan 18, 2022 at 4:51 PM Anup Patel wrote: > > > > On Tue, Jan 18, 2022 at 2:16 PM Guo Ren wrote: > > > > > > On Tue, Jan 18, 2022 at 11:32 AM Anup Patel wrote: > > > > > > > > On Tue, Jan 18, 2022 at 6:47 AM Weiwei Li wrote: > > > > >

Re: [PATCH 1/2] linx-user: Remove MAX_SIGQUEUE_SIZE

2022-01-18 Thread Laurent Vivier
Le 16/01/2022 à 21:44, Warner Losh a écrit : It's been unused for 7 years since 907f5fddaa67 when linux-user stopped queueing any signals. Signed-off-by: Warner Losh --- linux-user/qemu.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/linux-user/qemu.h b/linux-user/qemu.h index

Re: [PATCH 0/3] rSTify ppc-spapr-uv-hcalls.txt.

2022-01-18 Thread Cédric Le Goater
On 1/17/22 20:19, lagar...@linux.ibm.com wrote: From: Leonardo Garcia Leonardo Garcia (3): rSTify ppc-spapr-uv-hcalls.txt. Rename ppc-spapr-uv-hcalls.txt to ppc-spapr-uv-hcalls.rst. Link new ppc-spapr-uv-hcalls.rst to pseries.rst. docs/specs/ppc-spapr-uv-hcalls.rst | 89

[PULL 16/19] hw/dma: Move ScatterGatherEntry / QEMUSGList declarations around

2022-01-18 Thread Philippe Mathieu-Daudé via
In the next commit we will use the dma_addr_t type in the QEMUSGList structure. Since currently dma_addr_t is defined after QEMUSGList, move the declarations to have dma_addr_t defined first. This is a pure code-movement patch. Suggested-by: David Hildenbrand Signed-off-by: Philippe

[PULL 7/9] linux-user: Rename user_force_sig tracepoint to match function name

2022-01-18 Thread Laurent Vivier
From: Peter Maydell In commit c599d4d6d6e9bfdb64 in 2016 we renamed the old force_sig() function to dump_core_and_abort(), but we forgot to rename the associated tracepoint. Rename the tracepoint to to match the function it's called from. Signed-off-by: Peter Maydell Reviewed-by: Philippe

Re: [RFC PATCH 4/7] x86: Add XFD faulting bit for state components

2022-01-18 Thread Paolo Bonzini
On 1/7/22 10:31, Yang Zhong wrote: -uint32_t need_align; +uint32_t need_align, support_xfd; These can be replaced by a single field "uint32_t ecx". You can add also macros like #define ESA_FEATURE_ALIGN64_BIT (1) #define ESA_FEATURE_XFD_BIT (2) to simplify access. Paolo

Re: [PATCH 1/2] python: introduce qmp-shell-wrap convenience tool

2022-01-18 Thread Daniel P . Berrangé
On Mon, Jan 17, 2022 at 06:27:24PM -0500, John Snow wrote: > On Mon, Jan 17, 2022 at 9:11 AM Daniel P. Berrangé > wrote: > > > > With the current 'qmp-shell' tool developers must first spawn QEMU with > > a suitable -qmp arg and then spawn qmp-shell in a separate terminal > > pointing to the

Re: [PATCH] linux-user: Fix comment typo in arm cpu_loop code

2022-01-18 Thread Laurent Vivier
Le 14/01/2022 à 19:25, Peter Maydell a écrit : Fix a typo in a comment in the arm cpu_loop code. Signed-off-by: Peter Maydell --- linux-user/arm/cpu_loop.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/linux-user/arm/cpu_loop.c b/linux-user/arm/cpu_loop.c index

Re: [PATCH 3/3] linux-user: Return void from queue_signal()

2022-01-18 Thread Laurent Vivier
Le 14/01/2022 à 16:37, Peter Maydell a écrit : The linux-user queue_signal() function always returns 1, and none of its callers check the return value. Give it a void return type instead. The return value is a leftover from the old pre-2016 linux-user signal handling code, which really did

Re: [PATCH v5 1/5] target/riscv: Ignore reserved bits in PTE for RV64

2022-01-18 Thread Guo Ren
On Tue, Jan 18, 2022 at 7:28 PM Anup Patel wrote: > > On Tue, Jan 18, 2022 at 4:45 PM Guo Ren wrote: > > > > On Tue, Jan 18, 2022 at 4:51 PM Anup Patel wrote: > > > > > > On Tue, Jan 18, 2022 at 2:16 PM Guo Ren wrote: > > > > > > > > On Tue, Jan 18, 2022 at 11:32 AM Anup Patel wrote: > > > >

[PULL 05/19] memory: Make memory_region_is_mapped() succeed when mapped via an alias

2022-01-18 Thread Philippe Mathieu-Daudé via
From: David Hildenbrand memory_region_is_mapped() currently does not return "true" when a memory region is mapped via an alias. Assuming we have: alias (A0) -> alias (A1) -> region (R0) Mapping A0 would currently only make memory_region_is_mapped() succeed on A0, but not on A1 and R0.

Re: iotest 040, 041, intermittent failure in netbsd VM

2022-01-18 Thread Peter Maydell
On Mon, 17 Jan 2022 at 20:35, John Snow wrote: > I do expect this to print more information on failure than it > currently is, though (bug somewhere in machine.py, I think). > Can you please try applying this temporary patch and running `./check > -qcow2 040 041` until you see a breakage and show

[PULL 19/19] docs/devel: add some clarifying text for aliases

2022-01-18 Thread Philippe Mathieu-Daudé via
From: Alex Bennée We do mention the limitation of single parenthood for memory_region_add_subregion but lets also make it clear how aliases help solve that conundrum. Signed-off-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20220110175104.2908956-7-alex.ben...@linaro.org>

[PULL 2/9] hw/scsi/megasas: Simplify using the ldst API

2022-01-18 Thread Laurent Vivier
From: Philippe Mathieu-Daudé This code is easier to review using the load/store API. Reviewed-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé Message-Id: <20211218111912.1499377-1-phi...@redhat.com> Signed-off-by: Laurent Vivier --- hw/scsi/megasas.c | 17 +++-- 1

[PULL 18/19] hw/dma: Let dma_buf_read() / dma_buf_write() propagate MemTxResult

2022-01-18 Thread Philippe Mathieu-Daudé via
From: Philippe Mathieu-Daudé Since commit 292e13142d2, dma_buf_rw() returns a MemTxResult type. Do not discard it, return it to the caller. Pass the previously returned value (the QEMUSGList residual size, which was rarely used) as an optional argument. With this new API, SCSIRequest::residual

[PULL 14/19] hw/scsi: Rename SCSIRequest::resid as 'residual'

2022-01-18 Thread Philippe Mathieu-Daudé via
From: Philippe Mathieu-Daudé The 'resid' field is slightly confusing and could be interpreted as some ID. Rename it as 'residual' which is clearer to review. No logical change. Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Reviewed-by: David Hildenbrand Message-Id:

[PULL 15/19] hw/dma: Fix format string issues using dma_addr_t

2022-01-18 Thread Philippe Mathieu-Daudé via
Reviewed-by: Richard Henderson Reviewed-by: David Hildenbrand Signed-off-by: Philippe Mathieu-Daudé Message-Id: <2022084309.28637-10-f4...@amsat.org> --- hw/ide/ahci.c| 2 +- hw/rdma/trace-events | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/ide/ahci.c

[PULL 6/9] linux-user: Fix comment typo in arm cpu_loop code

2022-01-18 Thread Laurent Vivier
From: Peter Maydell Fix a typo in a comment in the arm cpu_loop code. Signed-off-by: Peter Maydell Reviewed-by: Warner Losh Message-Id: <20220114182535.3804783-1-peter.mayd...@linaro.org> Signed-off-by: Laurent Vivier --- linux-user/arm/cpu_loop.c | 4 ++-- 1 file changed, 2 insertions(+),

[PULL 8/9] linux-user: Return void from queue_signal()

2022-01-18 Thread Laurent Vivier
From: Peter Maydell The linux-user queue_signal() function always returns 1, and none of its callers check the return value. Give it a void return type instead. The return value is a leftover from the old pre-2016 linux-user signal handling code, which really did have a queue of signals and so

Re: [PATCH v4 2/7] target/riscv: rvk: add implementation of instructions for Zbk*

2022-01-18 Thread Weiwei Li
在 2022/1/18 下午12:40, Alistair Francis 写道: On Tue, Jan 11, 2022 at 1:56 PM Weiwei Li wrote: - reuse partial instructions of Zbb/Zbc extensions - add brev8, packh, unzip, zip, etc. Signed-off-by: Weiwei Li Signed-off-by: Junqiang Wang --- target/riscv/bitmanip_helper.c |

Re: [PATCH v5 3/5] target/riscv: add support for svnapot extension

2022-01-18 Thread Weiwei Li
在 2022/1/18 上午11:32, Anup Patel 写道: On Tue, Jan 18, 2022 at 6:47 AM Weiwei Li wrote: - add PTE_N bit - add PTE_N bit check for inner PTE - update address translation to support 64KiB continuous region (napot_bits = 4) Signed-off-by: Weiwei Li Signed-off-by: Junqiang Wang Cc: Anup Patel

Re: [PATCH v5 5/5] target/riscv: add support for svpbmt extension

2022-01-18 Thread Weiwei Li
在 2022/1/18 上午11:35, Anup Patel 写道: On Tue, Jan 18, 2022 at 6:47 AM Weiwei Li wrote: - add PTE_PBMT bits: It uses two PTE bits, but otherwise has no effect on QEMU, since QEMU is sequentially consistent and doesn't model PMAs currently - add PTE_PBMT bit check for inner PTE Signed-off-by:

  1   2   3   4   >