On Fri, Jul 14, 2023 at 5:29 AM Conor Dooley wrote:
>
> On Fri, Jul 14, 2023 at 11:19:34AM +0100, Conor Dooley wrote:
> > On Fri, Jul 14, 2023 at 10:00:19AM +0530, Anup Patel wrote:
> >
> > > > > OpenSBI v1.3
> > > > >_ _
> > > > > / __ \
The curses display handles most control-X keys, and translates
them into their corresponding keycode. Here we recognize
a few that are missing, Ctrl-@ (null), Ctrl-\ (backslash),
Ctrl-] (right bracket), Ctrl-^ (caret), Ctrl-_ (underscore).
Signed-off-by: Sean Estabrooks
---
ui/curses_keys.h | 6
Be careful not to change linux_dirent64, which is a host structure.
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 30 +++---
1 file changed, 15 insertions(+), 15 deletions(-)
diff --git a/linux-user/syscall_defs.h b
Based on gcc's nios2.h setting BIGGEST_ALIGNMENT to 32 bits.
Signed-off-by: Richard Henderson
---
include/exec/user/abitypes.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/include/exec/user/abitypes.h b/include/exec/user/abitypes.h
index beba0a48c7..6191ce9f74 100644
---
Be careful not to change linux_dirent64, which is a host structure.
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 72 +++
1 file changed, 36 insertions(+), 36 deletions(-)
diff --git a/linux-user/syscall
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 90 +++
1 file changed, 45 insertions(+), 45 deletions(-)
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index 442a8aefe3..21ca03b0f4 1006
The following changes since commit 4633c1e2c576fbabfe5c8c93f4b842504b69c096:
Merge tag 'for-upstream' of https://gitlab.com/bonzini/qemu into staging
(2023-07-14 16:39:46 +0100)
are available in the Git repository at:
https://gitlab.com/rth7680/qemu.git tags/pull-tcg-20230715
All of the guest to host page adjustment is handled by
mmap_reserve_or_unmap; there is no need to duplicate that.
There are no failure modes for munmap after alignment and
guest address range have been validated.
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-23-richard.hender.
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 60 +++
1 file changed, 30 insertions(+), 30 deletions(-)
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index 414d88a9ec..caaa895bec 1006
Share the setjmp cleanup between cpu_exec_step_atomic
and cpu_exec_setjmp.
Reviewed-by: Alex Bennée
Reviewed-by: Philippe Mathieu-Daudé
Reviewed-by: Richard W.M. Jones
Signed-off-by: Richard Henderson
---
accel/tcg/cpu-exec.c | 43 +++
1 file changed, 1
These definitions are in sparc/signal.c.
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 24
1 file changed, 24 deletions(-)
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index e80d54780b..a4e4df
We build with _FILE_OFFSET_BITS=64, so off_t = off64_t = uint64_t.
With an extra cast, this fixes emulation of mmap2, which could
overflow the computation of the full value of offset.
Reviewed-by: Alex Bennée
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-14-richard.hender...@
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 216 +++---
1 file changed, 108 insertions(+), 108 deletions(-)
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index e4fcbd16d2..442a8aefe3 10
From: Pierrick Bouvier
Support for execveat syscall was implemented in 55bbe4 and is available
since QEMU 8.0.0. It relies on host execveat, which is widely available
on most of Linux kernels today.
However, this change breaks qemu-user self emulation, if "host" qemu
version is less than 8.0.0.
Move the values into the per-target target_mman.h headers
Reviewed-by: Alex Bennée
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-7-richard.hender...@linaro.org>
---
linux-user/alpha/target_mman.h | 13 +
linux-user/generic/target_mman.h | 54
linux
Untabify and re-indent.
We had a mix of 2, 3, 4, and 8 space indentation.
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 1948 ++---
1 file changed, 974 insertions(+), 974 deletions(-)
diff --git a/linux-user
Use the interval tree to find empty space, rather than
probing each page in turn.
Cc: Warner Losh
Cc: Kyle Evans
Signed-off-by: Richard Henderson
Reviewed-bt: Warner Losh
Message-Id: <20230707204054.8792-18-richard.hender...@linaro.org>
---
bsd-user/mmap.c | 48 +++
Use the interval tree to find empty space, rather than
probing each page in turn.
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-19-richard.hender...@linaro.org>
---
linux-user/mmap.c | 52 ++-
1 file changed, 6 insertions(+), 46 del
Use the interval tree to locate an unused range in the VM.
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-17-richard.hender...@linaro.org>
---
include/exec/cpu-all.h | 15 +++
accel/tcg/user-exec.c | 41 +
2 files changed, 5
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 32
1 file changed, 16 insertions(+), 16 deletions(-)
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index 20986bd1d3..45ebacd4b4 100644
---
Off by one error, failing to take into account that layout_arg_1
already incremented info_in_idx for the first piece. We only
need care for the n-1 TCG_CALL_ARG_BY_REF_N pieces here.
Cc: qemu-sta...@nongnu.org
Fixes: 313bdea84d2 ("tcg: Add TCG_CALL_{RET,ARG}_BY_REF")
Resolves: https://gitlab.com/
Use 'last' variables instead of 'end' variables.
Always zero MAP_ANONYMOUS fragments, which we previously
failed to do if they were not writable; early exit in case
we allocate a new page from the kernel, known zeros.
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-16-richard.he
Based on gcc's microblaze.h setting BIGGEST_ALIGNMENT to 32 bits.
Signed-off-by: Richard Henderson
---
include/exec/user/abitypes.h | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/include/exec/user/abitypes.h b/include/exec/user/abitypes.h
index 743b8bb9ea..beba0a48c7 1006
The guest address, raddr, should be unsigned, aka abi_ulong.
The host addresses should be cast via *intptr_t not long.
Drop the inline and fix two other whitespace issues.
Signed-off-by: Richard Henderson
Reviewed-by: Philippe Mathieu-Daudé
Reviewed-by: Anton Johansson
Message-Id: <202306261402
Fix translation of TARGET_MAP_SHARED and TARGET_MAP_PRIVATE,
which are types not single bits. Add TARGET_MAP_SHARED_VALIDATE,
TARGET_MAP_SYNC, TARGET_MAP_NONBLOCK, TARGET_MAP_POPULATE,
TARGET_MAP_FIXED_NOREPLACE, and TARGET_MAP_UNINITIALIZED.
Update strace to match.
Reviewed-by: Alex Bennée
Sig
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-12-richard.hender...@linaro.org>
---
linux-user/mmap.c | 14 +++---
1 file changed, 11 insertions(+), 3 deletions(-)
diff --git a/linux-user/mmap.c b/linux-user/mmap.c
index 639921dba0..9dc34fc29d 100644
--- a/linux-user/m
From: Andreas Schwab
Fixes: 86f04735ac ("linux-user: Fix brk() to release pages")
Signed-off-by: Andreas Schwab
Message-Id:
Reviewed-by: Richard Henderson
Signed-off-by: Richard Henderson
---
linux-user/syscall.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/linux-user/
The previous check returned -1 when any page within
[start, start+len) is unmapped, not when all are unmapped.
Cc: Warner Losh
Cc: Kyle Evans
Signed-off-by: Richard Henderson
Reviewed-by: Warner Losh
Message-Id: <20230707204054.8792-11-richard.hender...@linaro.org>
---
bsd-user/mmap.c | 2 +-
Examine the interval tree to validate that a region
has no existing mappings.
Reviewed-by: Alex Bennée
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-10-richard.hender...@linaro.org>
---
include/exec/cpu-all.h | 12
accel/tcg/user-exec.c | 7 +++
2 files ch
We adjust CONFIG_ATOMIC128 and CONFIG_CMPXCHG128 with
CONFIG_ATOMIC128_OPT in atomic128.h. It is difficult
to tell when those changes have been applied with the
ifdef we must use with CONFIG_CMPXCHG128. So instead
use HAVE_CMPXCHG128, which triggers -Werror-undef when
the proper header has not be
Use 'last' variables instead of 'end' variables; be careful
about avoiding overflow. Assert that the mmap succeeded.
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-21-richard.hender...@linaro.org>
---
linux-user/mmap.c | 68 +--
1 f
Replace the 0/-1 result with true/false.
Invert the sense of the test of all callers.
Document the function.
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-25-richard.hender...@linaro.org>
---
bsd-user/qemu.h| 2 +-
include/exec/cpu-all.h | 13
If !reserved_va, munmap instead and assert success.
Update all callers.
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-22-richard.hender...@linaro.org>
---
linux-user/mmap.c | 29 -
1 file changed, 16 insertions(+), 13 deletions(-)
diff --git a/lin
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 12 ++--
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index 45ebacd4b4..e4fcbd16d2 100644
--- a/linux-user/syscall_d
We had done this for user-mode by invoking page_protect
within the translator loop. Extend this to handle system
mode as well. Move page locking out of tb_link_page.
Reported-by: Liren Wei
Reported-by: Richard W.M. Jones
Signed-off-by: Richard Henderson
Tested-by: Richard W.M. Jones
---
acc
Move the values into the per-target target_mman.h headers
Reviewed-by: Alex Bennée
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-8-richard.hender...@linaro.org>
---
linux-user/aarch64/target_mman.h | 8
linux-user/generic/target
From: Philippe Mathieu-Daudé
Since commit fbd3c4cff6 ("linux-user/arm: Mark the commpage
executable") executing bare-metal (linked with rdimon.specs)
cortex-M code fails as:
$ qemu-arm -cpu cortex-m3 ~/hello.exe.m3
qemu-arm: ../../accel/tcg/user-exec.c:492: page_set_flags: Assertion `last <=
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index 9dc41828cf..c8ffb4f785 100644
--- a/linux-user/syscall_defs.h
+++
Fix all checkpatch.pl errors within mmap.c.
Reviewed-by: Alex Bennée
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-5-richard.hender...@linaro.org>
---
linux-user/mmap.c | 199 --
1 file changed,
Only PAGE_WRITE needs special attention, all others can be
handled as we do for PAGE_READ. Adjust the mask.
Signed-off-by: Richard Henderson
Reviewed-by: Philippe Mathieu-Daudé
Message-Id: <20230707204054.8792-24-richard.hender...@linaro.org>
---
accel/tcg/user-exec.c | 4 ++--
1 file changed,
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index 21ca03b0f4..9dc41828cf 100644
--- a/linux-user/syscall_defs.h
+
From: Juan Quintela
These are types not used anymore anywhere else.
Signed-off-by: Juan Quintela
Reviewed-by: Richard Henderson
Reviewed-by: Laurent Vivier
Reviewed-by: Philippe Mathieu-Daudé
Message-id: <20230511085056.13809-1-quint...@redhat.com>
Signed-off-by: Richard Henderson
---
linu
Use 'last' variables instead of 'end' variables.
When host page size > guest page size, detect when
adjacent host pages have the same protection and
merge that expanded host range into fewer syscalls.
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-15-richard.hender...@linaro.or
The trivial length 0 check can be moved up, simplifying some
of the other cases. The end < start test is handled by
guest_range_valid_untagged.
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-27-richard.hender...@linaro.org>
---
linux-user/mmap.c | 19 ---
1 fi
Use page_check_range instead, which uses the interval tree
instead of checking each page individually.
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-26-richard.hender...@linaro.org>
---
linux-user/mmap.c | 24 +++-
1 file changed, 3 insertions(+), 21 delet
A zero bit value does not make sense -- it must relate to
some field in some way.
Define FLAG_BASIC with a build-time sanity check.
Adjust FLAG_GENERIC and FLAG_TARGET to use it.
Add FLAG_GENERIC_MASK and FLAG_TARGET_MASK.
Fix up the existing flag definitions for build errors.
Reviewed-by: Alex
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 108 +++---
1 file changed, 54 insertions(+), 54 deletions(-)
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index a4e4df8d3e..414d88a9ec 1006
Split out from validate_prot_to_pageflags, as there is not
one single host_prot for the entire range. We need to adjust
prot for every host page that overlaps multiple guest pages.
Reviewed-by: Alex Bennée
Signed-off-by: Richard Henderson
Message-Id: <20230707204054.8792-13-richard.hender...@li
Signed-off-by: Richard Henderson
---
linux-user/syscall_defs.h | 290 +++---
1 file changed, 145 insertions(+), 145 deletions(-)
diff --git a/linux-user/syscall_defs.h b/linux-user/syscall_defs.h
index 2846a8cfa5..20986bd1d3 100644
--- a/linux-user/syscall_defs.h
Complete the transition within the mmap functions to a formulation
that does not overflow at the end of the address space.
Signed-off-by: Richard Henderson
Reviewed-by: Philippe Mathieu-Daudé
Message-Id: <20230707204054.8792-20-richard.hender...@linaro.org>
---
linux-user/mmap.c | 45 ++
This commit refactors apic_mem_read/write to support both MMIO access in
xAPIC and MSR access in x2APIC.
Reviewed-by: Michael S. Tsirkin
Signed-off-by: Bui Quang Minh
---
hw/intc/apic.c | 79 ++--
hw/intc/trace-events | 4 +-
includ
This commit adds support for x2APIC transitions when writing to
MSR_IA32_APICBASE register and finally adds CPUID_EXT_X2APIC to
TCG_EXT_FEATURES.
Reviewed-by: Michael S. Tsirkin
Signed-off-by: Bui Quang Minh
---
hw/intc/apic.c | 50
hw/intc/api
As userspace APIC now supports x2APIC, intel interrupt remapping
hardware can be set to EIM mode when userspace local APIC is used.
Reviewed-by: Michael S. Tsirkin
Signed-off-by: Bui Quang Minh
---
hw/i386/intel_iommu.c | 11 ---
1 file changed, 11 deletions(-)
diff --git a/hw/i386/int
Hi everyone,
This series implements x2APIC mode in userspace local APIC and the
RDMSR/WRMSR helper to access x2APIC registers in x2APIC mode. Intel iommu
and AMD iommu are adjusted to support x2APIC interrupt remapping. With this
series, we can now boot Linux kernel into x2APIC mode with TCG accel
This commit adds XTSup configuration to let user choose to whether enable
this feature or not. When XTSup is enabled, additional bytes in IRTE with
enabled guest virtual VAPIC are used to support 32-bit destination id.
Additionally, this commit exports IVHD type 0x11 besides the old IVHD type
0x10
This commit extends the APIC ID to 32-bit long and remove the 255 max APIC
ID limit in userspace APIC. The array that manages local APICs is now
dynamically allocated based on the max APIC ID of created x86 machine.
Also, new x2APIC IPI destination determination scheme, self IPI and x2APIC
mode reg
On 7/15/23 21:28, Bui Quang Minh wrote:
Hi everyone,
This series implements x2APIC mode in userspace local APIC and the
RDMSR/WRMSR helper to access x2APIC registers in x2APIC mode. Intel iommu
and AMD iommu are adjusted to support x2APIC interrupt remapping. With this
series, we can now boot Li
Hi everyone,
This series implements x2APIC mode in userspace local APIC and the
RDMSR/WRMSR helper to access x2APIC registers in x2APIC mode. Intel iommu
and AMD iommu are adjusted to support x2APIC interrupt remapping. With this
series, we can now boot Linux kernel into x2APIC mode with TCG accel
This commit adds support for x2APIC transitions when writing to
MSR_IA32_APICBASE register and finally adds CPUID_EXT_X2APIC to
TCG_EXT_FEATURES.
Reviewed-by: Michael S. Tsirkin
Signed-off-by: Bui Quang Minh
---
hw/intc/apic.c | 50
hw/intc/api
This commit adds XTSup configuration to let user choose to whether enable
this feature or not. When XTSup is enabled, additional bytes in IRTE with
enabled guest virtual VAPIC are used to support 32-bit destination id.
Additionally, this commit exports IVHD type 0x11 besides the old IVHD type
0x10
This commit extends the APIC ID to 32-bit long and remove the 255 max APIC
ID limit in userspace APIC. The array that manages local APICs is now
dynamically allocated based on the max APIC ID of created x86 machine.
Also, new x2APIC IPI destination determination scheme, self IPI and x2APIC
mode reg
This commit refactors apic_mem_read/write to support both MMIO access in
xAPIC and MSR access in x2APIC.
Reviewed-by: Michael S. Tsirkin
Signed-off-by: Bui Quang Minh
---
hw/intc/apic.c | 79 ++--
hw/intc/trace-events | 4 +-
includ
As userspace APIC now supports x2APIC, intel interrupt remapping
hardware can be set to EIM mode when userspace local APIC is used.
Reviewed-by: Michael S. Tsirkin
Signed-off-by: Bui Quang Minh
---
hw/i386/intel_iommu.c | 11 ---
1 file changed, 11 deletions(-)
diff --git a/hw/i386/int
Am 11. Juli 2023 02:56:46 UTC schrieb Gurchetan Singh
:
>This adds initial support for gfxstream and cross-domain. Both
>features rely on virtio-gpu blob resources and context types, which
>are also implemented in this patch.
>
>gfxstream has a long and illustrious history in Android graphics
64 matches
Mail list logo