Re: [PATCH v5 00/17] tcg: CPUTLBEntryFull and TARGET_TB_PCREL

2022-09-28 Thread Mark Cave-Ayland
On 29/09/2022 03:16, Richard Henderson wrote: On 9/25/22 03:51, Richard Henderson wrote: Smooshing these two patch sets back together for review bandwidth. I hope to make this the next tcg-next pull. There are three from the first half, tlbentryfull, which are new. These are following a hallwa

Re: If your networking is failing after updating to the latest git version of QEMU...

2022-09-28 Thread Thomas Huth
On 29/09/2022 04.32, Jason Wang wrote: On Thu, Sep 29, 2022 at 1:06 AM Philippe Mathieu-Daudé wrote: On 28/9/22 10:27, Thomas Huth wrote: ... it might have happened due to the removal of the "slirp" submodule from the git repository. For example if you see an error message like this: Par

Re: [PATCH qemu v2 1/2] m68k: rework BI_VIRT_RNG_SEED as BI_RNG_SEED

2022-09-28 Thread Laurent Vivier
Le 26/09/2022 à 13:38, Jason A. Donenfeld a écrit : Following a change on the kernel side (see link), pass BI_RNG_SEED instead of BI_VIRT_RNG_SEED. This should have no impact on compatibility, as there will simply be no effect if it's an old kernel, which is how things have always been. We then u

Re: [PATCH 0/1] Update vfio-user module to the latest

2022-09-28 Thread Thomas Huth
On 29/09/2022 03.52, Jag Raman wrote: On Aug 29, 2022, at 8:40 AM, Thomas Huth wrote: On 07/08/2022 12.39, John Levon wrote: On Fri, Aug 05, 2022 at 09:24:56AM +0100, Daniel P. Berrangé wrote: [...] If we do add something as a submodule for some reason, I'd like us to say upfront that thi

Re: [PATCH v8 3/7] block: add block layer APIs resembling Linux ZonedBlockDevice ioctls

2022-09-28 Thread Markus Armbruster
Damien Le Moal writes: > On 9/1/22 23:57, Markus Armbruster wrote: >> Sam Li writes: >> >>> Markus Armbruster 于2022年8月31日周三 16:35写道: Sam Li writes: > Markus Armbruster 于2022年8月30日周二 19:57写道: [...] > Zoned_host_device is basically host_device + zone operations. It >>>

Re: [PATCH] tests: Add sndio to the FreeBSD CI containers / VM

2022-09-28 Thread Kyle Evans
On Wed, Sep 28, 2022 at 10:07 PM Brad Smith wrote: > > tests: Add sndio to the FreeBSD CI containers / VM > > Signed-off-by: Brad Smith > --- > .gitlab-ci.d/cirrus/freebsd-12.vars | 2 +- > .gitlab-ci.d/cirrus/freebsd-13.vars | 2 +- > tests/vm/freebsd| 3 +++ > 3 files chang

[PATCH] tests: Add sndio to the FreeBSD CI containers / VM

2022-09-28 Thread Brad Smith
tests: Add sndio to the FreeBSD CI containers / VM Signed-off-by: Brad Smith --- .gitlab-ci.d/cirrus/freebsd-12.vars | 2 +- .gitlab-ci.d/cirrus/freebsd-13.vars | 2 +- tests/vm/freebsd| 3 +++ 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.d/cirrus

Re: [PATCH v1 0/3] ui/gtk: Add a new parameter to assign connectors/monitors to Guests' windows

2022-09-28 Thread Markus Armbruster
"Kim, Dongwon" writes: > Hi Markus, > > Vivek and I have discussed this already. I am fine with replacing my old > series with this. Good to know, thank you!

Re: [PATCH v4 9/9] target/arm: Enable TARGET_TB_PCREL

2022-09-28 Thread Richard Henderson
On 9/22/22 07:07, Peter Maydell wrote: +/* + * For TARGET_TB_PCREL, the value relative to pc_curr against which + * offsets must be computed for cpu_pc. -1 if unknown due to jump. + */ I'm not really sure what this comment is trying to tell me. Could you expand it a bit ? Aft

Re: [PATCH v2 3/3] hw/intc: Fix LoongArch ipi device emulation

2022-09-28 Thread Richard Henderson
On 9/28/22 20:23, yangxiaojuan wrote: 在 2022/9/29 上午10:42, Richard Henderson 写道: On 9/26/22 23:12, Xiaojuan Yang wrote: In ipi_send function, it should not to set irq before writing data to dest cpu iocsr space, as the irq will trigger after data writing. Signed-off-by: Xiaojuan Yang ---   h

Re: [PATCH v2 1/4] target/loongarch: ftint_xxx insns set the result high 32bit 0xffffffff

2022-09-28 Thread gaosong
在 2022/9/28 下午11:14, Richard Henderson 写道: On 9/26/22 23:48, Song Gao wrote: we just set high 32bit 0x as the other float instructions do. Signed-off-by: Song Gao ---   target/loongarch/fpu_helper.c | 18 +-   1 file changed, 9 insertions(+), 9 deletions(-) But the res

Re: [PATCH v2 3/3] hw/intc: Fix LoongArch ipi device emulation

2022-09-28 Thread yangxiaojuan
在 2022/9/29 上午10:42, Richard Henderson 写道: On 9/26/22 23:12, Xiaojuan Yang wrote: In ipi_send function, it should not to set irq before writing data to dest cpu iocsr space, as the irq will trigger after data writing. Signed-off-by: Xiaojuan Yang ---   hw/intc/loongarch_ipi.c | 1 -   1 file c

Re: [PATCH v4 3/9] target/arm: Change gen_*set_pc_im to gen_*update_pc

2022-09-28 Thread Richard Henderson
On 9/22/22 07:04, Peter Maydell wrote: On Tue, 6 Sept 2022 at 11:13, Richard Henderson wrote: In preparation for TARGET_TB_PCREL, reduce reliance on absolute values by passing in pc difference. Signed-off-by: Richard Henderson --- @@ -263,14 +263,14 @@ static inline int curr_insn_len(Di

Re: [PATCH v2 3/3] hw/intc: Fix LoongArch ipi device emulation

2022-09-28 Thread Richard Henderson
On 9/26/22 23:12, Xiaojuan Yang wrote: In ipi_send function, it should not to set irq before writing data to dest cpu iocsr space, as the irq will trigger after data writing. Signed-off-by: Xiaojuan Yang --- hw/intc/loongarch_ipi.c | 1 - 1 file changed, 1 deletion(-) diff --git a/hw/intc/l

Re: [PATCH v2 2/3] hw/intc: Fix LoongArch extioi function

2022-09-28 Thread Richard Henderson
On 9/26/22 23:12, Xiaojuan Yang wrote: 1.When cpu read or write extioi COREISR reg, it should access the reg belonged to itself, so the index of 's->coreisr' is current cpu number. 2.Remove the unused extioi system memory region and we only support the extioi iocsr memory region now. Signed-off-

[PATCH] Hexagon (target/hexagon) Fix predicated assignment to .tmp

2022-09-28 Thread Taylor Simpson
Here is an example of an instruction with a predicated assignment to a .tmp HVX register if (p1) v12.tmp = vmem(%1 + #0) Note that the .tmp indicates that references to v12 in the same packet take the result of the load. However, when the predicate is false, the value at the start of the packe

Re: If your networking is failing after updating to the latest git version of QEMU...

2022-09-28 Thread Jason Wang
On Thu, Sep 29, 2022 at 1:06 AM Philippe Mathieu-Daudé wrote: > > On 28/9/22 10:27, Thomas Huth wrote: > > > > ... it might have happened due to the removal of the "slirp" submodule > > from the git repository. For example if you see an error message like this: > > > > Parameter 'type' expects a

Re: [PATCH v2 1/3] hw/loongarch: Add memmap for LoongArch virt machine

2022-09-28 Thread Richard Henderson
On 9/26/22 23:12, Xiaojuan Yang wrote: Using memmap table for loongarch virt machine type, this method comes from arm/riscv architectures. While being data driven is nice... +hwaddr base = ms->memmap[VIRT_ACPI_GED].base + ACPI_GED_EVT_SEL_LEN + ... these indexes are not really better th

Re: [PATCH v5 00/17] tcg: CPUTLBEntryFull and TARGET_TB_PCREL

2022-09-28 Thread Richard Henderson
On 9/25/22 03:51, Richard Henderson wrote: Smooshing these two patch sets back together for review bandwidth. I hope to make this the next tcg-next pull. There are three from the first half, tlbentryfull, which are new. These are following a hallway conversation with Peter about bits in MemTxAtt

Re: [PATCH 2/2] ast2600: Drop NEON from the CPU features

2022-09-28 Thread Joel Stanley
On Wed, 28 Sept 2022 at 16:47, Cédric Le Goater wrote: > > Currently, the CPU features exposed to the AST2600 QEMU machines are : > > half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt > vfpd32 lpae evtstrm > > But, the features of the Cortex A7 CPU on the Aspeed AST2600 A3 SoC > ar

Re: [PATCH 0/1] Update vfio-user module to the latest

2022-09-28 Thread Jag Raman
> On Aug 29, 2022, at 8:40 AM, Thomas Huth wrote: > > On 07/08/2022 12.39, John Levon wrote: >> On Fri, Aug 05, 2022 at 09:24:56AM +0100, Daniel P. Berrangé wrote: > [...] >>> If we do add something as a submodule for some reason, I'd like us to >>> say upfront that this is for a fixed time per

Re: [PATCH v9 4/4] target/riscv: smstateen knobs

2022-09-28 Thread Alistair Francis
On Mon, Sep 19, 2022 at 4:58 PM Mayuresh Chitale wrote: > > Add knobs to allow users to enable smstateen and also export it via the > ISA extension string. > > Signed-off-by: Mayuresh Chitale > Reviewed-by: Weiwei Li Reviewed-by: Alistair Francis Alistair > --- > target/riscv/cpu.c | 2 ++ >

Re: [PATCH v9 1/4] target/riscv: Add smstateen support

2022-09-28 Thread Alistair Francis
On Thu, Sep 29, 2022 at 10:58 AM weiwei wrote: > > > On 2022/9/19 14:29, Mayuresh Chitale wrote: > > Smstateen extension specifies a mechanism to close > > the potential covert channels that could cause security issues. > > > > This patch adds the CSRs defined in the specification and > > the corr

Re: [PATCH v1 1/1] hw/arm/xlnx-zynqmp: Connect ZynqMP's USB controllers

2022-09-28 Thread Alistair Francis
On Tue, Sep 20, 2022 at 6:23 PM Francisco Iglesias wrote: > > From: Francisco Iglesias > > Connect ZynqMP's USB controllers. > > Signed-off-by: Francisco Iglesias Acked-by: Alistair Francis Alistair > --- > hw/arm/xlnx-zynqmp.c | 36 > include/hw

Re: [PATCH v9 3/4] target/riscv: smstateen check for fcsr

2022-09-28 Thread weiwei
On 2022/9/19 14:29, Mayuresh Chitale wrote: If smstateen is implemented and sstateen0.fcsr is clear then the floating point operations must return illegal instruction exception or virtual instruction trap, if relevant. Signed-off-by: Mayuresh Chitale --- target/riscv/csr.c

[PULL 1/3] Hexagon (target/hexagon) add instruction attributes from archlib

2022-09-28 Thread Taylor Simpson
The imported files from the architecture library have added some instruction attributes. Some of these will be used in a subsequent patch for determing the size of a store. Signed-off-by: Taylor Simpson Acked-by: Richard Henderson Message-Id: <20220920080746.26791-2-tsimp...@quicinc.com> --- t

[PULL 3/3] Hexagon (target/hexagon) Change decision to set pkt_has_store_s[01]

2022-09-28 Thread Taylor Simpson
We have found cases where pkt_has_store_s[01] is set incorrectly. This leads to generating an unnecessary store that is left over from a previous packet. Add an attribute to determine if an instruction is a scalar store The attribute is attached to the fSTORE macro (hex_common.py) Update the logic

[PULL 2/3] Hexagon (target/hexagon) move store size tracking to translation

2022-09-28 Thread Taylor Simpson
The store width is needed for packet commit, so it is stored in ctx->store_width. Currently, it is set when a store has a TCG override instead of a QEMU helper. In the QEMU helper case, the ctx->store_width is not set, we invoke a helper during packet commit that uses the runtime store width. Th

[PULL 0/3] Hexagon (target/hexagon) improve store handling

2022-09-28 Thread Taylor Simpson
The following changes since commit dbc4f48b5ab3e6d85f78aa4df6bd6ad561c3d152: Merge tag 'net-pull-request' of https://github.com/jasowang/qemu into staging (2022-09-27 11:08:36 -0400) are available in the Git repository at: https://github.com/quic/qemu tags/pull-hex-20220928

Re: [PATCH v9 1/4] target/riscv: Add smstateen support

2022-09-28 Thread weiwei
On 2022/9/19 14:29, Mayuresh Chitale wrote: Smstateen extension specifies a mechanism to close the potential covert channels that could cause security issues. This patch adds the CSRs defined in the specification and the corresponding predicates and read/write functions. Signed-off-by: Mayure

Re: [PATCH v3 5/5] hw/arm/virt: Add 'highmem-compact' property

2022-09-28 Thread Gavin Shan
Hi Eric, On 9/28/22 10:22 PM, Eric Auger wrote: On 9/22/22 01:13, Gavin Shan wrote: After the improvement to high memory region address assignment is applied, the memory layout is changed. For example, VIRT_HIGH_PCIE_MMIO s/the memory layout is changed./the memory layout is changed, introducin

Re: [PATCH v3 4/5] hw/arm/virt: Improve high memory region address assignment

2022-09-28 Thread Gavin Shan
Hi Eric, On 9/28/22 10:51 PM, Eric Auger wrote: On 9/22/22 01:13, Gavin Shan wrote: There are three high memory regions, which are VIRT_HIGH_REDIST2, VIRT_HIGH_PCIE_ECAM and VIRT_HIGH_PCIE_MMIO. Their base addresses are floating on highest RAM address. However, they can be disabled in several c

Re: [PATCH v2 31/66] target/arm: Fix S2 disabled check in S1_ptw_translate

2022-09-28 Thread Richard Henderson
On 9/20/22 09:01, Peter Maydell wrote: This doesn't actually change the behaviour, though, right? regime_translation_disabled() at this point in the patchset doesn't do anything that makes a distinction between Stage2_S and Stage2 AFAICT. So this is just making the code clearer; we fixed the actu

Re: [PATCH v1 0/3] ui/gtk: Add a new parameter to assign connectors/monitors to Guests' windows

2022-09-28 Thread Kim, Dongwon
Hi Markus, Vivek and I have discussed this already. I am fine with replacing my old series with this. Thanks, DW On 9/20/2022 11:06 PM, Markus Armbruster wrote: "Kasireddy, Vivek" writes: Hi Markus, Any overlap with Dongwon Kim's "[PATCH v5 0/2] handling guest multiple displays"? [Kas

Re: [PATCH v3 3/5] hw/arm/virt: Introduce variable region_base in virt_set_high_memmap()

2022-09-28 Thread Gavin Shan
Hi Eric, On 9/28/22 10:10 PM, Eric Auger wrote: On 9/22/22 01:13, Gavin Shan wrote: This introduces variable 'region_base' for the base address of the specific high memory region. It's the preparatory work to optimize high memory region address assignment. Why is it a preparatory work (same co

Re: [PATCH qemu v2 2/2] m68k: align bootinfo strings and data to 4 bytes

2022-09-28 Thread Jason A. Donenfeld
On Mon, Sep 26, 2022 at 11:42:37PM +0200, Jason A. Donenfeld wrote: > On Mon, Sep 26, 2022 at 11:42 PM Laurent Vivier wrote: > > > > Le 26/09/2022 à 23:40, Jason A. Donenfeld a écrit : > > > On Mon, Sep 26, 2022 at 11:37 PM Laurent Vivier wrote: > > >> > > >> Le 26/09/2022 à 13:39, Jason A. Donen

Re: [PATCH 1/2] target/arm: Disable VFPv4-D32 when NEON is not available

2022-09-28 Thread Joel Stanley
On Wed, 28 Sept 2022 at 16:47, Cédric Le Goater wrote: > > As the Cortex A7 MPCore Technical reference says : > > "When FPU option is selected without NEON, the FPU is VFPv4-D16 and > uses 16 double-precision registers. When the FPU is implemented with > NEON, the FPU is VFPv4-D32 and uses 3

RE: [PATCH v2 3/3] hw/timer: ibex_timer.c: Add support for writes to mtime

2022-09-28 Thread Dong, Eddie
From: Tyler Ng Sent: Monday, September 26, 2022 4:38 PM To: Dong, Eddie Cc: open list:RISC-V ; qemu-devel@nongnu.org Developers ; Alistair Francis ; Meng, Bin ; Thomas Huth ; Paolo Bonzini ; Palmer Dabbelt ; Laurent Vivier Subject: Re: [PATCH v2 3/3] hw/timer: ibex_timer.c: Add support fo

Re: [PATCH v1 09/10] contrib/plugins: reset skip when matching in execlog

2022-09-28 Thread Richard Henderson
On 9/21/22 09:08, Alex Bennée wrote: The purpose of the matches was to only track the execution of instructions we care about. Without resetting skip to the value at the start of the block we end up dumping all instructions after the match with the consequent load on the instrumentation. Signed-

Re: [PATCH v1 04/10] tests/tcg: add memory-sve test for aarch64

2022-09-28 Thread Richard Henderson
On 9/21/22 09:07, Alex Bennée wrote: This will be helpful in debugging problems with tracking SVE memory accesses via the TCG plugins system. Signed-off-by: Alex Bennée Cc: Robert Henry Cc: Aaron Lindsay --- tests/tcg/aarch64/Makefile.softmmu-target | 7 +++ tests/tcg/aarch64/system/bo

Re: [PATCH 1/6] tests/avocado/machine_aspeed.py: Fix typos on buildroot

2022-09-28 Thread Joel Stanley
On Fri, 23 Sept 2022 at 08:48, Cédric Le Goater wrote: > > Replace 'buidroot' and 'builroot' by 'buildroot'. > > Fixes: f7bc7da0724f ("test/avocado/machine_aspeed.py: Add tests using > buildroot images") > Signed-off-by: Cédric Le Goater Reviewed-by: Joel Stanley

Re: [PATCH 2/2] virtio-blk: add zoned storage emulation for zoned devices

2022-09-28 Thread Damien Le Moal
On 2022/09/29 4:55, Sam Li wrote: > Stefan Hajnoczi 于2022年9月20日周二 05:31写道: [...] >>> +static void virtio_blk_zone_append_complete(void *opaque, int ret) { >>> +ZoneCmdData *data = opaque; >>> +VirtIOBlockReq *req = data->req; >>> +VirtIOBlock *s = req->dev; >>> +VirtIODevice *vdev

Re: [RFC PATCH] tests/qtest: bump up QOS_PATH_MAX_ELEMENT_SIZE

2022-09-28 Thread Paolo Bonzini
Il mar 27 set 2022, 23:35 Alex Bennée ha scritto: > It seems the depth of path we need to With s/path/stack/, Acked-by: Paolo Bonzini Paolo support can vary depending on the order of the init constructors getting called. It seems > --enable-lto shuffles things around just enough to push y

Re: [RFC PATCH] tests/qtest: bump up QOS_PATH_MAX_ELEMENT_SIZE

2022-09-28 Thread Paolo Bonzini
Oh, wait, this is not a path! This is the stack for a graph visit, and the limit is not the maximum length of the path, but rather the number of nodes in the graph. In other words, QOS_PATH_MAX_ELEMENT_SIZE is being overloaded and using it in qos_node_stack is wrong. The solution is to use a linke

[PATCH] ui/gtk-egl: egl context needs to be unbound in the end of gd_egl_switch

2022-09-28 Thread Dongwon Kim
A thread often fails to bind an egl context to itself after guest VM is rebooted because the context is still owned by another thread. It is not very clear what condition makes this happen but this can be prevented by unbinding the context from the thread in the end of gd_egl_switch. Cc: Gerd Hoff

Re: Why we should avoid new submodules if possible

2022-09-28 Thread Michal Suchánek
On Wed, Sep 28, 2022 at 05:07:48PM -0400, Michael S. Tsirkin wrote: > On Wed, Sep 28, 2022 at 10:48:03PM +0200, Michal Suchánek wrote: > > Hello, > > > > On Tue, Jun 28, 2022 at 07:00:59AM -0400, Michael S. Tsirkin wrote: > > > > > > > > git submodules are awkward basically because they are an a

Re: Why we should avoid new submodules if possible

2022-09-28 Thread Michael S. Tsirkin
On Wed, Sep 28, 2022 at 10:48:03PM +0200, Michal Suchánek wrote: > Hello, > > On Tue, Jun 28, 2022 at 07:00:59AM -0400, Michael S. Tsirkin wrote: > > > > > git submodules are awkward basically because they are an automated wget. > > I don't think an explicit wget is much better ... but > > looks

Re: [PATCH v2] target/hppa: Generate illegal instruction exception for 64-bit instructions

2022-09-28 Thread Richard Henderson
On 9/28/22 11:49, Helge Deller wrote: Qemu currently emulates a 32-bit CPU only, and crashes with this error when it faces a 64-bit load (e.g. "ldd 0(r26),r0") or a 64-bit store (e.g. "std r26,0(r26)") instruction in the guest: ERROR:../qemu/tcg/tcg-op.c:2822:tcg_canonicalize_memop: code should

Re: [PATCH 8/8] linux-user: Log tid for strace

2022-09-28 Thread Laurent Vivier
Le 29/08/2022 à 04:10, Richard Henderson a écrit : Printing the same pid for all threads isn't helpful. Signed-off-by: Richard Henderson --- linux-user/strace.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linux-user/strace.c b/linux-user/strace.c index c47d91bb3d..ca9

[PULL 34/37] linux-user: Implement PI futexes

2022-09-28 Thread Laurent Vivier
From: Richard Henderson Define the missing FUTEX_* constants in syscall_defs.h Signed-off-by: Richard Henderson Reviewed-by: Laurent Vivier Message-Id: <20220829021006.67305-6-richard.hender...@linaro.org> Signed-off-by: Laurent Vivier --- linux-user/syscall.c | 10 ++ linux-use

Re: [PATCH 4/5] configure, meson: move C++ compiler detection to meson.build

2022-09-28 Thread Richard Henderson
On 9/28/22 12:21, Paolo Bonzini wrote: Heh, I wanted to get it in for exactly that reason, so that a future revert would not introduce the test in configure. But I guess having the patch out there on the archives may also be enough. Heh. I suppose that's fair, being wary of reversion. r~

[PULL 36/37] linux-user: Lock log around strace

2022-09-28 Thread Laurent Vivier
From: Richard Henderson Do not allow syscall arguments to be interleaved between threads. Signed-off-by: Richard Henderson Reviewed-by: Laurent Vivier Message-Id: <20220829021006.67305-8-richard.hender...@linaro.org> Signed-off-by: Laurent Vivier --- linux-user/strace.c | 65

[PULL 32/37] linux-user: Implement FUTEX_WAKE_BITSET

2022-09-28 Thread Laurent Vivier
From: Richard Henderson Signed-off-by: Richard Henderson Reviewed-by: Laurent Vivier Message-Id: <20220829021006.67305-4-richard.hender...@linaro.org> Signed-off-by: Laurent Vivier --- linux-user/syscall.c | 1 + 1 file changed, 1 insertion(+) diff --git a/linux-user/syscall.c b/linux-user/s

Re: [RFC PATCH] semihosting: update link to spec

2022-09-28 Thread Richard Henderson
On 9/28/22 12:04, Alex Bennée wrote: The old link has moved but it seems the document is now hosted on Arm's github along with a license update to CC-BY-SA-4.0. Signed-off-by: Alex Bennée --- semihosting/arm-compat-semi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Reviewed-by: Ri

[PULL 37/37] linux-user: Add parameters of getrandom() syscall for strace

2022-09-28 Thread Laurent Vivier
From: Helge Deller Signed-off-by: Helge Deller Reviewed-by: Laurent Vivier Message-Id: <20220927093538.8954-2-del...@gmx.de> Signed-off-by: Laurent Vivier --- linux-user/strace.list | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linux-user/strace.list b/linux-user/strace.

[PULL 30/37] linux-user: Combine do_futex and do_futex_time64

2022-09-28 Thread Laurent Vivier
From: Richard Henderson Pass a boolean to select between time32 and time64. Signed-off-by: Richard Henderson Reviewed-by: Laurent Vivier Message-Id: <20220829021006.67305-2-richard.hender...@linaro.org> Signed-off-by: Laurent Vivier --- linux-user/syscall.c | 67 -

[PULL 25/37] linux-user: fix bug about missing signum convert of sigqueue

2022-09-28 Thread Laurent Vivier
From: fanwenjie Fixes: 66fb9763af ("basic signal handling") Fixes: cf8b8bfc50 ("linux-user: add support for rt_tgsigqueueinfo() system call") Signed-off-by: fanwenjie Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: Laurent Vivier --- linux-user/syscall.c | 4 ++-- 1 file changed, 2 insert

[PULL 20/37] linux-user/hppa: Add signal trampoline for hppa target

2022-09-28 Thread Laurent Vivier
From: Helge Deller In Linux kernel v5.18 the vDSO for signal trampoline was added. This code mimiks the bare minimum of this vDSO and thus avoids that the parisc emulation needs executable stacks. Signed-off-by: Helge Deller Message-Id: <20220924114501.21767-4-del...@gmx.de> Signed-off-by: Laur

[PULL 33/37] linux-user: Convert signal number for FUTEX_FD

2022-09-28 Thread Laurent Vivier
From: Richard Henderson The val argument to FUTEX_FD is a signal number. Convert to match the host, as it will be converted back when the signal is delivered. Signed-off-by: Richard Henderson Reviewed-by: Laurent Vivier Message-Id: <20220829021006.67305-5-richard.hender...@linaro.org> Signed-

[PULL 35/37] linux-user: Update print_futex_op

2022-09-28 Thread Laurent Vivier
From: Richard Henderson Use a table for the names; print unknown values in hex, since the value contains flags. Signed-off-by: Richard Henderson Message-Id: <20220829021006.67305-7-richard.hender...@linaro.org> [lv: update print_futex() according to "linux-user: Show timespec on strace for fute

[PULL 31/37] linux-user: Sink call to do_safe_futex

2022-09-28 Thread Laurent Vivier
From: Richard Henderson Leave only the argument adjustments within the shift, and sink the actual syscall to the end. Sink the timespec conversion as well, as there will be more users. Signed-off-by: Richard Henderson Reviewed-by: Laurent Vivier Message-Id: <20220829021006.67305-3-richard.hen

[PULL 21/37] linux-user/hppa: Drop stack guard page on hppa target

2022-09-28 Thread Laurent Vivier
From: Helge Deller The stack-overflow check when building the "grep" debian package fails on the debian hppa target. Reason is, that the guard page at the top of the stack (which is added by qemu) prevents the fault handler in the grep program to properly detect the stack overflow. The Linux ker

[PULL 24/37] linux-user/hppa: Fix setup_sigcontext()

2022-09-28 Thread Laurent Vivier
From: Helge Deller We don't emulate a preemptive kernel on this level, and the hppa architecture doesn't allow context switches on the gateway page. So we always have to return to sc_iaoq[] and not to gr[31]. This fixes the remaining random segfaults which still occured. Signed-off-by: Helge Del

[PULL 27/37] linux-user/s390x: Save/restore fpc when handling a signal

2022-09-28 Thread Laurent Vivier
From: Ilya Leoshkevich Linux kernel does this in fpregs_store() and fpregs_load(), so qemu-user should do this as well. Found by running valgrind's none/tests/s390x/test_sig. Signed-off-by: Ilya Leoshkevich Reviewed-by: Richard Henderson Message-Id: <20220817123902.585623-1-...@linux.ibm.com>

[PULL 16/37] linux-user: Passthrough MADV_DONTNEED for certain file mappings

2022-09-28 Thread Laurent Vivier
From: Ilya Leoshkevich This is a follow-up for commit 892a4f6a750a ("linux-user: Add partial support for MADV_DONTNEED"), which added passthrough for anonymous mappings. File mappings can be handled in a similar manner. In order to do that, mark pages, for which mmap() was passed through, with P

[PULL 18/37] linux-user: Fix TARGET_PROT_SEM for XTENSA

2022-09-28 Thread Laurent Vivier
From: Helge Deller The xtensa platform has a value of 0x10 for PROT_SEM. Signed-off-by: Helge Deller Reviewed-by: Laurent Vivier Message-Id: <20220924114501.21767-2-del...@gmx.de> Signed-off-by: Laurent Vivier --- linux-user/syscall_defs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-

Re: Why we should avoid new submodules if possible

2022-09-28 Thread Michal Suchánek
Hello, On Tue, Jun 28, 2022 at 07:00:59AM -0400, Michael S. Tsirkin wrote: > > git submodules are awkward basically because they are an automated wget. > I don't think an explicit wget is much better ... but > looks like I'm alone in this. Oh well. > So it will be a weird dance of wget a tarball

[PULL 06/37] linux-user: Log failing executable in EXCP_DUMP()

2022-09-28 Thread Laurent Vivier
From: Helge Deller Enhance the EXCP_DUMP() macro to print out the failing program too. During debugging it's sometimes hard to track down the actual failing program if you are e.g. building a whole debian package. Signed-off-by: Helge Deller Reviewed-by: Laurent Vivier Reviewed-by: Philippe Ma

[PULL 26/37] linux-user: Don't assume 0 is not a valid host timer_t value

2022-09-28 Thread Laurent Vivier
From: Peter Maydell For handling guest POSIX timers, we currently use an array g_posix_timers[], whose entries are a host timer_t value, or 0 for "this slot is unused". When the guest calls the timer_create syscall we look through the array for a slot containing 0, and use that for the new timer

[PULL 13/37] linux-user: Provide MADV_* definitions

2022-09-28 Thread Laurent Vivier
From: Ilya Leoshkevich Provide MADV_* definitions using target_mman.h header, similar to what kernel does. Most architectures use the same values, with the exception of alpha and hppa. Signed-off-by: Ilya Leoshkevich Reviewed-by: Richard Henderson Message-Id: <20220906000839.1672934-2-...@linu

[PULL 29/37] linux-user: Set ELF_BASE_PLATFORM for MIPS

2022-09-28 Thread Laurent Vivier
From: Jiaxun Yang Match most appropriate base platform string based on insn_flags. Logic is aligned with aligned with set_isa() from arch/mips/kernel/cpu-probe.c in Linux kernel. Signed-off-by: Jiaxun Yang Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20220803103009.95972-3-jiaxun.y...@flyg

[PULL 01/37] linux-user: use 'max' instead of 'qemu32' / 'qemu64' by default

2022-09-28 Thread Laurent Vivier
From: Daniel P. Berrangé The 'qemu64' CPU model implements the least featureful x86_64 CPU that's possible. Historically this hasn't been an issue since it was rare for OS distros to build with a higher mandatory CPU baseline. With RHEL-9, however, the entire distro is built for the x86_64-v2 AB

[PULL 22/37] linux-user/hppa: Increase guest stack size to 80MB for hppa target

2022-09-28 Thread Laurent Vivier
From: Helge Deller The hppa target requires a much bigger stack than many other targets, and the Linux kernel allocates 80 MB by default for it. This patch increases the guest stack for hppa to 80MB, and prevents that this default stack size gets reduced by a lower stack limit on the host. Sinc

[PULL 15/37] linux-user: Implement stracing madvise()

2022-09-28 Thread Laurent Vivier
From: Ilya Leoshkevich The default implementation has several problems: the first argument is not displayed as a pointer, making it harder to grep; the third argument is not symbolized; and there are several extra unused arguments. Signed-off-by: Ilya Leoshkevich Reviewed-by: Richard Henderson

[PULL 28/37] linux-user: Introduce stubs for ELF AT_BASE_PLATFORM

2022-09-28 Thread Laurent Vivier
From: Jiaxun Yang AT_BASE_PLATFORM is a elf auxiliary vector pointing to a string to pass some architecture information. See getauxval(3) man-page. Signed-off-by: Jiaxun Yang Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20220803103009.95972-2-jiaxun.y...@flygoat.com> Signed-off-by: Laurent

[PULL 23/37] linux-user/hppa: Allow PROT_GROWSUP and PROT_GROWSDOWN in mprotect()

2022-09-28 Thread Laurent Vivier
From: Helge Deller The hppa platform uses an upwards-growing stack and required in Linux kernels < 5.18 an executable stack for signal processing. For that some executables and libraries are marked to have an executable stack, for which glibc uses the mprotect() syscall to mark the stack like th

[PULL 14/37] linux-user: Fix madvise(MADV_DONTNEED) on alpha

2022-09-28 Thread Laurent Vivier
From: Ilya Leoshkevich MADV_DONTNEED has a different value on alpha, compared to all the other architectures. Fix by using TARGET_MADV_DONTNEED instead of MADV_DONTNEED. Fixes: 892a4f6a750a ("linux-user: Add partial support for MADV_DONTNEED") Signed-off-by: Ilya Leoshkevich Reviewed-by: Richar

[PULL 10/37] linux-user/hppa: Set TASK_UNMAPPED_BASE to 0xfa000000 for hppa arch

2022-09-28 Thread Laurent Vivier
From: Helge Deller On the parisc architecture the stack grows upwards. Move the TASK_UNMAPPED_BASE to high memory area as it's done by the kernel on physical machines. Signed-off-by: Helge Deller Message-Id: <20220918194555.83535-9-del...@gmx.de> Signed-off-by: Laurent Vivier --- linux-user/m

[PULL 17/37] tests/tcg/linux-test: Add linux-madvise test

2022-09-28 Thread Laurent Vivier
From: Ilya Leoshkevich Add a test that checks madvise(MADV_DONTNEED) behavior with anonymous and file mappings in order to prevent regressions. Signed-off-by: Ilya Leoshkevich Reviewed-by: Richard Henderson Message-Id: <20220906000839.1672934-6-...@linux.ibm.com> Signed-off-by: Laurent Vivier

[PULL 19/37] linux-user: Add proper strace format strings for getdents()/getdents64()

2022-09-28 Thread Laurent Vivier
From: Helge Deller Signed-off-by: Helge Deller Message-Id: <20220924114501.21767-3-del...@gmx.de> Signed-off-by: Laurent Vivier --- linux-user/strace.list | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/linux-user/strace.list b/linux-user/strace.list index c6f748505a9e.

[PULL 12/37] linux-user: Show timespec on strace for futex()

2022-09-28 Thread Laurent Vivier
From: Helge Deller Signed-off-by: Helge Deller Reviewed-by: Laurent Vivier Message-Id: <20220918194555.83535-11-del...@gmx.de> Signed-off-by: Laurent Vivier --- linux-user/strace.c | 11 ++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/linux-user/strace.c b/linux-user

[PULL 02/37] linux-user: fix readlinkat handling with magic exe symlink

2022-09-28 Thread Laurent Vivier
From: Jameson Nash Exactly the same as f17f4989fa193fa8279474c5462289a3cfe69aea before was for readlink. I suppose this was simply missed at the time. Signed-off-by: Jameson Nash Reviewed-by: Laurent Vivier Message-Id: <20220808190727.875155-1-vtjn...@gmail.com> Signed-off-by: Laurent Vivier

[PULL 07/37] linux-user/hppa: Use EXCP_DUMP() to show enhanced debug info

2022-09-28 Thread Laurent Vivier
From: Helge Deller Enhance the hppa linux-user cpu_loop() to show more debugging info on hard errors. Signed-off-by: Helge Deller Reviewed-by: Laurent Vivier Message-Id: <20220918194555.83535-6-del...@gmx.de> Signed-off-by: Laurent Vivier --- linux-user/hppa/cpu_loop.c | 6 +- 1 file cha

[PULL 11/37] linux-user: Add strace for clock_nanosleep()

2022-09-28 Thread Laurent Vivier
From: Helge Deller Signed-off-by: Helge Deller Reviewed-by: Laurent Vivier Message-Id: <20220918194555.83535-10-del...@gmx.de> Signed-off-by: Laurent Vivier --- linux-user/strace.c| 15 +++ linux-user/strace.list | 3 ++- 2 files changed, 17 insertions(+), 1 deletion(-) diff

[PULL 04/37] linux-user: Add missing clock_gettime64() syscall strace

2022-09-28 Thread Laurent Vivier
From: Helge Deller Allow linux-user to strace the clock_gettime64() syscall. This syscall is used a lot on 32-bit guest architectures which use newer glibc versions. Signed-off-by: Helge Deller Reviewed-by: Laurent Vivier Message-Id: <20220918194555.83535-3-del...@gmx.de> Signed-off-by: Lauren

[PULL 08/37] linux-user/hppa: Dump IIR on register dump

2022-09-28 Thread Laurent Vivier
From: Helge Deller Include the IIR register (which holds the opcode of the failing instruction) when dumping the hppa registers. Signed-off-by: Helge Deller Reviewed-by: Laurent Vivier Reviewed-by: Philippe Mathieu-Daudé Message-Id: <20220918194555.83535-7-del...@gmx.de> Signed-off-by: Lauren

[PULL 03/37] linux-user: Add missing signals in strace output

2022-09-28 Thread Laurent Vivier
From: Helge Deller Some of the guest signal numbers are currently not converted to their representative names in the strace output, e.g. SIGVTALRM. This patch introduces a smart way to generate and keep in sync the host-to-guest and guest-to-host signal conversion tables for usage in the qemu si

[PULL 09/37] linux-user: Fix strace of chmod() if mode == 0

2022-09-28 Thread Laurent Vivier
From: Helge Deller If the mode parameter of chmod() is zero, this value isn't shown when stracing a program: chmod("filename",) This patch fixes it up to show the zero-value as well: chmod("filename",000) Signed-off-by: Helge Deller Reviewed-by: Laurent Vivier Reviewed-by: Philippe Mat

[PULL 05/37] linux-user: Add pidfd_open(), pidfd_send_signal() and pidfd_getfd() syscalls

2022-09-28 Thread Laurent Vivier
From: Helge Deller I noticed those were missing when running the glib2.0 testsuite. Add the syscalls including the strace output. Signed-off-by: Helge Deller Reviewed-by: Laurent Vivier Message-Id: <20220918194555.83535-4-del...@gmx.de> Signed-off-by: Laurent Vivier --- linux-user/strace.c

[PULL 00/37] Linux user for 7.2 patches

2022-09-28 Thread Laurent Vivier
ll request 20220928-v2 use 'max' instead of 'qemu32' / 'qemu64' add pidfd_open(), pidfd_send_signal() and pidfd_getfd() Improve madvise(MADV_DONTNEED) futex syscal rework strace improvement HP/PA fixes and improvement Misc fixes --

Re: [PULL 00/38] Linux user for 7.2 patches

2022-09-28 Thread Laurent Vivier
Le 28/09/2022 à 22:04, Stefan Hajnoczi a écrit : Hi Laurent, There is a build failure for hexagon linux-user. Please take a look (I didn't verify whether it's caused by your pull request, but I think the chance is high): cc -m64 -mcx16 -Ilibqemu-hexagon-linux-user.fa.p -I. -I.. -Itarget/hexagon

Re: [PATCH v5 11/12] blkio: implement BDRV_REQ_REGISTERED_BUF optimization

2022-09-28 Thread Alberto Campinho Faria
On Wed, Sep 28, 2022 at 8:21 PM Stefan Hajnoczi wrote: > On Tue, Sep 27, 2022 at 03:34:30PM -0400, Stefan Hajnoczi wrote: > > +ret = blkio_get_bool(s->blkio, > > + "mem-regions-pinned", > > + &s->mem_regions_pinned); > > +if (ret < 0) { > > +

Re: [PATCH v5 02/12] blkio: add libblkio block driver

2022-09-28 Thread Stefan Hajnoczi
On Wed, Sep 28, 2022 at 07:27:34AM +0200, Markus Armbruster wrote: > > +## > > +# @BlockdevOptionsVirtioBlkVhostVdpa: > > +# > > +# Driver specific block device options for the virtio-blk-vhost-vdpa > > backend. > > +# > > +# @path: path to the vhost-vdpa character device. > > +# > > +# Since: 7.2

Re: [PULL 00/38] Linux user for 7.2 patches

2022-09-28 Thread Stefan Hajnoczi
Hi Laurent, There is a build failure for hexagon linux-user. Please take a look (I didn't verify whether it's caused by your pull request, but I think the chance is high): cc -m64 -mcx16 -Ilibqemu-hexagon-linux-user.fa.p -I. -I.. -Itarget/hexagon -I../target/hexagon -I../common-user/host/x86_64 -I

Re: Why we should avoid new submodules if possible

2022-09-28 Thread Michael S. Tsirkin
On Wed, Sep 28, 2022 at 04:07:40PM +0100, Peter Maydell wrote: > On Wed, 28 Sept 2022 at 15:29, Michael S. Tsirkin wrote: > > > > On Wed, Sep 28, 2022 at 11:18:18AM +0100, Daniel P. Berrangé wrote: > > > On Wed, Sep 28, 2022 at 06:13:45AM -0400, Michael S. Tsirkin wrote: > > > > On Wed, Sep 28, 20

Re: [PATCH 2/2] virtio-blk: add zoned storage emulation for zoned devices

2022-09-28 Thread Sam Li
Stefan Hajnoczi 于2022年9月20日周二 05:31写道: > > On Sat, Sep 10, 2022 at 02:50:57PM +0800, Sam Li wrote: > > This patch extends virtio-blk emulation to handle zoned device commands > > by calling the new block layer APIs to perform zoned device I/O on > > behalf of the guest. It supports Report Zone, fo

Re: [PATCH v2 29/66] target/arm: Introduce arm_hcr_el2_eff_secstate

2022-09-28 Thread Richard Henderson
On 9/20/22 08:52, Peter Maydell wrote: On Mon, 22 Aug 2022 at 17:22, Richard Henderson wrote: For page walking, we may require HCR for a security state that is not "current". Signed-off-by: Richard Henderson --- target/arm/cpu.h| 20 +--- target/arm/helper.c | 11 +

Re: [Virtio-fs] virtiofsd: Any reason why there's not an "openat2" sandbox mode?

2022-09-28 Thread Vivek Goyal
On Wed, Sep 28, 2022 at 10:33:40AM +0200, Sergio Lopez wrote: > On Tue, Sep 27, 2022 at 04:14:20PM -0400, Stefan Hajnoczi wrote: > > On Tue, Sep 27, 2022 at 01:51:41PM -0400, Colin Walters wrote: > > > > > > > > > On Tue, Sep 27, 2022, at 1:27 PM, German Maglione wrote: > > > > > > > >> > Now all

Re: virtiofsd: Any reason why there's not an "openat2" sandbox mode?

2022-09-28 Thread Vivek Goyal
On Tue, Sep 27, 2022 at 07:27:02PM +0200, German Maglione wrote: > On Tue, Sep 27, 2022 at 6:57 PM Vivek Goyal wrote: > > > > On Tue, Sep 27, 2022 at 12:37:15PM -0400, Vivek Goyal wrote: > > > On Fri, Sep 09, 2022 at 05:24:03PM -0400, Colin Walters wrote: > > > > We previously had a chat here > >

Re: [PATCH 4/5] configure, meson: move C++ compiler detection to meson.build

2022-09-28 Thread Paolo Bonzini
Heh, I wanted to get it in for exactly that reason, so that a future revert would not introduce the test in configure. But I guess having the patch out there on the archives may also be enough. Paolo Il mer 28 set 2022, 18:25 Richard Henderson ha scritto: > On 9/27/22 02:59, Paolo Bonzini wrote

  1   2   3   4   >