[PATCH RESEND 0/2] build improvments

2022-04-29 Thread Konstantin Kostiuk
Resend because the series didn't reach the mailing list. Konstantin Kostiuk (2): configure: Add cross prefix for widl tool qga-vss: always build qga-vss.tlb when qga-vss.dll is built configure | 3 +++ qga/vss-win32/meson.build | 4 ++-- 2 files changed, 5 insertions(+), 2 de

[PATCH RESEND 1/2] configure: Add cross prefix for widl tool

2022-04-29 Thread Konstantin Kostiuk
The mingw-w64-tool package in Fedora provides widl tool with a cross prefix, so adds it automatically for cross builds. WIDL env can be used to redefine the path to tool. The same behavior as with windres. Signed-off-by: Konstantin Kostiuk --- configure | 3 +++ 1 file changed, 3 insertions(+)

[PATCH RESEND 2/2] qga-vss: always build qga-vss.tlb when qga-vss.dll is built

2022-04-29 Thread Konstantin Kostiuk
Signed-off-by: Konstantin Kostiuk --- qga/vss-win32/meson.build | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/qga/vss-win32/meson.build b/qga/vss-win32/meson.build index 71c50d0866..26c5dd6e0e 100644 --- a/qga/vss-win32/meson.build +++ b/qga/vss-win32/meson.build @@ -23,

[PATCH v2 2/2] ppc/xive: Update the state of the External interrupt signal

2022-04-29 Thread Frederic Barrat
When pulling or pushing an OS context from/to a CPU, we should re-evaluate the state of the External interrupt signal. Otherwise, we can end up catching the External interrupt exception in hypervisor mode, which is unexpected. The problem is best illustrated with the following scenario: 1. an Ext

Re: [PATCH v2 1/2] ppc/xive: Always recompute the PIPR when pushing an OS context

2022-04-29 Thread Cédric Le Goater
On 4/29/22 09:16, Frederic Barrat wrote: The Post Interrupt Priority Register (PIPR) is not restored like the other OS-context related fields of the TIMA when pushing an OS context on the CPU. It's not needed because it can be calculated from the Interrupt Pending Buffer (IPB), which is saved and

[PATCH v2 0/2] ppc/xive: Update for guest interrupt handling

2022-04-29 Thread Frederic Barrat
This short series fixes a couple of issues about interrupt handling found when running a KVM guest on the powernv9 and powernv10 models. I split a patch I previously sent. Changlog: v2: - update comment on patch 1 - picked up Cedric's reviewed-by on patch 2 Frederic Barrat (2): ppc/xive: Alwa

[PATCH v2 1/2] ppc/xive: Always recompute the PIPR when pushing an OS context

2022-04-29 Thread Frederic Barrat
The Post Interrupt Priority Register (PIPR) is not restored like the other OS-context related fields of the TIMA when pushing an OS context on the CPU. It's not needed because it can be calculated from the Interrupt Pending Buffer (IPB), which is saved and restored. The PIPR must therefore always b

Re: [PATCH] hw/arm: add versioning to sbsa-ref machine DT

2022-04-29 Thread Cédric Le Goater
On 4/27/22 20:29, Leif Lindholm wrote: The sbsa-ref machine is continuously evolving. Some of the changes we want to make in the near future, to align with real components (e.g. the GIC-700), will break compatibility for existing firmware. Introduce two new properties to the DT generated on mach

Re: [PATCH RESEND 0/2] build improvments

2022-04-29 Thread Paolo Bonzini
Queued, thanks. Paolo

[Bug 1970563] Re: Qemu Debian 1:6.2+dfsg-2ubuntu6 deadlock bug

2022-04-29 Thread Paride Legovini
** Also affects: qemu Importance: Undecided Status: New ** No longer affects: qemu -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1970563 Title: Qemu 1:6.2+dfsg-2ubuntu6 deadlock bug Sta

[Bug 1970563] Re: Qemu 1:6.2+dfsg-2ubuntu6 deadlock bug

2022-04-29 Thread Paride Legovini
Thanks, that report also has nice steps to reproduce. I updated the bug tags/status accordingly. ** Summary changed: - Qemu Debian 1:6.2+dfsg-2ubuntu6 deadlock bug + Qemu 1:6.2+dfsg-2ubuntu6 deadlock bug ** Also affects: qemu Importance: Undecided Status: New ** No longer affects: qem

Re: [PATCH v3 0/5] i386: Enable newly introduced KVM Hyper-V enlightenments

2022-04-29 Thread Paolo Bonzini
> This series enables four new KVM Hyper-V enlightenmtes [...] > > docs/hyperv.txt| 34 ++ Queued, thanks. Would you please convert hyperv.txt to rST in docs/system/i386? The various enlightenments can be converted to a definition list. Paolo

Re: [RFC PATCH v2 1/8] aio_wait_kick: add missing memory barrier

2022-04-29 Thread Emanuele Giuseppe Esposito
Am 28/04/2022 um 13:09 schrieb Stefan Hajnoczi: > On Tue, Apr 26, 2022 at 04:51:07AM -0400, Emanuele Giuseppe Esposito wrote: >> It seems that aio_wait_kick always required a memory barrier >> or atomic operation in the caller, but almost nobody actually >> took care of doing it. >> >> Let's put

Re: [RFC PATCH v2 0/8] Removal of AioContext lock, bs->parents and ->children: new rwlock

2022-04-29 Thread Emanuele Giuseppe Esposito
Am 28/04/2022 um 12:34 schrieb Stefan Hajnoczi: > On Tue, Apr 26, 2022 at 04:51:06AM -0400, Emanuele Giuseppe Esposito wrote: >> Next step is the most complex one: figure where to put the rdlocks. > > I got a little lost at this step but will hopefully understand more when > reading the patches

Re: [RFC PATCH v2 1/8] aio_wait_kick: add missing memory barrier

2022-04-29 Thread Paolo Bonzini
On 4/26/22 10:51, Emanuele Giuseppe Esposito wrote: It seems that aio_wait_kick always required a memory barrier or atomic operation in the caller, but almost nobody actually took care of doing it. I could not find any barrier in the callers, so I would remove the "almost". Paolo

[PATCH v2 0/5] hw/nvme: fix namespace identifiers

2022-04-29 Thread Klaus Jensen
From: Klaus Jensen The namespace identifiers reported by the controller is kind of a mess. See [1,2]. This series should fix this for both the `-device nvme,drive=...` and `-device nvme-ns,...` cases. [1]: https://lore.kernel.org/linux-nvme/20220224192845.1097602-1-...@lst.de/ [2]: https://

[PATCH v2 1/5] hw/nvme: enforce common serial per subsystem

2022-04-29 Thread Klaus Jensen
From: Klaus Jensen The Identify Controller Serial Number (SN) is the serial number for the NVM subsystem and must be the same across all controller in the NVM subsystem. Enforce this. Reviewed-by: Christoph Hellwig Reviewed-by: Keith Busch Signed-off-by: Klaus Jensen --- hw/nvme/nvme.h |

[PATCH v2 3/5] hw/nvme: do not auto-generate uuid

2022-04-29 Thread Klaus Jensen
From: Klaus Jensen Do not default to generate an UUID for namespaces if it is not explicitly specified. This is a technically a breaking change in behavior. However, since the UUID changes on every VM launch, it is not spec compliant and is of little use since the UUID cannot be used reliably an

[PATCH v2 2/5] hw/nvme: do not auto-generate eui64

2022-04-29 Thread Klaus Jensen
From: Klaus Jensen We cannot provide auto-generated unique or persistent namespace identifiers (EUI64, NGUID, UUID) easily. Since 6.1, namespaces have been assigned a generated EUI64 of the form "52:54:00:". This is will be unique within a QEMU instance, but not globally. Revert that this is ass

[PATCH v2 4/5] hw/nvme: do not report null uuid

2022-04-29 Thread Klaus Jensen
From: Klaus Jensen Do not report the "null uuid" (all zeros) in the namespace identification descriptors. Reported-by: Luis Chamberlain Reported-by: Christoph Hellwig Reviewed-by: Christoph Hellwig Reviewed-by: Keith Busch Signed-off-by: Klaus Jensen --- hw/nvme/ctrl.c | 17 +++

[PATCH v2 5/5] hw/nvme: bump firmware revision

2022-04-29 Thread Klaus Jensen
From: Klaus Jensen The Linux kernel quirks the QEMU NVMe controller pretty heavily because of the namespace identifier mess. Since this is now fixed, bump the firmware revision number to allow the quirk to be disabled for this revision. As of now, bump the firmware revision number to be equal to

Re: [RESEND][PATCH 0/2] acpi/nvdimm: support NVDIMM _LS{I,R,W} methods

2022-04-29 Thread Robert Hoo
On Wed, 2022-04-27 at 16:39 +0200, Igor Mammedov wrote: > On Tue, 12 Apr 2022 14:57:51 +0800 > Robert Hoo wrote: > > > The original NVDIMM _DSM functions (index 4~6) for label operations > > have > > been deprecated by new ACPI methods _LS{I,R,W}[1][2]. > > > > Patch 1 implements the new _LS{I,R

Re: [RFC PATCH v2 3/8] block: introduce a lock to protect graph operations

2022-04-29 Thread Emanuele Giuseppe Esposito
Am 28/04/2022 um 15:45 schrieb Stefan Hajnoczi: > On Tue, Apr 26, 2022 at 04:51:09AM -0400, Emanuele Giuseppe Esposito wrote: >> block layer graph operations are always run under BQL in the >> main loop. This is proved by the assertion qemu_in_main_thread() >> and its wrapper macro GLOBAL_STATE_

Re: [RFC PATCH v2 4/8] async: register/unregister aiocontext in graph lock list

2022-04-29 Thread Emanuele Giuseppe Esposito
Am 29/04/2022 um 00:19 schrieb Paolo Bonzini: > On 4/28/22 15:46, Stefan Hajnoczi wrote: >>>     if have_block >>>     util_ss.add(files('aiocb.c', 'async.c', 'aio-wait.c')) >>> +  util_ss.add(files('../block/graph-lock.c')) >> Why is it in block/ if it needs to be built into libqemuutil? > Mayb

Re: [PATCH RFC 04/10] intel_iommu: Second Stage Access Dirty bit support

2022-04-29 Thread Joao Martins
On 4/29/22 03:26, Jason Wang wrote: > On Fri, Apr 29, 2022 at 5:14 AM Joao Martins > wrote: >> @@ -3693,7 +3759,8 @@ static void vtd_init(IntelIOMMUState *s) >> >> /* TODO: read cap/ecap from host to decide which cap to be exposed. */ >> if (s->scalable_mode) { >> -s->ecap |= VT

Re: [RFC PATCH v2 5/8] block.c: wrlock in bdrv_replace_child_noperm

2022-04-29 Thread Emanuele Giuseppe Esposito
Am 28/04/2022 um 15:55 schrieb Stefan Hajnoczi: > On Tue, Apr 26, 2022 at 04:51:11AM -0400, Emanuele Giuseppe Esposito wrote: >> The only problem here is ->attach and ->detach callbacks >> could call bdrv_{un}apply_subtree_drain(), which itself >> will use a rdlock to navigate through all nodes.

Re: [PATCH 1/2] acpi/nvdimm: Create _LS{I,R,W} method for NVDIMM device

2022-04-29 Thread Robert Hoo
On Wed, 2022-04-27 at 16:34 +0200, Igor Mammedov wrote: > On Tue, 12 Apr 2022 14:57:52 +0800 > Robert Hoo wrote: > > > Since ACPI 6.2, previous NVDIMM/_DSM funcions "Get Namespace Label > > Data > > Size (function index 4)", "Get Namespace Label Data (function index > > 5)", > > "Set Namespace La

Re: [PATCH v3 0/5] i386: Enable newly introduced KVM Hyper-V enlightenments

2022-04-29 Thread Vitaly Kuznetsov
Paolo Bonzini writes: >> This series enables four new KVM Hyper-V enlightenmtes [...] >> >> docs/hyperv.txt| 34 ++ > > Queued, thanks. Thanks! > Would you please convert hyperv.txt to rST in docs/system/i386? Sure, it's on my TODO list. -- Vitaly

Re: [RFC PATCH v2 2/8] coroutine-lock: release lock when restarting all coroutines

2022-04-29 Thread Emanuele Giuseppe Esposito
Am 29/04/2022 um 00:14 schrieb Paolo Bonzini: > On 4/28/22 13:21, Stefan Hajnoczi wrote: >> It's unclear whether this patch fixes a bug or introduces a new API that >> will be used in later patches. >> >> The commit message is a bit misleading: existing functions are not >> changed to release th

Re: [PATCH v3 56/60] target/arm: Enable FEAT_CSV2_2 for -cpu max

2022-04-29 Thread Damien Hedde
On 4/17/22 19:44, Richard Henderson wrote: There is no branch prediction in TCG, therefore there is no need to actually include the context number into the predictor. Therefore all we need to do is add the state for SCXTNUM_ELx. > Signed-off-by: Richard Henderson --- v2: Update emulation.rst;

[PATCH v3 04/43] target/loongarch: Add fixed point arithmetic instruction translation

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This includes: - ADD.{W/D}, SUB.{W/D} - ADDI.{W/D}, ADDU16ID - ALSL.{W[U]/D} - LU12I.W, LU32I.D LU52I.D - SLT[U], SLT[U]I - PCADDI, PCADDU12I, PCADDU18I, PCALAU12I - AND, OR, NOR, XOR, ANDN, ORN - MUL.{W/D}, MULH.{W[U]/D[U]} - MULW.D.W[U] - DIV.{W[U]/D[U]}, MOD.{W[U]/D[U]} - ANDI,

[PATCH v3 01/43] target/loongarch: Add README

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This patch gives an introduction to the LoongArch target. Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson --- MAINTAINERS | 6 ++ target/loongarch/README | 10 ++ 2 files changed, 16 insertions(+) create mode 100644

[PATCH v3 09/43] target/loongarch: Add fixed point extra instruction translation

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This includes: - CRC[C].W.{B/H/W/D}.W - SYSCALL - BREAK - ASRT{LE/GT}.D - RDTIME{L/H}.W, RDTIME.D - CPUCFG Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson --- target/loongarch/helper.h | 4 ++ target/loongarch/insn_trans

[PATCH v3 00/43] Add LoongArch softmmu support

2022-04-29 Thread Xiaojuan Yang
Hi All, As this series only supports running binary files in ELF format, and does not depend on BIOS and kernel file. so this series are changed from RFC to patch v1. The manual: - https://github.com/loongson/LoongArch-Documentation/releases/tag/2022.03.17 Old series: - https://patchew.org

[PATCH v3 03/43] target/loongarch: Add main translation routines

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This patch adds main translation routines and basic functions for translation. Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson --- target/loongarch/helper.h| 6 ++ target/loongarch/op_helper.c | 21 + target/loongarch/translate.c

[PATCH v3 26/43] target/loongarch: Add LoongArch IOCSR instruction

2022-04-29 Thread Xiaojuan Yang
This includes: - IOCSR{RD/WR}.{B/H/W/D} Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao --- target/loongarch/cpu.c| 44 target/loongarch/cpu.h| 25 +++ target/loongarch/disas.c | 8 +++ target/loongarch/

[PATCH v3 02/43] target/loongarch: Add core definition

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This patch adds target state header, target definitions and initialization routines. Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson Reviewed-by: Philippe Mathieu-Daudé --- target/loongarch/cpu-param.h | 18 ++ target/loongarch/cpu.c

[PATCH v3 15/43] target/loongarch: Add branch instruction translation

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This includes: - BEQ, BNE, BLT[U], BGE[U] - BEQZ, BNEZ - B - BL - JIRL - BCEQZ, BCNEZ Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson --- .../loongarch/insn_trans/trans_branch.c.inc | 83 +++ target/loongarch/insns.decode

[PATCH v3 10/43] target/loongarch: Add floating point arithmetic instruction translation

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This includes: - F{ADD/SUB/MUL/DIV}.{S/D} - F{MADD/MSUB/NMADD/NMSUB}.{S/D} - F{MAX/MIN}.{S/D} - F{MAXA/MINA}.{S/D} - F{ABS/NEG}.{S/D} - F{SQRT/RECIP/RSQRT}.{S/D} - F{SCALEB/LOGB/COPYSIGN}.{S/D} - FCLASS.{S/D} Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Rich

[PATCH v3 17/43] target/loongarch: Add target build suport

2022-04-29 Thread Xiaojuan Yang
From: Song Gao Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson Reviewed-by: Philippe Mathieu-Daudé --- target/loongarch/meson.build | 19 +++ target/meson.build | 1 + 2 files changed, 20 insertions(+) create mode 100644 target/

[PATCH v3 16/43] target/loongarch: Add disassembler

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This patch adds support for disassembling via option '-d in_asm'. Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson --- include/disas/dis-asm.h | 2 + meson.build | 1 + target/loongarch/disas.c | 610

[PATCH v3 11/43] target/loongarch: Add floating point comparison instruction translation

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This includes: - FCMP.cond.{S/D} Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson --- target/loongarch/fpu_helper.c| 60 target/loongarch/helper.h| 9 +++ target/loongarch/insn_trans/t

[PATCH v3 18/43] target/loongarch: Add system emulation introduction

2022-04-29 Thread Xiaojuan Yang
Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- MAINTAINERS | 8 + docs/system/loongarch/loongson3.rst | 41 ++ target/loongarch/README | 54 + 3 files changed, 103 i

[PATCH v3 22/43] target/loongarch: Add MMU support for LoongArch CPU.

2022-04-29 Thread Xiaojuan Yang
Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- target/loongarch/cpu-param.h | 2 +- target/loongarch/cpu.c| 24 +++ target/loongarch/cpu.h| 51 ++ target/loongarch/internals.h | 9 + target/loongarch/machine.c| 17 ++ tar

[PATCH v3 31/43] hw/loongarch: Add LoongArch ipi interrupt support(IPI)

2022-04-29 Thread Xiaojuan Yang
This patch realize the IPI interrupt controller. Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- MAINTAINERS | 2 + hw/intc/Kconfig | 3 + hw/intc/loongarch_ipi.c | 242 hw/

[PATCH v3 30/43] hw/loongarch: Add support loongson3 virt machine type.

2022-04-29 Thread Xiaojuan Yang
Emulate a 3A5000 board use the new loongarch instruction. 3A5000 belongs to the Loongson3 series processors. The board consists of a 3A5000 cpu model and the virt bridge. The host 3A5000 board is really complicated and contains many functions.Now for the tcg softmmu mode only part functions are emu

[PATCH v3 21/43] target/loongarch: Implement qmp_query_cpu_definitions()

2022-04-29 Thread Xiaojuan Yang
Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- qapi/machine-target.json | 6 -- target/loongarch/cpu.c | 26 ++ 2 files changed, 30 insertions(+), 2 deletions(-) diff --git a/qapi/machine-target.json b/qapi/machine-target.

[PATCH v3 13/43] target/loongarch: Add floating point move instruction translation

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This includes: - FMOV.{S/D} - FSEL - MOVGR2FR.{W/D}, MOVGR2FRH.W - MOVFR2GR.{S/D}, MOVFRH2GR.S - MOVGR2FCSR, MOVFCSR2GR - MOVFR2CF, MOVCF2FR - MOVGR2CF, MOVCF2GR Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson --- target/loongarch/fpu_helper

[PATCH v3 40/43] hw/loongarch: Add LoongArch ls7a acpi device support

2022-04-29 Thread Xiaojuan Yang
Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao --- MAINTAINERS| 2 + hw/acpi/Kconfig| 4 + hw/acpi/ls7a.c | 374 + hw/acpi/meson.build| 1 + hw/loongarch/Kconfig | 2 + hw/loongarch/loongson3.

[PATCH v3 35/43] hw/loongarch: Add irq hierarchy for the system

2022-04-29 Thread Xiaojuan Yang
This patch add the irq hierarchy for the virt board. Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- hw/loongarch/loongson3.c | 116 +++ 1 file changed, 116 insertions(+) diff --git a/hw/loongarch/loongson3.c b/hw/loo

[PATCH v3 24/43] target/loongarch: Add constant timer support

2022-04-29 Thread Xiaojuan Yang
Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- target/loongarch/constant_timer.c | 64 +++ target/loongarch/cpu.c| 2 + target/loongarch/cpu.h| 4 ++ target/loongarch/internals.h | 6 +++ target

[PATCH v3 37/43] hw/loongarch: Add some devices support for 3A5000.

2022-04-29 Thread Xiaojuan Yang
1.Add uart,virtio-net,vga and usb for 3A5000. 2.Add irq set and map for the pci host. Non pci device use irq 0-16, pci device use 16-64. 3.Add some unimplented device to emulate guest unused memory space. Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Acked-by: Richard Henderson --- hw/l

[PATCH v3 12/43] target/loongarch: Add floating point conversion instruction translation

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This includes: - FCVT.S.D, FCVT.D.S - FFINT.{S/D}.{W/L}, FTINT.{W/L}.{S/D} - FTINT{RM/RP/RZ/RNE}.{W/L}.{S/D} - FRINT.{S/D} Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson --- target/loongarch/fpu_helper.c| 393 +++

[PATCH v3 42/43] tests/tcg/loongarch64: Add hello/memory test in loongarch64 system

2022-04-29 Thread Xiaojuan Yang
- We write a very minimal softmmu harness. - This is a very simple smoke test with no need to run a full Linux/kernel. - The Makefile.softmmu-target record the rule to run. Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- MAINTAINERS

[PATCH v3 34/43] hw/intc: Add LoongArch extioi interrupt controller(EIOINTC)

2022-04-29 Thread Xiaojuan Yang
This patch realize the EIOINTC interrupt controller. Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao --- hw/intc/Kconfig| 3 + hw/intc/loongarch_extioi.c | 248 + hw/intc/meson.build| 1 + hw/intc/trace-events

[PATCH v3 14/43] target/loongarch: Add floating point load/store instruction translation

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This includes: - FLD.{S/D}, FST.{S/D} - FLDX.{S/D}, FSTX.{S/D} - FLD{GT/LE}.{S/D}, FST{GT/LE}.{S/D} Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson --- .../loongarch/insn_trans/trans_fmemory.c.inc | 153 ++ target/loongarch/

[PATCH v3 08/43] target/loongarch: Add fixed point atomic instruction translation

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This includes: - LL.{W/D}, SC.{W/D} - AM{SWAP/ADD/AND/OR/XOR/MAX/MIN}[_DB].{W/D} - AM{MAX/MIN}[_DB].{WU/DU} Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson --- .../loongarch/insn_trans/trans_atomic.c.inc | 113 ++ .../loong

[PATCH v3 43/43] target/loongarch: 'make check-tcg' support

2022-04-29 Thread Xiaojuan Yang
From: Song Gao Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson Acked-by: Alex Bennée Reviewed-by: Philippe Mathieu-Daudé --- tests/tcg/configure.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/tcg/configure.sh b/tests/tcg/configure.sh index 6

[PATCH v3 33/43] hw/intc: Add LoongArch ls7a msi interrupt controller support(PCH-MSI)

2022-04-29 Thread Xiaojuan Yang
This patch realize PCH-MSI interrupt controller. Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- hw/intc/Kconfig | 5 ++ hw/intc/loongarch_pch_msi.c | 73 + hw/intc/meson.build | 1

[PATCH v3 19/43] target/loongarch: Add CSRs definition

2022-04-29 Thread Xiaojuan Yang
Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- target/loongarch/cpu-csr.h | 208 + target/loongarch/cpu.c | 36 +++ target/loongarch/cpu.h | 64 3 files changed, 308 insertions(+) create mod

[PATCH v3 06/43] target/loongarch: Add fixed point bit instruction translation

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This includes: - EXT.W.{B/H} - CL{O/Z}.{W/D}, CT{O/Z}.{W/D} - BYTEPICK.{W/D} - REVB.{2H/4H/2W/D} - REVH.{2W/D} - BITREV.{4B/8B}, BITREV.{W/D} - BSTRINS.{W/D}, BSTRPICK.{W/D} - MASKEQZ, MASKNEZ Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson -

[PATCH v3 41/43] target/loongarch: Add gdb support.

2022-04-29 Thread Xiaojuan Yang
Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- MAINTAINERS | 1 + configs/targets/loongarch64-softmmu.mak | 1 + gdb-xml/loongarch-base64.xml| 44 ++ gdb-xml/loongarch-fpu64.xml | 57 +

[PATCH v3 23/43] target/loongarch: Add LoongArch interrupt and exception handle

2022-04-29 Thread Xiaojuan Yang
Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- target/loongarch/cpu.c | 229 +++ target/loongarch/cpu.h | 2 + target/loongarch/internals.h | 2 + 3 files changed, 233 insertions(+) diff --git a/target/loo

[PATCH v3 32/43] hw/intc: Add LoongArch ls7a interrupt controller support(PCH-PIC)

2022-04-29 Thread Xiaojuan Yang
This patch realize the PCH-PIC interrupt controller. Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao --- MAINTAINERS | 1 + hw/intc/Kconfig | 4 + hw/intc/loongarch_pch_pic.c | 431 hw/intc/meson.build

[PATCH v3 29/43] target/loongarch: Add timer related instructions support.

2022-04-29 Thread Xiaojuan Yang
This includes: -RDTIME{L/H}.W -RDTIME.D Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- target/loongarch/disas.c | 3 ++ target/loongarch/helper.h | 2 ++ target/loongarch/insn_trans/trans_extra.c.inc | 33 +

[PATCH v3 39/43] hw/loongarch: Add LoongArch load elf function.

2022-04-29 Thread Xiaojuan Yang
Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao --- hw/loongarch/loongson3.c| 66 +++-- include/hw/loongarch/virt.h | 9 + target/loongarch/cpu.h | 2 ++ 3 files changed, 75 insertions(+), 2 deletions(-) diff --git a/hw/loongarch/loongson3.c b

[PATCH v3 25/43] target/loongarch: Add LoongArch CSR instruction

2022-04-29 Thread Xiaojuan Yang
This includes: - CSRRD - CSRWR - CSRXCHG Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao --- target/loongarch/csr_helper.c | 92 ++ target/loongarch/disas.c | 101 +++ target/loongarch/helper.h | 9 + .../insn_trans/trans_

[PATCH v3 28/43] target/loongarch: Add other core instructions support

2022-04-29 Thread Xiaojuan Yang
This includes: -CACOP -LDDIR -LDPTE -ERTN -DBCL -IDLE Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- target/loongarch/disas.c | 17 target/loongarch/helper.h | 5 + .../insn_trans/trans_privileged.c.inc

[PATCH v3 07/43] target/loongarch: Add fixed point load/store instruction translation

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This includes: - LD.{B[U]/H[U]/W[U]/D}, ST.{B/H/W/D} - LDX.{B[U]/H[U]/W[U]/D}, STX.{B/H/W/D} - LDPTR.{W/D}, STPTR.{W/D} - PRELD - LD{GT/LE}.{B/H/W/D}, ST{GT/LE}.{B/H/W/D} - DBAR, IBAR Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson --- targe

[PATCH v3 20/43] target/loongarch: Add basic vmstate description of CPU.

2022-04-29 Thread Xiaojuan Yang
Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- target/loongarch/cpu.c | 1 + target/loongarch/internals.h | 2 + target/loongarch/machine.c | 85 target/loongarch/meson.build | 6 +++ 4 files changed, 94 in

[PATCH v3 36/43] Enable common virtio pci support for LoongArch

2022-04-29 Thread Xiaojuan Yang
Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- softmmu/qdev-monitor.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/softmmu/qdev-monitor.c b/softmmu/qdev-monitor.c index 12fe60c467..bb5897fc76 100644 --- a/softmmu/qdev-monitor.c +

[PATCH v3 27/43] target/loongarch: Add TLB instruction support

2022-04-29 Thread Xiaojuan Yang
This includes: - TLBSRCH - TLBRD - TLBWR - TLBFILL - TLBCLR - TLBFLUSH - INVTLB Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao Reviewed-by: Richard Henderson --- target/loongarch/disas.c | 18 + target/loongarch/helper.h | 13 + .../insn_trans/t

[PATCH v3 38/43] hw/loongarch: Add LoongArch ls7a rtc device support

2022-04-29 Thread Xiaojuan Yang
This patch add ls7a rtc device support. Signed-off-by: Xiaojuan Yang Signed-off-by: Song Gao --- MAINTAINERS| 1 + hw/loongarch/Kconfig | 1 + hw/loongarch/loongson3.c | 4 + hw/rtc/Kconfig | 3 + hw/rtc/ls7a_rtc.c | 322 +

Re: [PATCH 05/18] tests/qtest: Specify audiodev= and -audiodev

2022-04-29 Thread Martin Kletzander
On Mon, Apr 25, 2022 at 02:42:53PM +0100, Daniel P. Berrangé wrote: On Mon, Apr 25, 2022 at 10:21:48AM +0200, Martin Kletzander wrote: This will enable removing deprecated default audiodev support. I did not figure out how to make the audiodev represented as an interface node, so this is a work

[PATCH v5 0/6] 9pfs: macOS host fixes

2022-04-29 Thread Christian Schoenebeck
A bunch of fixes for recently (in QEMU 7.0) added 9p support on macOS hosts. Note: there are still issues to address with case-insensitive file systems on macOS hosts. I sent a separate RFC on that icase issue: https://lore.kernel.org/qemu-devel/1757498.AyhHxzoH2B@silver/ v4 -> v5: * Check ret

[PATCH v3 05/43] target/loongarch: Add fixed point shift instruction translation

2022-04-29 Thread Xiaojuan Yang
From: Song Gao This includes: - SLL.W, SRL.W, SRA.W, ROTR.W - SLLI.W, SRLI.W, SRAI.W, ROTRI.W - SLL.D, SRL.D, SRA.D, ROTR.D - SLLI.D, SRLI.D, SRAI.D, ROTRI.D Signed-off-by: Song Gao Signed-off-by: Xiaojuan Yang Reviewed-by: Richard Henderson --- target/loongarch/insn_trans/trans_shift.c.inc

[PATCH v5 2/6] 9pfs: fix qemu_mknodat(S_IFSOCK) on macOS

2022-04-29 Thread Christian Schoenebeck
mknod() on macOS does not support creating sockets, so divert to call sequence socket(), bind() and fchmodat() respectively if S_IFSOCK was passed with mode argument. Link: https://lore.kernel.org/qemu-devel/17933734.zYzKuhC07K@silver/ Signed-off-by: Christian Schoenebeck --- hw/9pfs/9p-util-dar

[PATCH v5 4/6] 9pfs: fix wrong errno being sent to Linux client on macOS host

2022-04-29 Thread Christian Schoenebeck
Linux and macOS only share some errno definitions with equal macro name and value. In fact most mappings for errno are completely different on the two systems. This patch converts some important errno values from macOS host to corresponding Linux errno values before eventually sending such error c

[PATCH v5 5/6] 9pfs: fix removing non-existent POSIX ACL xattr on macOS host

2022-04-29 Thread Christian Schoenebeck
When mapped POSIX ACL is used, we are ignoring errors when trying to remove a POSIX ACL xattr that does not exist. On Linux hosts we would get ENODATA in such cases, on macOS hosts however we get ENOATTR instead. As we can be sure that ENOATTR is defined as being identical on Linux hosts (at least

[PATCH v5 1/6] 9pfs: fix qemu_mknodat(S_IFREG) on macOS

2022-04-29 Thread Christian Schoenebeck
mknod() on macOS does not support creating regular files, so divert to openat_file() if S_IFREG is passed with mode argument. Furthermore, 'man 2 mknodat' on Linux says: "Zero file type is equivalent to type S_IFREG". Link: https://lore.kernel.org/qemu-devel/17933734.zYzKuhC07K@silver/ Signed-off

[PATCH v5 3/6] 9pfs: fix wrong encoding of rdev field in Rgetattr on macOS

2022-04-29 Thread Christian Schoenebeck
The 'rdev' field in 9p reponse 'Rgetattr' is of type dev_t, which is actually a system dependant type and therefore both the size and encoding of dev_t differ between macOS and Linux. So far we have sent 'rdev' to guest in host's dev_t format as-is, which caused devices to appear with wrong device

[PATCH v5 6/6] 9pfs: fix qemu_mknodat() to always return -1 on error on macOS host

2022-04-29 Thread Christian Schoenebeck
qemu_mknodat() is expected to behave according to its POSIX API, and therefore should always return exactly -1 on any error, and errno should be set for the actual error code. Signed-off-by: Christian Schoenebeck Reviewed-by: Greg Kurz --- hw/9pfs/9p-util-darwin.c | 3 ++- 1 file changed, 2 ins

Re: [PATCH 1/4] target/riscv: Fix csr number based privilege checking

2022-04-29 Thread Alistair Francis
On Fri, Apr 29, 2022 at 1:36 PM Anup Patel wrote: > > When hypervisor and VS CSRs are accessed from VS-mode or VU-mode, > the riscv_csrrw_check() function should generate virtual instruction > trap instead illegal instruction trap. > > Fixes: 533c91e8f22c ("target/riscv: Use RISCVException enum fo

Re: [PATCH v5 4/6] 9pfs: fix wrong errno being sent to Linux client on macOS host

2022-04-29 Thread Bin Meng
On Fri, Apr 29, 2022 at 7:16 PM Christian Schoenebeck wrote: > > Linux and macOS only share some errno definitions with equal macro > name and value. In fact most mappings for errno are completely > different on the two systems. > > This patch converts some important errno values from macOS host t

Re: [PATCH 07/18] Introduce machine's default-audiodev property

2022-04-29 Thread Martin Kletzander
On Mon, Apr 25, 2022 at 03:06:14PM +0100, Daniel P. Berrangé wrote: On Mon, Apr 25, 2022 at 10:21:50AM +0200, Martin Kletzander wrote: Many machine types have default audio devices with no way to set the underlying audiodev. Instead of adding an option for each and every one of them this new pr

Re: [PATCH 00/18] RFC: Remove deprecated audio features

2022-04-29 Thread Martin Kletzander
On Mon, Apr 25, 2022 at 06:05:56PM +0100, Mark Cave-Ayland wrote: On 25/04/2022 09:21, Martin Kletzander wrote: I wanted to deal with https://bugzilla.redhat.com/2043498 and I got a suggesstion that removing deprecated features could actually make it easier to propagate the error. In the end (

Re: [PATCH v5 4/6] 9pfs: fix wrong errno being sent to Linux client on macOS host

2022-04-29 Thread Greg Kurz
On Fri, 29 Apr 2022 19:28:39 +0800 Bin Meng wrote: > On Fri, Apr 29, 2022 at 7:16 PM Christian Schoenebeck > wrote: > > > > Linux and macOS only share some errno definitions with equal macro > > name and value. In fact most mappings for errno are completely > > different on the two systems. > >

Re: [PATCH v5 4/6] 9pfs: fix wrong errno being sent to Linux client on macOS host

2022-04-29 Thread Christian Schoenebeck via
On Freitag, 29. April 2022 13:28:39 CEST Bin Meng wrote: > On Fri, Apr 29, 2022 at 7:16 PM Christian Schoenebeck > > wrote: > > Linux and macOS only share some errno definitions with equal macro > > name and value. In fact most mappings for errno are completely > > different on the two systems. >

Re: [PATCH v3 3/3] nbd/server: Allow MULTI_CONN for shared writable exports

2022-04-29 Thread Kevin Wolf
Am 27.04.2022 um 23:39 hat Eric Blake geschrieben: > On Wed, Apr 27, 2022 at 05:52:09PM +0200, Kevin Wolf wrote: > > Am 14.03.2022 um 21:38 hat Eric Blake geschrieben: > > > According to the NBD spec, a server that advertises > > > NBD_FLAG_CAN_MULTI_CONN promises that multiple client connections w

Re: [PATCH v5 2/6] 9pfs: fix qemu_mknodat(S_IFSOCK) on macOS

2022-04-29 Thread Greg Kurz
On Fri, 29 Apr 2022 12:25:11 +0200 Christian Schoenebeck wrote: > mknod() on macOS does not support creating sockets, so divert to > call sequence socket(), bind() and fchmodat() respectively if S_IFSOCK > was passed with mode argument. > > Link: https://lore.kernel.org/qemu-devel/17933734.zYzKu

Re: [PATCH v5 4/6] 9pfs: fix wrong errno being sent to Linux client on macOS host

2022-04-29 Thread Greg Kurz
On Fri, 29 Apr 2022 14:46:26 +0200 Christian Schoenebeck wrote: > On Freitag, 29. April 2022 13:28:39 CEST Bin Meng wrote: > > On Fri, Apr 29, 2022 at 7:16 PM Christian Schoenebeck > > > > wrote: > > > Linux and macOS only share some errno definitions with equal macro > > > name and value. In f

Re: [RFC PATCH v1 0/8] qapi: add generator for Golang interface

2022-04-29 Thread Andrea Bolognani
On Thu, Apr 28, 2022 at 03:50:55PM +0200, Markus Armbruster wrote: > Andrea Bolognani writes: > > One concern that I have is about naming struct members: things like > > SpiceInfo.MouseMode and most others are translated from the QAPI > > schema exactly the way you'd expect them, but for example >

Re: [PATCH v5 4/6] 9pfs: fix wrong errno being sent to Linux client on macOS host

2022-04-29 Thread Bin Meng
On Fri, Apr 29, 2022 at 9:08 PM Greg Kurz wrote: > > On Fri, 29 Apr 2022 14:46:26 +0200 > Christian Schoenebeck wrote: > > > On Freitag, 29. April 2022 13:28:39 CEST Bin Meng wrote: > > > On Fri, Apr 29, 2022 at 7:16 PM Christian Schoenebeck > > > > > > wrote: > > > > Linux and macOS only share

mount host directory as disk in VM

2022-04-29 Thread Nguetchouang Ngongang Kevin
Hello everyone, I'm trying to mount a host directory as a disk in my VM at startup but I'm facing a problem. QEMU-SYSTEM- is returning "could not read directory". I'm using this https://qemu.readthedocs.io/en/latest/system/images.html#virtual-fat-disk-images as "-hdc fat:/mnt/data/outpu

Re: [PATCH v5 4/6] 9pfs: fix wrong errno being sent to Linux client on macOS host

2022-04-29 Thread Greg Kurz
On Fri, 29 Apr 2022 21:19:51 +0800 Bin Meng wrote: > On Fri, Apr 29, 2022 at 9:08 PM Greg Kurz wrote: > > > > On Fri, 29 Apr 2022 14:46:26 +0200 > > Christian Schoenebeck wrote: > > > > > On Freitag, 29. April 2022 13:28:39 CEST Bin Meng wrote: > > > > On Fri, Apr 29, 2022 at 7:16 PM Christian

Re: [RFC PATCH 1/6] pc: remove -soundhw pcspk

2022-04-29 Thread Paolo Bonzini
On 4/27/22 13:32, Paolo Bonzini wrote: The pcspk device is the only user of isa_register_soundhw, and the only -soundhw option which does not create a new device (it hacks into the PCSpkState by hand). Remove it, since it was deprecated. Signed-off-by: Paolo Bonzini --- hw/audio/pcspk.c

Re: [qemu.qmp PATCH 03/12] update project description

2022-04-29 Thread Beraldo Leal
On Fri, Apr 22, 2022 at 02:49:31PM -0400, John Snow wrote: > Signed-off-by: John Snow > Reviewed-by: Beraldo Leal > --- > setup.cfg | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/setup.cfg b/setup.cfg > index f06f944..c21f2ce 100644 > --- a/setup.cfg > +++ b/setup.cfg

Re: [PATCH v5 4/6] 9pfs: fix wrong errno being sent to Linux client on macOS host

2022-04-29 Thread Christian Schoenebeck
On Freitag, 29. April 2022 15:29:15 CEST Greg Kurz wrote: > On Fri, 29 Apr 2022 21:19:51 +0800 > > Bin Meng wrote: > > On Fri, Apr 29, 2022 at 9:08 PM Greg Kurz wrote: > > > On Fri, 29 Apr 2022 14:46:26 +0200 > > > > > > Christian Schoenebeck wrote: > > > > On Freitag, 29. April 2022 13:28:39

Re: [PATCH v5 2/6] 9pfs: fix qemu_mknodat(S_IFSOCK) on macOS

2022-04-29 Thread Christian Schoenebeck
On Freitag, 29. April 2022 14:56:50 CEST Greg Kurz wrote: > On Fri, 29 Apr 2022 12:25:11 +0200 > > Christian Schoenebeck wrote: > > mknod() on macOS does not support creating sockets, so divert to > > call sequence socket(), bind() and fchmodat() respectively if S_IFSOCK > > was passed with mode

Re: [qemu.qmp PATCH 04/12] update project URLs

2022-04-29 Thread Beraldo Leal
On Fri, Apr 22, 2022 at 02:49:32PM -0400, John Snow wrote: > Point to this library's URLs instead of the entire project's. > > Signed-off-by: John Snow > --- > setup.cfg | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/setup.cfg b/setup.cfg > index c21f2ce..0a1c215 1

  1   2   3   >