]> git.ipfire.org Git - thirdparty/qemu.git/log
thirdparty/qemu.git
7 weeks agoinclude/qemu: Remove ifndef CONFIG_USER_ONLY from accel.h
Richard Henderson [Thu, 13 Mar 2025 03:18:08 +0000 (20:18 -0700)] 
include/qemu: Remove ifndef CONFIG_USER_ONLY from accel.h

While setup_post and has_memory will not be used for
CONFIG_USER_ONLY, let the struct have constant layout.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/system: Remove ifndef CONFIG_USER_ONLY in qtest.h
Richard Henderson [Thu, 13 Mar 2025 03:15:41 +0000 (20:15 -0700)] 
include/system: Remove ifndef CONFIG_USER_ONLY in qtest.h

This is include/system, so CONFIG_USER_ONLY will never be true.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/exec: Protect icount_enabled from poisoned symbols
Richard Henderson [Fri, 14 Mar 2025 20:15:07 +0000 (13:15 -0700)] 
include/exec: Protect icount_enabled from poisoned symbols

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/exec: Split out icount.h
Richard Henderson [Fri, 14 Mar 2025 19:57:31 +0000 (12:57 -0700)] 
include/exec: Split out icount.h

Split icount stuff from system/cpu-timers.h.
There are 17 files which only require icount.h, 7 that only
require cpu-timers.h, and 7 that require both.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/hw/s390x: Remove ifndef CONFIG_USER_ONLY in css.h
Richard Henderson [Thu, 13 Mar 2025 03:12:17 +0000 (20:12 -0700)] 
include/hw/s390x: Remove ifndef CONFIG_USER_ONLY in css.h

We were hiding a number of declarations from user-only,
although it hurts nothing to allow them.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/hw/intc: Remove ifndef CONFIG_USER_ONLY from armv7m_nvic.h
Richard Henderson [Thu, 13 Mar 2025 03:11:41 +0000 (20:11 -0700)] 
include/hw/intc: Remove ifndef CONFIG_USER_ONLY from armv7m_nvic.h

We were hiding a number of declarations from user-only,
although it hurts nothing to allow them.  The inlines
for user-only are unused.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/hw/core: Drop ifndef CONFIG_USER_ONLY from cpu.h
Richard Henderson [Thu, 13 Mar 2025 03:10:02 +0000 (20:10 -0700)] 
include/hw/core: Drop ifndef CONFIG_USER_ONLY from cpu.h

We were hiding a number of declarations from user-only,
although it hurts nothing to allow them.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/exec: Drop ifndef CONFIG_USER_ONLY from cpu-common.h
Richard Henderson [Thu, 13 Mar 2025 03:08:44 +0000 (20:08 -0700)] 
include/exec: Drop ifndef CONFIG_USER_ONLY from cpu-common.h

We were hiding a number of declarations from user-only,
although it hurts nothing to allow them.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoplugins: Move api.c, core.c to libuser_ss, libsystem_ss
Richard Henderson [Thu, 13 Mar 2025 02:46:44 +0000 (19:46 -0700)] 
plugins: Move api.c, core.c to libuser_ss, libsystem_ss

Headers used by these files require CONFIG_USER_ONLY.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agosystem: Move most files to libsystem_ss
Richard Henderson [Thu, 13 Mar 2025 02:45:50 +0000 (19:45 -0700)] 
system: Move most files to libsystem_ss

Some of the headers used require CONFIG_USER_ONLY.
Do not move vl.c, because it has other include dependencies
that are present in system_ss.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agohw/core: Move unconditional files to libsystem_ss, libuser_ss
Richard Henderson [Thu, 13 Mar 2025 02:45:02 +0000 (19:45 -0700)] 
hw/core: Move unconditional files to libsystem_ss, libuser_ss

Many of the headers used by these require CONFIG_USER_ONLY.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/exec: Split out watchpoint.h
Richard Henderson [Fri, 14 Mar 2025 17:39:19 +0000 (10:39 -0700)] 
include/exec: Split out watchpoint.h

Relatively few objects in qemu care about watchpoints, so split
out to a new header.  Removes an instance of CONFIG_USER_ONLY
from hw/core/cpu.h.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agosemihosting: Assert is_user in user-only semihosting_enabled
Richard Henderson [Thu, 20 Mar 2025 23:09:51 +0000 (16:09 -0700)] 
semihosting: Assert is_user in user-only semihosting_enabled

Suggested-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agosemihosting: Move user-only implementation out-of-line
Richard Henderson [Thu, 13 Mar 2025 00:16:05 +0000 (17:16 -0700)] 
semihosting: Move user-only implementation out-of-line

Avoid testing CONFIG_USER_ONLY in semihost.h.
The only function that's required is semihosting_enabled.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agotarget/xtensa: Restrict semihosting tests to system mode
Richard Henderson [Mon, 17 Mar 2025 16:36:32 +0000 (09:36 -0700)] 
target/xtensa: Restrict semihosting tests to system mode

We do not set CONFIG_SEMIHOSTING in
configs/targets/xtensa*-linux-user.mak.

Do not raise SIGILL for user-only unconditionally.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agotarget/mips: Restrict semihosting tests to system mode
Richard Henderson [Sun, 16 Mar 2025 22:48:07 +0000 (15:48 -0700)] 
target/mips: Restrict semihosting tests to system mode

We do not set CONFIG_SEMIHOSTING in
configs/targets/mips*-linux-user.mak.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoaccel/tcg: Use libuser_ss and libsystem_ss
Richard Henderson [Wed, 12 Mar 2025 21:55:21 +0000 (14:55 -0700)] 
accel/tcg: Use libuser_ss and libsystem_ss

While some of these files are built exactly once, due
to being in only libuser_ss or libsystem_ss, some of
the includes that they depend on require CONFIG_USER_ONLY.
So make use of the common infrastructure to allow that.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agogdbstub: Move syscalls.c out of common_ss
Richard Henderson [Wed, 12 Mar 2025 21:37:07 +0000 (14:37 -0700)] 
gdbstub: Move syscalls.c out of common_ss

Copy to libuser_ss and libsystem_ss.
This file uses semihosting/semihost.h, which has separate
implementations with and without CONFIG_USER_ONLY.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agomeson: Introduce top-level libuser_ss and libsystem_ss
Richard Henderson [Wed, 12 Mar 2025 21:33:07 +0000 (14:33 -0700)] 
meson: Introduce top-level libuser_ss and libsystem_ss

We already have two subdirectories for which we need
to build files twice, for user vs system modes.
Move this handling to the top level.

This cannot be combined with user_ss or system_ss,
because the formulation has not been extended to support
configuration symbols.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoexec: Restrict memory-internal.h to system/
Philippe Mathieu-Daudé [Mon, 17 Mar 2025 16:13:29 +0000 (17:13 +0100)] 
exec: Restrict memory-internal.h to system/

Only file units within the system/ directory need access to
"memory-internal.h". Restrict its scope by moving it there.

The comment from commit 9d70618c684 ("memory-internal.h:
Remove obsolete claim that header is obsolete") is now obsolete,
remove it.

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: David Hildenbrand <david@redhat.com>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317161329.40300-3-philmd@linaro.org>

7 weeks agoaccel/tcg: Remove unnecesary inclusion of memory-internal.h in cputlb.c
Philippe Mathieu-Daudé [Mon, 17 Mar 2025 16:13:28 +0000 (17:13 +0100)] 
accel/tcg: Remove unnecesary inclusion of memory-internal.h in cputlb.c

At some point cputlb.c stopped depending on the
"exec/memory-internal.h" header. Clean that now.

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Reviewed-by: David Hildenbrand <david@redhat.com>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317161329.40300-2-philmd@linaro.org>

7 weeks agoinclude/system: Move exec/ramblock.h to system/ramblock.h
Richard Henderson [Thu, 13 Mar 2025 02:03:02 +0000 (19:03 -0700)] 
include/system: Move exec/ramblock.h to system/ramblock.h

Convert the existing includes with sed.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/system: Move exec/ram_addr.h to system/ram_addr.h
Richard Henderson [Thu, 13 Mar 2025 00:42:03 +0000 (17:42 -0700)] 
include/system: Move exec/ram_addr.h to system/ram_addr.h

Convert the existing includes with sed.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/system: Move exec/ioport.h to system/ioport.h
Richard Henderson [Wed, 12 Mar 2025 19:49:38 +0000 (12:49 -0700)] 
include/system: Move exec/ioport.h to system/ioport.h

Convert the existing includes with sed.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/system: Move exec/address-spaces.h to system/address-spaces.h
Richard Henderson [Wed, 12 Mar 2025 19:31:54 +0000 (12:31 -0700)] 
include/system: Move exec/address-spaces.h to system/address-spaces.h

Convert the existing includes with sed.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/system: Move exec/memory.h to system/memory.h
Richard Henderson [Wed, 12 Mar 2025 19:11:21 +0000 (12:11 -0700)] 
include/system: Move exec/memory.h to system/memory.h

Convert the existing includes with

  sed -i ,exec/memory.h,system/memory.h,g

Move the include within cpu-all.h into a !CONFIG_USER_ONLY block.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/exec: Split out mmap-lock.h
Richard Henderson [Wed, 12 Mar 2025 17:36:39 +0000 (10:36 -0700)] 
include/exec: Split out mmap-lock.h

Split out mmap_lock, et al from page-protection.h
to a new header.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoaccel/tcg: Remove mmap_lock/unlock from watchpoint.c
Richard Henderson [Wed, 12 Mar 2025 17:37:23 +0000 (10:37 -0700)] 
accel/tcg: Remove mmap_lock/unlock from watchpoint.c

The mmap_lock is user-only, whereas watchpoint.c
is only compiled for system mode.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoaccel/tcg: Implement translator_ld*_end
Richard Henderson [Wed, 12 Mar 2025 13:04:13 +0000 (06:04 -0700)] 
accel/tcg: Implement translator_ld*_end

Add a new family of translator load functions which take
an absolute endianness value in the form of MO_BE/MO_LE.
Expand the other translator_ld* functions on top of this.
Remove exec/tswap.h from translator.c.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoaccel/tcg: Use cpu_ld*_code_mmu in translator.c
Richard Henderson [Wed, 12 Mar 2025 03:21:26 +0000 (20:21 -0700)] 
accel/tcg: Use cpu_ld*_code_mmu in translator.c

Cache the mmu index in DisasContextBase.
Perform the read on host endianness, which lets us
share code with the translator_ld fast path.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoaccel/tcg: Perform aligned atomic reads in translator_ld
Richard Henderson [Wed, 12 Mar 2025 01:34:58 +0000 (18:34 -0700)] 
accel/tcg: Perform aligned atomic reads in translator_ld

Perform aligned atomic reads in translator_ld, if possible.
According to

https://lore.kernel.org/qemu-devel/20240607101403.1109-1-jim.shu@sifive.com/

this is required for RISC-V Ziccif.

Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/exec: Inline *_code memory operations
Richard Henderson [Tue, 11 Mar 2025 21:34:28 +0000 (14:34 -0700)] 
include/exec: Inline *_code memory operations

These need to be per-target for 'abi_ptr' and endianness.
These expand inline to the *_mmu api with a lookup of the
target's cpu_mmu_index() and ra == 0.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/exec: Inline *_data memory operations
Richard Henderson [Tue, 11 Mar 2025 21:08:55 +0000 (14:08 -0700)] 
include/exec: Inline *_data memory operations

These need to be per-target for 'abi_ptr'.  Expand inline to
the *_data_ra api with ra == 0.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/exec: Inline *_data_ra memory operations
Richard Henderson [Tue, 11 Mar 2025 20:56:02 +0000 (13:56 -0700)] 
include/exec: Inline *_data_ra memory operations

These need to be per-target for 'abi_ptr'.  Expand inline to
the *_mmuidx_ra api with a lookup of the target's cpu_mmu_index().

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/exec: Inline *_mmuidx_ra memory operations
Richard Henderson [Tue, 11 Mar 2025 20:45:24 +0000 (13:45 -0700)] 
include/exec: Inline *_mmuidx_ra memory operations

These need to be per-target for 'abi_ptr'.  Expand inline to
the *_mmu api with trivial massaging of the arguments.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/exec: Split out accel/tcg/cpu-mmu-index.h
Richard Henderson [Thu, 13 Mar 2025 03:04:59 +0000 (20:04 -0700)] 
include/exec: Split out accel/tcg/cpu-mmu-index.h

The implementation of cpu_mmu_index was split between cpu-common.h
and cpu-all.h, depending on CONFIG_USER_ONLY.  We already have the
plumbing common to user and system mode.  Using MMU_USER_IDX
requires the cpu.h for a specific target, and so is restricted to
when we're compiling per-target.

Include the new header only where needed.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/exec: Split out cpu-ldst-common.h
Richard Henderson [Tue, 11 Mar 2025 20:03:37 +0000 (13:03 -0700)] 
include/exec: Split out cpu-ldst-common.h

Split out the *_mmu api, which no longer uses
target specific argument types.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoinclude/exec: Use vaddr for *_mmu guest memory access routines
Richard Henderson [Tue, 11 Mar 2025 19:52:36 +0000 (12:52 -0700)] 
include/exec: Use vaddr for *_mmu guest memory access routines

Use vaddr only for the newest api, because it has the least
number of uses and therefore is the easiest to audit.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoaccel/tcg: Fix cpu_ld*_code_mmu for user mode
Richard Henderson [Sat, 15 Mar 2025 01:20:00 +0000 (18:20 -0700)] 
accel/tcg: Fix cpu_ld*_code_mmu for user mode

These routines are buggy in multiple ways:
  - Use of target-endian loads, then a bswap that
    depends on the host endiannness.
  - A non-unwinding code load must set_helper_retaddr 1,
    which is magic within adjust_signal_pc.
  - cpu_ldq_code_mmu used MMU_DATA_LOAD

The bugs are hidden because all current uses of cpu_ld*_code_mmu
are from system mode.

Fixes: 2899062614a ("accel/tcg: Add cpu_ld*_code_mmu")
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoaccel/tcg: Build plugin-gen.c once
Richard Henderson [Mon, 10 Mar 2025 20:15:22 +0000 (13:15 -0700)] 
accel/tcg: Build plugin-gen.c once

We assert that env immediately follows CPUState in cpu-all.h.
Change the offsetof expressions to be based on CPUState instead
of ArchCPU.

Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agoaccel/tcg: Build user-exec-stub.c once
Richard Henderson [Mon, 10 Mar 2025 19:57:24 +0000 (12:57 -0700)] 
accel/tcg: Build user-exec-stub.c once

CONFIG_USER_ONLY == !CONFIG_SYSTEM_ONLY.
Therefore it's cleaner to just add to user_ss.

Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agosystem/ioport: make compilation unit common
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:17 +0000 (11:34 -0700)] 
system/ioport: make compilation unit common

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-19-pierrick.bouvier@linaro.org>

7 weeks agosystem/memory: make compilation unit common
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:16 +0000 (11:34 -0700)] 
system/memory: make compilation unit common

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-18-pierrick.bouvier@linaro.org>

7 weeks agoinclude/exec/memory: move devend functions to memory-internal.h
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:15 +0000 (11:34 -0700)] 
include/exec/memory: move devend functions to memory-internal.h

Only system/physmem.c and system/memory.c use those functions, so we can
move then to internal header.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-17-pierrick.bouvier@linaro.org>

7 weeks agoinclude/exec/memory: extract devend_big_endian from devend_memop
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:14 +0000 (11:34 -0700)] 
include/exec/memory: extract devend_big_endian from devend_memop

we'll use it in system/memory.c.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-16-pierrick.bouvier@linaro.org>

7 weeks agosystem/physmem: compilation unit is now common to all targets
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:13 +0000 (11:34 -0700)] 
system/physmem: compilation unit is now common to all targets

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-15-pierrick.bouvier@linaro.org>

7 weeks agosystem/xen: remove inline stubs
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:12 +0000 (11:34 -0700)] 
system/xen: remove inline stubs

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-14-pierrick.bouvier@linaro.org>

7 weeks agohw/xen: add stubs for various functions
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:11 +0000 (11:34 -0700)] 
hw/xen: add stubs for various functions

Those symbols are used by system/physmem.c, and are called only if
xen_enabled() (which happens only if CONFIG_XEN is set and xen is
available).

So we can crash the stubs in case those are called, as they are linked
only when CONFIG_XEN is not set.

Acked-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Anthony PERARD <anthony.perard@vates.tech>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-13-pierrick.bouvier@linaro.org>

7 weeks agoexec/ram_addr: call xen_hvm_modified_memory only if xen is enabled
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:10 +0000 (11:34 -0700)] 
exec/ram_addr: call xen_hvm_modified_memory only if xen is enabled

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-12-pierrick.bouvier@linaro.org>

7 weeks agosystem/kvm: make kvm_flush_coalesced_mmio_buffer() accessible for common code
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:09 +0000 (11:34 -0700)] 
system/kvm: make kvm_flush_coalesced_mmio_buffer() accessible for common code

This function is used by system/physmem.c will be turn into common code
in next commit.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-11-pierrick.bouvier@linaro.org>

7 weeks agoexec/ram_addr: remove dependency on cpu.h
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:08 +0000 (11:34 -0700)] 
exec/ram_addr: remove dependency on cpu.h

Needed so compilation units including it can be common.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-10-pierrick.bouvier@linaro.org>

7 weeks agoexec/memory-internal: remove dependency on cpu.h
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:07 +0000 (11:34 -0700)] 
exec/memory-internal: remove dependency on cpu.h

Needed so compilation units including it can be common.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-9-pierrick.bouvier@linaro.org>

7 weeks agoexec/exec-all: remove dependency on cpu.h
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:06 +0000 (11:34 -0700)] 
exec/exec-all: remove dependency on cpu.h

Previous commit changed files relying transitively on it.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-8-pierrick.bouvier@linaro.org>

7 weeks agocodebase: prepare to remove cpu.h from exec/exec-all.h
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:05 +0000 (11:34 -0700)] 
codebase: prepare to remove cpu.h from exec/exec-all.h

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-7-pierrick.bouvier@linaro.org>

7 weeks agoexec/memory.h: make devend_memop "target defines" agnostic
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:04 +0000 (11:34 -0700)] 
exec/memory.h: make devend_memop "target defines" agnostic

Will allow to make system/memory.c common later.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-6-pierrick.bouvier@linaro.org>

7 weeks agoexec/memory_ldst_phys: extract memory_ldst_phys declarations from cpu-all.h
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:03 +0000 (11:34 -0700)] 
exec/memory_ldst_phys: extract memory_ldst_phys declarations from cpu-all.h

They are now accessible through exec/memory.h instead, and we make sure
all variants are available for common or target dependent code.

Move stl_phys_notdirty function as well.
Cached endianness agnostic version rely on st/ld*_p, which is available
through tswap.h.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-5-pierrick.bouvier@linaro.org>

7 weeks agoexec/memory_ldst: extract memory_ldst declarations from cpu-all.h
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:02 +0000 (11:34 -0700)] 
exec/memory_ldst: extract memory_ldst declarations from cpu-all.h

They are now accessible through exec/memory.h instead, and we make sure
all variants are available for common or target dependent code.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-4-pierrick.bouvier@linaro.org>

7 weeks agoexec/tswap: implement {ld,st}.*_p as functions instead of macros
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:01 +0000 (11:34 -0700)] 
exec/tswap: implement {ld,st}.*_p as functions instead of macros

Defining functions allows to use them from common code, by not depending
on TARGET_BIG_ENDIAN.
Remove previous macros from exec/cpu-all.h.
By moving them out of cpu-all.h, we'll be able to break dependency on
cpu.h for memory related functions coming in next commits.

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-3-pierrick.bouvier@linaro.org>

7 weeks agoexec/tswap: target code can use TARGET_BIG_ENDIAN instead of target_words_bigendian()
Pierrick Bouvier [Mon, 17 Mar 2025 18:34:00 +0000 (11:34 -0700)] 
exec/tswap: target code can use TARGET_BIG_ENDIAN instead of target_words_bigendian()

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Message-ID: <20250317183417.285700-2-pierrick.bouvier@linaro.org>

7 weeks agoMerge tag 'pull-avr-20250422' of https://gitlab.com/rth7680/qemu into staging
Stefan Hajnoczi [Wed, 23 Apr 2025 13:29:33 +0000 (09:29 -0400)] 
Merge tag 'pull-avr-20250422' of https://gitlab.com/rth7680/qemu into staging

target/avr: Fix buffer read in avr_print_insn
target/avr: Improve decode of LDS, STS
target/avr: Move cpu register accesses into system memory
target/avr: Increase TARGET_PAGE_BITS to 10

# -----BEGIN PGP SIGNATURE-----
#
# iQFRBAABCgA7FiEEekgeeIaLTbaoWgXAZN846K9+IV8FAmgIBb4dHHJpY2hhcmQu
# aGVuZGVyc29uQGxpbmFyby5vcmcACgkQZN846K9+IV9wcgf/b0pwvg5GlDEtowUU
# L21jCyzh0zkYTBQ4SYiGKI1jYx3wuJAEyDx8jQ8iFZA+5Vv43aUQO0ghy301Xmc+
# wrBDhVbd+cSCNPobd8uthoDfBoMO6IIvQ10Rc9S/iCVs7idhrS/vCk25UqWkHHo6
# BYI8mZCTwIo/UnE4B9g5+ccvTqiXIzOYDWxRo31Fb4GJclPlELV0MS/IO377W3Rs
# t43BGDbzyJW1irUOzBsCxqZ8QogUwOve5h67tzJK53ETqqZVlRnuH3mvirtlL3R0
# 0AMFYwm0ygr+rkmQ/AfQ2D1QPiVz0oALV0P1KKNaUuv39WAeWEVEcIuDMvwy9XqG
# pgI+uw==
# =/fBY
# -----END PGP SIGNATURE-----
# gpg: Signature made Tue 22 Apr 2025 17:10:22 EDT
# gpg:                using RSA key 7A481E78868B4DB6A85A05C064DF38E8AF7E215F
# gpg:                issuer "richard.henderson@linaro.org"
# gpg: Good signature from "Richard Henderson <richard.henderson@linaro.org>" [full]
# Primary key fingerprint: 7A48 1E78 868B 4DB6 A85A  05C0 64DF 38E8 AF7E 215F

* tag 'pull-avr-20250422' of https://gitlab.com/rth7680/qemu:
  target/avr: Increase TARGET_PAGE_BITS to 10
  hw/avr: Prepare for TARGET_PAGE_SIZE > 256
  target/avr: Use do_stb in avr_cpu_do_interrupt
  target/avr: Use cpu_stb_mmuidx_ra in helper_fullwr
  target/avr: Remove NUMBER_OF_IO_REGISTERS
  target/avr: Move cpu register accesses into system memory
  target/avr: Add defines for i/o port registers
  target/avr: Remove OFFSET_CPU_REGISTERS
  target/avr: Improve decode of LDS, STS

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
7 weeks agoMerge tag 'pull-request-2025-04-23' of https://gitlab.com/thuth/qemu into staging
Stefan Hajnoczi [Wed, 23 Apr 2025 13:29:22 +0000 (09:29 -0400)] 
Merge tag 'pull-request-2025-04-23' of https://gitlab.com/thuth/qemu into staging

* Remove the obsolete s390-ccw-virtio-2.9 machine type
* Prepare the dump-skeys QMP command for the universal binary project
* Add compat machine types for 10.1
* Convert the remaining Avocado tests to the functional framework
* Some more small fixes for the functional tests

# -----BEGIN PGP SIGNATURE-----
#
# iQJFBAABCAAvFiEEJ7iIR+7gJQEY8+q5LtnXdP5wLbUFAmgIghARHHRodXRoQHJl
# ZGhhdC5jb20ACgkQLtnXdP5wLbXFeA//ayM/KF9so5DbatHQ+TD4wReNd5zlcYxz
# hjx5FAQPl+QmMNcBhkfBWJ6DqypzzrDOrRevwKe1xcJYyUthDJ6Bl//phmfTKzbo
# lAW5XmQhFGi+yolhRMdd6N+5Ky/c0jPzZjuJvi21RmSWi+ZqBiwUmaH1wutiI6A5
# peytvpt1R+DPJsZtFViEW9AwRtSkQh4I5+not33bvKdFWTGHE+iSYnVTXDiEbY5p
# TNIXaN9t9ZnojknswwHvyF+QbXn/pVLSA+XLDZuops2IEiPCsCTXUdjSwlfPReKM
# G0tl5DOXJFUMwmU1wRtqn0TdkP2AL1KfMr6ZVsE1zD1/XMj9uDF6BxxjB2si2UrC
# DTXCn+K535IyEa3qf25mhv9ueDr2ItiaDk4CBpb+Z/lg3p73jVW8G1mAU0mG9XlH
# KhJgOqTelnSuwlF6PdhtOxiH/rmgozMcrlppAMBbNgKBvzrT7Iwcq3OS9r+ZAWXO
# 7ouY/zYlbe1fnRgkgaapWx5AXhbkyxqgMkmZk0JE5XcsOHwMUd4O/Sk2kE6zVObe
# 7ReNqJdxj4c+lfqof5UwMUeqb465NTEAJXBGpiGDcP5qCzGBwnaIv5D71o1A+KoB
# 8g3E6woUN2i3ZPq8W4L8PbMR+zHNGUIVdnmH3EtNd6X3cBN9w4UYVN1MdzKSzQsi
# aCG/VdfcZsw=
# =yO4v
# -----END PGP SIGNATURE-----
# gpg: Signature made Wed 23 Apr 2025 02:00:48 EDT
# 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

* tag 'pull-request-2025-04-23' of https://gitlab.com/thuth/qemu: (29 commits)
  MAINTAINERS: Add functional tests that are not covered yet
  tests/functional: Remove unnecessary import statements
  tests/functional: Remove semicolons at the end of lines
  Remove the remainders of the Avocado tests
  docs/devel/testing: Dissolve the ci-definitions.rst.inc file
  gitlab-ci: Update QEMU_JOB_AVOCADO and QEMU_CI_AVOCADO_TESTING
  tests/functional: Convert the SMMU test to the functional framework
  tests/functional: Use the tuxrun kernel for the aarch64 replay test
  tests/functional: Use the tuxrun kernel for the x86 replay test
  tests/avocado: Remove the boot_linux.py tests
  tests/functional: Convert the 64-bit big endian Wheezy mips test
  tests/functional: Convert the 64-bit little endian Wheezy mips test
  tests/functional: Convert the 32-bit little endian Wheezy mips test
  tests/functional: Convert the 32-bit big endian Wheezy mips test
  tests/avocado: Remove the LinuxKernelTest class
  tests/functional: Convert the i386 replay avocado test
  tests/functional: Convert reverse_debugging tests to the functional framework
  tests/functional: Move the check for the parameters from avocado to functional
  gitlab-ci: Remove the avocado tests from the CI pipelines
  tests/functional/test_vnc: skip test if no crypto backend available
  ...

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
7 weeks agoMerge tag 'for-upstream' of https://gitlab.com/bonzini/qemu into staging
Stefan Hajnoczi [Wed, 23 Apr 2025 13:29:12 +0000 (09:29 -0400)] 
Merge tag 'for-upstream' of https://gitlab.com/bonzini/qemu into staging

* target/i386: Fix model number of Zhaoxin YongFeng vCPU template
* target/i386: Reset parked vCPUs together with the online ones
* scsi: add conversion from ENODEV to sense
* target/i386: tweaks to flag handling
* target/i386: tweaks to SHLD/SHRD code generation
* target/i386: remove some global temporaries from TCG
* target/i386: pull emulator outside target/i386/hvf
* host/i386: consolidate getting host CPU vendor
* rust/hpet: preparation for migration support
* rust/pl011: bring over more commits from C version

# -----BEGIN PGP SIGNATURE-----
#
# iQFIBAABCgAyFiEE8TM4V0tmI4mGbHaCv/vSX3jHroMFAmgItXAUHHBib256aW5p
# QHJlZGhhdC5jb20ACgkQv/vSX3jHroNrwgf/TAiz0LdO9q3O9Ob2FJVdAL6jn0YH
# /yDjAOpRT9WBOoKi+fikMuX6FlxVNpb6K5xx/WMbXDiO3PLMMNYet3fnXpjGBCj0
# aLcrHxG0TUfUk2mYssBoyZ1IG5bjevRZjjRFAXGubJZp/l6oXCCPrZ4mkW9MRP9U
# GzzwhSC2U0CuZREz4YxurPZmgx9lKRcf71lVExh6AHWpPPU3tWk0F51zE+PxObWk
# WvNwVvBPPYryC88DcN9YytiNn0jLtIozf3sxTDAi6jsg5T6PzeGU+LTck3DtQJIY
# 3eAoTpLW1ZEYMIcbA/upLHz+obqDCgWZUPQydHvJS/xlIcnO+RYkWobOxg==
# =06CN
# -----END PGP SIGNATURE-----
# gpg: Signature made Wed 23 Apr 2025 05:40:00 EDT
# 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

* tag 'for-upstream' of https://gitlab.com/bonzini/qemu: (34 commits)
  rust/hw/char/pl011: Extract DR write logic into separate function
  rust/hw/char/pl011: Extract extract DR read logic into separate function
  rust/vmstate_test: Fix typo in test_vmstate_macro_array_of_pointer_wrapped()
  rust/hpet: Fix a clippy error
  rust/hpet: convert HPETTimer index to u8 type
  rust/hpet: convert num_timers to u8 type
  i386/cpu: Consolidate the helper to get Host's vendor
  target/i386/emulate: remove flags_mask
  MAINTAINERS: add an entry for the x86 instruction emulator
  target/i386: move x86 instruction emulator out of hvf
  target/i386/emulate: add a panic.h
  target/i386: add a directory for x86 instruction emulator
  target/i386/hvf: rename some include guards
  target/i386/hvf: drop unused headers
  target/i386: rename lazy flags field and its type
  target/i386/hvf: provide and use simulate_{wrmsr, rdmsr} in emul_ops
  target/i386/hvf: provide and use write_mem in emul_ops
  target/i386/hvf: use emul_ops->read_mem in x86_emu.c
  target/i386: rename hvf_mmio_buf to emu_mmio_buf
  target/i386/hvf: provide and use handle_io in emul_ops
  ...

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
7 weeks agoMerge tag 'ipmi-for-qemu-10.0' of https://github.com/cminyard/qemu into staging
Stefan Hajnoczi [Wed, 23 Apr 2025 13:29:02 +0000 (09:29 -0400)] 
Merge tag 'ipmi-for-qemu-10.0' of https://github.com/cminyard/qemu into staging

Some minor fixes for various things

# -----BEGIN PGP SIGNATURE-----
#
# iQIzBAABCgAdFiEE/Q1c5nzg9ZpmiCaGYfOMkJGb/4EFAmgAQuQACgkQYfOMkJGb
# /4G9EQ//do2GgBjj2NChR7G8CV7DyAA7rnhYx1txD8I4F1cyvMAW0flc8qE5MaC8
# pJpfvQwYJs60WQbg5RELEEPFubtMPz/OPgfZfpGsXBRwqbpl2c3JGrEpVnDpsqdW
# VXd24gFEuHyFKLoa4VMeJ40TvCsHsndkFTb7v12mneiH52YJyYDdb6ywkbeJS34F
# 1sX745LtgQbC/piFzcuwX/NvSPlk3O9FT84k4AdfUPpBJNicQ6aKeQB/kuXmecEU
# 6i6j8E/oCzZM9yLXWFFg3Fit5F24CBK9uDpFLE1ctoOW0lsVaQ+e8ogprvY7KMlO
# zZVu2CPOZPf6IwUC/nmvWukey1BHpJSpEwZPZJao3Bt+qxK3hEl2FNPQIBVLNsJ9
# /6f6VtdgYSkkMed3G11eVS+p5QwX+4GEg+rhV8HDMYPecpaSePR3DIomAUKTc9je
# t89ooW3iy6egONcbZSlFILPRmfRHv2h6aLOSMAAFXgx4aKt1I9b0EpjqBvDgTIxZ
# 3ehn2jnwG8jTYaJdkiXFvvYNn2A8qEJc1Hifud1skJchqFXn7e6mjneLuOWO4uYZ
# /VnOljqu+KwyDWxCnMfkLuOd+PNnHvB9fctqRvYJpsyc+WyjmRhH+YlbG2yt/FZj
# fmCjZWKrZR2e6GaUPQSTEpahbuySf4QV4B9sP+YOcSQFy3N8ocU=
# =V8+d
# -----END PGP SIGNATURE-----
# gpg: Signature made Wed 16 Apr 2025 19:53:08 EDT
# gpg:                using RSA key FD0D5CE67CE0F59A6688268661F38C90919BFF81
# gpg: Good signature from "Corey Minyard <cminyard@mvista.com>" [unknown]
# gpg:                 aka "Corey Minyard <corey@minyard.net>" [unknown]
# gpg:                 aka "Corey Minyard <minyard@mvista.com>" [unknown]
# gpg:                 aka "Corey Minyard <minyard@acm.org>" [unknown]
# 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: FD0D 5CE6 7CE0 F59A 6688  2686 61F3 8C90 919B FF81

* tag 'ipmi-for-qemu-10.0' of https://github.com/cminyard/qemu:
  ipmi/bmc-sim: add error handling for 'Set BMC Global Enables' command
  ipmi/bmc-sim: implement watchdog dont log flag
  ipmi/bmc-sim: Add 'Get Channel Info' command
  ipmi: add fwinfo to pci ipmi devices
  ipmi/pci-ipmi-bt: Rename copy-paste variables
  hw/ipmi: Move vmsd registration to device class

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
7 weeks agorust/hw/char/pl011: Extract DR write logic into separate function
Rakesh Jeyasingh [Mon, 7 Apr 2025 18:13:27 +0000 (23:43 +0530)] 
rust/hw/char/pl011: Extract DR write logic into separate function

- Split `write()` DR case into `write_data_register()`

Signed-off-by: Rakesh Jeyasingh <rakeshjb010@gmail.com>
Link: https://lore.kernel.org/r/20250407181327.171563-3-rakeshjb010@gmail.com
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
7 weeks agorust/hw/char/pl011: Extract extract DR read logic into separate function
Rakesh Jeyasingh [Mon, 7 Apr 2025 18:13:26 +0000 (23:43 +0530)] 
rust/hw/char/pl011: Extract extract DR read logic into separate function

- Split `read()` DR case into `read_data_register()`

Signed-off-by: Rakesh Jeyasingh <rakeshjb010@gmail.com>
Link: https://lore.kernel.org/r/20250407181327.171563-2-rakeshjb010@gmail.com
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
7 weeks agorust/vmstate_test: Fix typo in test_vmstate_macro_array_of_pointer_wrapped()
Zhao Liu [Mon, 14 Apr 2025 14:49:38 +0000 (22:49 +0800)] 
rust/vmstate_test: Fix typo in test_vmstate_macro_array_of_pointer_wrapped()

test_vmstate_macro_array_of_pointer_wrapped() tests the 3rd element, so
fix the index.

Signed-off-by: Zhao Liu <zhao1.liu@intel.com>
Link: https://lore.kernel.org/r/20250414144943.1112885-5-zhao1.liu@intel.com
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
7 weeks agorust/hpet: Fix a clippy error
Zhao Liu [Mon, 14 Apr 2025 14:49:43 +0000 (22:49 +0800)] 
rust/hpet: Fix a clippy error

Carge clippy complained about:

error: casts from `u8` to `u32` can be expressed infallibly using `From`

So use `From` to convert `u8` to `u32`.

Signed-off-by: Zhao Liu <zhao1.liu@intel.com>
Link: https://lore.kernel.org/r/20250414144943.1112885-10-zhao1.liu@intel.com
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
7 weeks agorust/hpet: convert HPETTimer index to u8 type
Zhao Liu [Mon, 14 Apr 2025 14:49:41 +0000 (22:49 +0800)] 
rust/hpet: convert HPETTimer index to u8 type

The C version of HPET uses the uint8_t type for timer index ("tn"), and
usize type in Rust version will break migration between the C and Rust
versions.

So convert HPETTimer index' type to u8 (consistent with the C version of
HPET) to make it friendly for vmstate support.

Signed-off-by: Zhao Liu <zhao1.liu@intel.com>
Link: https://lore.kernel.org/r/20250414144943.1112885-8-zhao1.liu@intel.com
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
7 weeks agorust/hpet: convert num_timers to u8 type
Zhao Liu [Mon, 14 Apr 2025 14:49:40 +0000 (22:49 +0800)] 
rust/hpet: convert num_timers to u8 type

The C version of HPET uses the uint8_t type for num_timers, and usize
type in Rust version will break migration between the C and Rust
versions.

So convert num_timers' type to u8 (consistent with the C version of
HPET) to make it friendly for vmstate support.

Note the commit 7bda68e8e2b0 ("qdev, rust/hpet: fix type of HPET
'timers property") supports the usize type property, but the uint8
property has to be re-supported now.

Signed-off-by: Zhao Liu <zhao1.liu@intel.com>
Link: https://lore.kernel.org/r/20250414144943.1112885-7-zhao1.liu@intel.com
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
7 weeks agoMAINTAINERS: Add functional tests that are not covered yet
Thomas Huth [Mon, 14 Apr 2025 12:15:20 +0000 (14:15 +0200)] 
MAINTAINERS: Add functional tests that are not covered yet

Some functional tests are currently not covered by the entries
in MAINTAINERS yet, so scripts/get_maintainers.pl fails to suggest
the right people who should be CC:-ed for related patches.
Add the uncovered tests to the right sections to close this gap.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20250414121520.213665-1-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/functional: Remove unnecessary import statements
Thomas Huth [Mon, 14 Apr 2025 14:54:57 +0000 (16:54 +0200)] 
tests/functional: Remove unnecessary import statements

pylint complains about these unnecessary import statements,
so let's remove them.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20250414145457.261734-1-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/functional: Remove semicolons at the end of lines
Thomas Huth [Thu, 27 Mar 2025 20:13:05 +0000 (21:13 +0100)] 
tests/functional: Remove semicolons at the end of lines

Yes, we are all C coders who try to write Python code for testing...
but still, let's better avoid semicolons at the end of the lines
to keep "pylint" happy!

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Nina Schoetterl-Glausch <nsg@linux.ibm.com>
Reviewed-by: Cédric Le Goater <clg@redhat.com>
Message-ID: <20250327201305.996241-1-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agoRemove the remainders of the Avocado tests
Thomas Huth [Mon, 14 Apr 2025 11:30:29 +0000 (13:30 +0200)] 
Remove the remainders of the Avocado tests

Now that all Avocado tests have been converted to or been replaced by
other functional tests, we can delete the remainders of the Avocado
tests from the QEMU source tree.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-16-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agodocs/devel/testing: Dissolve the ci-definitions.rst.inc file
Thomas Huth [Fri, 14 Mar 2025 08:59:57 +0000 (09:59 +0100)] 
docs/devel/testing: Dissolve the ci-definitions.rst.inc file

This file was meant for defining the vocabulary for our testing
efforts, but it did not age well: First, the definitions are not
only about the CI part, but also about testing in general, so most
of the information should rather reside in main.rst instead.
Second, some vocabulary has never been really adopted by the QEMU
project, for example we never really use the word "system testing"
since "system" rather means the system emulator binaries in the
QEMU project (and we also don't do any testing with other components
like libvirt and virt-managers here). It also defines that the qtests
are the "functional" tests in QEMU, which is not really up to date
anymore after the "tests/functional" framework has been introduced
a couple of months ago (FWIW, the qtests could rather be seen as a
mix between unit testing and functional testing).

To solve this problem, move the useful parts of this file into
main.rst and directly into ci.rst, and drop the ones (like "system
testing") that we don't really need anymore.

Message-ID: <20250314085959.1585568-1-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agogitlab-ci: Update QEMU_JOB_AVOCADO and QEMU_CI_AVOCADO_TESTING
Thomas Huth [Mon, 14 Apr 2025 11:30:28 +0000 (13:30 +0200)] 
gitlab-ci: Update QEMU_JOB_AVOCADO and QEMU_CI_AVOCADO_TESTING

Since we don't run the Avocado jobs in the CI anymore, rename
these variables to QEMU_JOB_FUNCTIONAL and QEMU_CI_FUNCTIONAL.

Also, there was a mismatch between the documentation and the
implementation of QEMU_CI_AVOCADO_TESTING: While the documentation
said that you had to "Set this variable to have the tests using the
Avocado framework run automatically", you indeed needed to set it
to make the pipelines appear in your dashboard - but they were never
run automatically in forks and had to be triggered manually. Let's
improve this now: No need to hide these pipelines from the users
by default anymore (the functional tests should be stable enough
nowadays), and rather allow the users to run the pipelines auto-
matically with this switch now instead, as was documented.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-15-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/functional: Convert the SMMU test to the functional framework
Thomas Huth [Mon, 14 Apr 2025 11:30:27 +0000 (13:30 +0200)] 
tests/functional: Convert the SMMU test to the functional framework

This test was using cloudinit and a "dnf install" command in the guest
to exercise the NIC with SMMU enabled. Since we don't have the cloudinit
stuff in the functional framework and we should not rely on having access
to external networks (once our ASSETs have been cached), we rather boot
into the initrd first, manually mount the root disk and then use the
check_http_download() function from the functional framework here instead
for testing whether the network works as expected.

Unfortunately, there seems to be a small race when using the files
from Fedora 33: To enter the initrd shell, we have to send a "return"
once. But it does not seem to work if we send it too early. Using a
sleep(0.2) makes it work reliably for me, but to make it even more
unlikely to trigger this situation, let's better limit the Fedora 33
tests to only run with KVM.

Finally, while we're at it, we also add some lines for testing writes
to the hard disk, as we already do it in the test_intel_iommu test.

Reviewed-by: Eric Auger <eric.auger@redhat.com>
Tested-by: Eric Auger <eric.auger@redhat.com>
Message-ID: <20250414113031.151105-14-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/functional: Use the tuxrun kernel for the aarch64 replay test
Thomas Huth [Mon, 14 Apr 2025 11:30:26 +0000 (13:30 +0200)] 
tests/functional: Use the tuxrun kernel for the aarch64 replay test

This way we can do a full boot in record-replay mode and
should get a similar test coverage compared to the old
replay test from tests/avocado/replay_linux.py.

Since the aarch64 test was the last avocado test in the
tests/avocado/replay_linux.py file, we can remove this
file now completely.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
Message-ID: <20250414113031.151105-13-thuth@redhat.com>

7 weeks agotests/functional: Use the tuxrun kernel for the x86 replay test
Thomas Huth [Mon, 14 Apr 2025 11:30:25 +0000 (13:30 +0200)] 
tests/functional: Use the tuxrun kernel for the x86 replay test

This way we can do a full boot in record-replay mode and
should get a similar test coverage compared to the old
replay test from tests/avocado/replay_linux.py. Thus remove
the x86 avocado replay_linux test now.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-12-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/avocado: Remove the boot_linux.py tests
Thomas Huth [Mon, 14 Apr 2025 11:30:24 +0000 (13:30 +0200)] 
tests/avocado: Remove the boot_linux.py tests

These tests are based on the cloudinit functions from Avocado.
The cloudinit is very, very slow compared to our other tests,
so most of these Avocado tests have either been disabled by default
with a decorator, or have been marked to only run with KVM.

We won't include this sluggish cloudinit stuff in the functional
framework, and we've already got plenty of other tests there that
check pretty much the same things, so let's simply get rid of these
old tests now.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-11-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/functional: Convert the 64-bit big endian Wheezy mips test
Thomas Huth [Mon, 14 Apr 2025 11:30:23 +0000 (13:30 +0200)] 
tests/functional: Convert the 64-bit big endian Wheezy mips test

Reuse the test function from the 32-bit big endian test to easily
convert the 64-bit big endian Wheezy mips test.

Since this was the last test in tests/avocado/linux_ssh_mips_malta.py,
we can remove this avocado file now, too.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-10-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/functional: Convert the 64-bit little endian Wheezy mips test
Thomas Huth [Mon, 14 Apr 2025 11:30:22 +0000 (13:30 +0200)] 
tests/functional: Convert the 64-bit little endian Wheezy mips test

Reuse the test function from the 32-bit big endian test to easily
convert the 64-bit little endian Wheezy mips test.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-9-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/functional: Convert the 32-bit little endian Wheezy mips test
Thomas Huth [Mon, 14 Apr 2025 11:30:21 +0000 (13:30 +0200)] 
tests/functional: Convert the 32-bit little endian Wheezy mips test

Reuse the test function from the big endian test to easily
convert the 32-bit little endian Wheezy mips test.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-8-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/functional: Convert the 32-bit big endian Wheezy mips test
Thomas Huth [Mon, 14 Apr 2025 11:30:20 +0000 (13:30 +0200)] 
tests/functional: Convert the 32-bit big endian Wheezy mips test

The test checks some entries in /proc and the output of some commands ...
we put these checks into exportable functions now so that they can
be reused more easily.

Additionally the linux_ssh_mips_malta.py uses SSH to test the networking
of the guest. Since we don't have a SSH module in the functional
framework yet, let's use the check_http_download() function here instead.

And while we're at it, also switch the NIC to e1000 now to get some more
test coverage, since the "pcnet" device is already tested in the test
test_mips_malta_cpio.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-7-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/avocado: Remove the LinuxKernelTest class
Thomas Huth [Mon, 14 Apr 2025 11:30:19 +0000 (13:30 +0200)] 
tests/avocado: Remove the LinuxKernelTest class

All tests that used this class have been converted to the functional
framework, so we can remove the boot_linux_console.py file now.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-6-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/functional: Convert the i386 replay avocado test
Thomas Huth [Mon, 14 Apr 2025 11:30:18 +0000 (13:30 +0200)] 
tests/functional: Convert the i386 replay avocado test

Since this was the last test in tests/avocado/replay_kernel.py,
we can remove that Avocado file now.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-5-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/functional: Convert reverse_debugging tests to the functional framework
Thomas Huth [Mon, 14 Apr 2025 11:30:17 +0000 (13:30 +0200)] 
tests/functional: Convert reverse_debugging tests to the functional framework

These tests are using the gdb-related library functions from the
Avocado framework which we don't have in the functional framework
yet. So for the time being, keep those imports and skip the test
if the Avocado framework is not installed on the host.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-4-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/functional: Move the check for the parameters from avocado to functional
Thomas Huth [Mon, 14 Apr 2025 11:30:16 +0000 (13:30 +0200)] 
tests/functional: Move the check for the parameters from avocado to functional

test_x86_64_pc in tests/avocado/boot_linux_console.py only checks
whether the kernel parameters have correctly been passed to the
kernel in the guest by looking for them in the console output of the
guest. Let's move that to the functional test framework now, but
instead of doing it in a separate test, let's do it for all tuxrun
tests instead, so it is done automatically for all targets that have
a tuxrun test.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-3-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agogitlab-ci: Remove the avocado tests from the CI pipelines
Thomas Huth [Mon, 14 Apr 2025 11:30:15 +0000 (13:30 +0200)] 
gitlab-ci: Remove the avocado tests from the CI pipelines

We are going to move the remaining Avocado tests step by step
into the functional test framework. Unfortunately, Avocado fails
with an error if it cannot determine a test to run, so disable
the tests here now to avoid failures in the Gitlab-CI during the
next steps.

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-ID: <20250414113031.151105-2-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotests/functional/test_vnc: skip test if no crypto backend available
Cornelia Huck [Mon, 14 Apr 2025 09:37:32 +0000 (11:37 +0200)] 
tests/functional/test_vnc: skip test if no crypto backend available

The test_change_password test will fail if no cryptographic backend is
available (e.g. if QEMU was built on a system with no cryptographic
library development packages installed); just skip the test in that
case.

Signed-off-by: Cornelia Huck <cohuck@redhat.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-ID: <20250414093732.220498-1-cohuck@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agohw: add compat machines for 10.1
Cornelia Huck [Mon, 14 Apr 2025 09:45:43 +0000 (11:45 +0200)] 
hw: add compat machines for 10.1

Add 10.1 machine types for arm/i440fx/m68k/q35/s390x/spapr.

Signed-off-by: Cornelia Huck <cohuck@redhat.com>
Reviewed-by: Zhao Liu <zhao1.liu@intel.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Message-ID: <20250414094543.221241-1-cohuck@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agoqapi/machine: Make @dump-skeys command generic
Philippe Mathieu-Daudé [Mon, 10 Mar 2025 15:14:14 +0000 (16:14 +0100)] 
qapi/machine: Make @dump-skeys command generic

Reduce misc-target.json by one target specific command.

Error message is returned for machines not implementing
TYPE_DUMP_SKEYS_INTERFACE:

  $ qemu-system-aarch64 -M virt -S -qmp stdio
  {"QMP": {"version": {"qemu": {"micro": 50, "major": 9}}, "capabilities": ["oob"]}}
  { "execute": "qmp_capabilities" }
  {"return": {}}
  { "execute": "dump-skeys", "arguments": { "filename": "/tmp/foo" }  }
  {"error": {"class": "GenericError", "desc": "Storage keys information not available for this architecture"}}

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-ID: <20250310151414.11550-5-philmd@linaro.org>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agohw/s390x/ccw: Have CCW machine implement a qmp_dump_skeys() callback
Philippe Mathieu-Daudé [Mon, 10 Mar 2025 15:14:13 +0000 (16:14 +0100)] 
hw/s390x/ccw: Have CCW machine implement a qmp_dump_skeys() callback

In preparation to make @dump-skeys command generic,
extract s390_qmp_dump_skeys() out of qmp_dump_skeys().
Register it as CCW qmp_dump_skeys() callback.

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Reviewed-by: Eric Farman <farman@linux.ibm.com>
Message-ID: <20250310151414.11550-4-philmd@linaro.org>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agohw/s390x/skeys: Introduce TYPE_DUMP_SKEYS_INTERFACE
Philippe Mathieu-Daudé [Mon, 10 Mar 2025 15:14:12 +0000 (16:14 +0100)] 
hw/s390x/skeys: Introduce TYPE_DUMP_SKEYS_INTERFACE

The storage keys are part of the machine memory.

Introduce the TYPE_DUMP_SKEYS_INTERFACE type,
allowing machine using storage keys to dump them
when a DumpSKeysInterface::qmp_dump_skeys() callback
is provided.

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Eric Farman <farman@linux.ibm.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-ID: <20250310151414.11550-3-philmd@linaro.org>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agohw/s390x/skeys: Declare QOM types using DEFINE_TYPES() macro
Philippe Mathieu-Daudé [Mon, 10 Mar 2025 15:14:11 +0000 (16:14 +0100)] 
hw/s390x/skeys: Declare QOM types using DEFINE_TYPES() macro

When multiple QOM types are registered in the same file,
it is simpler to use the the DEFINE_TYPES() macro. In
particular because type array declared with such macro
are easier to review.

Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Eric Farman <farman@linux.ibm.com>
Reviewed-by: Thomas Huth <thuth@redhat.com>
Message-ID: <20250310151414.11550-2-philmd@linaro.org>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agohw/intc/s390_flic: Remove the obsolete migration_enabled flag
Thomas Huth [Wed, 15 Jan 2025 07:38:15 +0000 (08:38 +0100)] 
hw/intc/s390_flic: Remove the obsolete migration_enabled flag

Now that the machine types that set the migration_enabled flag to
false are gone, we can remove it and the related code.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20250115073819.15452-5-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agohw/s390x/s390-stattrib: Remove the old migration_enabled flag
Thomas Huth [Wed, 15 Jan 2025 07:38:14 +0000 (08:38 +0100)] 
hw/s390x/s390-stattrib: Remove the old migration_enabled flag

Now that the machine types that set the migration_enabled flag to
false are gone, we can remove it and the related code.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20250115073819.15452-4-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agohw/s390x/css: Remove the obsolete "css_migration_enabled" variable
Thomas Huth [Wed, 15 Jan 2025 07:38:13 +0000 (08:38 +0100)] 
hw/s390x/css: Remove the obsolete "css_migration_enabled" variable

Now that the s390-ccw-virtio-2.9 machine type has been removed, we
don't need the "css_migration_enabled" variable anymore and can remove
the related code.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-ID: <20250115073819.15452-3-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agohw/s390x/s390-virtio-ccw: Remove the deprecated 2.9 machine type
Thomas Huth [Wed, 15 Jan 2025 07:38:12 +0000 (08:38 +0100)] 
hw/s390x/s390-virtio-ccw: Remove the deprecated 2.9 machine type

The s390-ccw-virtio-2.9 machine is older than 6 years, so according to
our machine support policy, it can be removed now.

Message-ID: <20250115073819.15452-2-thuth@redhat.com>
Signed-off-by: Thomas Huth <thuth@redhat.com>
7 weeks agotarget/avr: Increase TARGET_PAGE_BITS to 10
Richard Henderson [Tue, 25 Mar 2025 22:32:50 +0000 (15:32 -0700)] 
target/avr: Increase TARGET_PAGE_BITS to 10

Now that we can handle the MCU allocating only a portion of the
first page to i/o, increase the page size.  Choose 10 as larger
than the i/o on every MCU, just so that this path is tested.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
7 weeks agohw/avr: Prepare for TARGET_PAGE_SIZE > 256
Richard Henderson [Tue, 25 Mar 2025 22:26:28 +0000 (15:26 -0700)] 
hw/avr: Prepare for TARGET_PAGE_SIZE > 256

If i/o does not cover the entire first page, allocate a portion
of ram as an i/o device, so that the entire first page is i/o.

While memory_region_init_ram_device_ptr is happy to allocate
the RAMBlock, it does not register the ram for migration.
Do this by hand.

Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>