[Bug 1907909] Re: assertion failure in am53c974

2021-06-16 Thread Thomas Huth
As Alexander already wrote, this triggered the same bug as #1919036 which got fixed by commit 0ebb5fd80589835153a0c2baa1b8cc7a04e67a93. Since this is not reproducible anymore, I'm closing this bug now. If you still can reproduce it somehow, please open a new ticket in the new gitlab issue tracker.

Re: [PATCH v2 1/2] qapi/machine.json: add DEVICE_UNPLUG_ERROR QAPI event

2021-06-16 Thread Markus Armbruster
Daniel Henrique Barboza writes: > On 6/11/21 9:12 AM, Markus Armbruster wrote: >> Daniel Henrique Barboza writes: >> >>> At this moment we only provide one event to report a hotunplug error, >>> MEM_UNPLUG_ERROR. As of Linux kernel 5.12 and QEMU 6.0.0, the pseries >>> machine is now able to rep

Re: [PATCH 3/7] Fixed SVM hang when do failover before PVM crash

2021-06-16 Thread lizhij...@fujitsu.com
On 17/06/2021 10:47, Lei Rao wrote: > From: "Rao, Lei" > > This patch fixed as follows: > Thread 1 (Thread 0x7f34ee738d80 (LWP 11212)): > #0 __pthread_clockjoin_ex (threadid=139847152957184, > thread_return=0x7f30b1febf30, clockid=, abstime= out>, block=) at pthread_join_common.c:145

Re: [PATCH 0/4] modules: add support for target-specific modules.

2021-06-16 Thread Gerd Hoffmann
Hi, > >> However, please correct me if I'm wrong, I understand that an accelerator > >> as a > >> module will add an overhead that some user won't be willing to pay. So, > >> give > >> them the option to have built-in accelerators seems a good idea. > > > > Modules add some overhead, yes, a

Re: [PATCH v9] qapi: introduce 'query-kvm-cpuid' action

2021-06-16 Thread Markus Armbruster
Valeriy Vdovin writes: > Introducing new qapi method 'query-kvm-cpuid'. This method can be used to It's actually a QMP command. There are no "qapi methods". > get virtualized cpu model info generated by QEMU during VM initialization in > the form of cpuid representation. > > Diving into more d

Re: [PATCH v2 23/23] hw/i386/Kconfig: Add missing Kconfig dependency (runtime error)

2021-06-16 Thread Gerd Hoffmann
On Wed, Jun 16, 2021 at 10:43:28PM +0200, Philippe Mathieu-Daudé wrote: > When building the 'microvm' machine stand-alone we get: > > $ qemu-system-x86_64 -M microvm > ** > ERROR:qom/object.c:714:object_new_with_type: assertion failed: (type != > NULL) > Bail out! ERROR:qom/object.c:714:o

Re: [PATCH v2 22/23] hw/acpi/Kconfig: Add missing Kconfig dependencies (build error)

2021-06-16 Thread Gerd Hoffmann
On Wed, Jun 16, 2021 at 10:43:27PM +0200, Philippe Mathieu-Daudé wrote: > The 'microvm' machine misses various dependencies: > > /usr/bin/ld: libqemu-i386-softmmu.fa.p/hw_i386_acpi-microvm.c.o: in > function `acpi_setup_microvm': > hw/i386/acpi-microvm.c:247: undefined reference to `acpi_buil

Re: [PATCH v3 2/4] s390x/css: Split out the IRB sense data

2021-06-16 Thread Thomas Huth
On 16/06/2021 03.47, Eric Farman wrote: Let's move this logic into its own routine, so it can be reused later. Signed-off-by: Eric Farman --- hw/s390x/css.c | 19 --- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/hw/s390x/css.c b/hw/s390x/css.c index 8be21efb

Re: [PATCH v4 2/6] memory: make global_dirty_log a bitmask

2021-06-16 Thread Hyman Huang
在 2021/6/16 23:22, Peter Xu 写道: On Wed, Jun 16, 2021 at 09:12:28AM +0800, huang...@chinatelecom.cn wrote: diff --git a/include/exec/memory.h b/include/exec/memory.h index b114f54..e31eef2 100644 --- a/include/exec/memory.h +++ b/include/exec/memory.h @@ -55,7 +55,11 @@ static inline void fuzz

RE: [PATCH V8 1/6] qapi/net: Add IPFlowSpec and QMP command for COLO passthrough

2021-06-16 Thread Zhang, Chen
> -Original Message- > From: Markus Armbruster > Sent: Wednesday, June 16, 2021 9:26 PM > To: Zhang, Chen > Cc: Lukas Straub ; Daniel P.Berrangé > ; Li Zhijian ; Jason Wang > ; qemu-dev ; Dr. David > Alan Gilbert ; Gerd Hoffmann ; > Zhang Chen ; Eric Blake > Subject: Re: [PATCH V8 1/6]

[PATCH 6/7] Changed the last-mode to none of first start COLO

2021-06-16 Thread Lei Rao
From: "Rao, Lei" When we first stated the COLO, the last-mode is as follows: { "execute": "query-colo-status" } {"return": {"last-mode": "primary", "mode": "primary", "reason": "none"}} The last-mode is unreasonable. After the patch, will be changed to the following: { "execute": "query-colo-sta

[PATCH 3/7] Fixed SVM hang when do failover before PVM crash

2021-06-16 Thread Lei Rao
From: "Rao, Lei" This patch fixed as follows: Thread 1 (Thread 0x7f34ee738d80 (LWP 11212)): #0 __pthread_clockjoin_ex (threadid=139847152957184, thread_return=0x7f30b1febf30, clockid=, abstime=, block=) at pthread_join_common.c:145 #1 0x563401998e36 in qemu_thread_join (thread=0

[PATCH 4/7] colo: fixed 'Segmentation fault' when the simplex mode PVM poweroff

2021-06-16 Thread Lei Rao
From: "Rao, Lei" When a PVM completed its SVM failover steps and begins to run in the simplex mode, QEMU would encounter a 'Segmentation fault' if the guest poweroff with the following calltrace: Program received signal SIGSEGV, Segmentation fault. This is because primary_vm_do_failover() would

[PATCH 7/7] Optimized the function of fill_connection_key.

2021-06-16 Thread Lei Rao
From: "Rao, Lei" Remove some unnecessary code to improve the performance of the filter-rewriter module. Signed-off-by: Lei Rao --- net/colo-compare.c| 2 +- net/colo.c| 31 --- net/colo.h| 6 +++--- net/filter-rewriter.c | 10 +-

[PATCH 2/7] Fixed qemu crash when guest power off in COLO mode

2021-06-16 Thread Lei Rao
From: "Rao, Lei" This patch fixes the following: qemu-system-x86_64: invalid runstate transition: 'shutdown' -> 'running' Aborted (core dumped) The gdb bt as following: 0 __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50 1 0x7faa3d613859 in __GI_abort () at abort.c:79 2

[PATCH 5/7] Removed the qemu_fclose() in colo_process_incoming_thread

2021-06-16 Thread Lei Rao
From: "Rao, Lei" After the live migration, the related fd will be cleanup in migration_incoming_state_destroy(). So, the qemu_close() in colo_process_incoming_thread is not necessary. Signed-off-by: Lei Rao --- migration/colo.c | 5 - 1 file changed, 5 deletions(-) diff --git a/migration/

[PATCH 0/7] Fixed some bugs and optimized some codes for COLO

2021-06-16 Thread Lei Rao
From: Rao, Lei The series of patches include: Fixed some bugs of qemu crash and segment fault. Optimized the function of fill_connection_key. Remove some unnecessary code to improve COLO. Rao, Lei (7): Some minor optimizations for COLO Fixed qemu crash when guest powe

[PATCH 1/7] Some minor optimizations for COLO

2021-06-16 Thread Lei Rao
From: "Rao, Lei" Signed-off-by: Lei Rao --- migration/colo.c | 2 +- net/colo-compare.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/migration/colo.c b/migration/colo.c index 79fa1f6..616dc00 100644 --- a/migration/colo.c +++ b/migration/colo.c @@ -152,7 +152,7 @@ st

Re: [PATCH qemu v21] spapr: Implement Open Firmware client interface

2021-06-16 Thread Alexey Kardashevskiy
On 16/06/2021 20:26, BALATON Zoltan wrote: On Wed, 16 Jun 2021, Alexey Kardashevskiy wrote: On 6/16/21 07:09, BALATON Zoltan wrote: On Tue, 15 Jun 2021, Alexey Kardashevskiy wrote: The PAPR platform describes an OS environment that's presented by a combination of a hypervisor and firmware.

[PATCH v2 0/1] input: Add lang1 and lang2 to QKeyCode

2021-06-16 Thread Akihiko Odaki
This patch adds two QKeyCodes. The corresponding path for ui/keycodemapdb is titled as "Add QEMU QKeyCode 'lang1' and 'lang2'". This patch should be applied *before* applying the patch for ui/keycodemapdb, or it causes build failures. v1 -> v2: - Documented the new QKeyCodes as available "since

[PATCH v2 1/1] input: Add lang1 and lang2 to QKeyCode

2021-06-16 Thread Akihiko Odaki
lang1 and lang2 represents the keys with the same names in the keyboard/keypad usage page (0x07) included in the "HID Usage Tables for Universal Serial Bus (USB)" version 1.22. Although the keys are described as "Hangul/English toggle key" and "Hanja conversion key" in the specification, the meanin

[PATCH v2] ui/gtk: Allow user to select monitor number to display qemu in full screen through new gtk display option

2021-06-16 Thread sweeaun
-display gtk,monitor= Signed-off-by: sweeaun --- qapi/ui.json| 4 +++- qemu-options.hx | 2 +- ui/gtk.c| 15 +++ 3 files changed, 19 insertions(+), 2 deletions(-) diff --git a/qapi/ui.json b/qapi/ui.json index 1052ca9c38..1616f3ffbd 100644 --- a/qapi/ui.json +++ b/qap

Re: [PATCH qemu v21] spapr: Implement Open Firmware client interface

2021-06-16 Thread Alexey Kardashevskiy
On 16/06/2021 20:34, BALATON Zoltan wrote: On Wed, 16 Jun 2021, Alexey Kardashevskiy wrote: On 6/15/21 20:29, BALATON Zoltan wrote: On Tue, 15 Jun 2021, Alexey Kardashevskiy wrote: The PAPR platform describes an OS environment that's presented by a combination of a hypervisor and firmware.

[PATCH v2 1/1] accel/tcg: Probe the proper permissions for atomic ops

2021-06-16 Thread Richard Henderson
We had a single ATOMIC_MMU_LOOKUP macro that probed for read+write on all atomic ops. This is incorrect for plain atomic load and atomic store. For user-only, we rely on the host page permissions. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/390 Reviewed-by: Alex Bennée Signed-off-by

[PATCH v2 0/1] accel/tcg: Fix #390 and other atomicity musings

2021-06-16 Thread Richard Henderson
This fixes some bugs reported against 128-bit atomic operations. Just a note that the ppc insns that uses this, LQ and STQ, do not require atomic operations if the address is unaligned, or if the address does not resolve to ram. So for some things we are working harder than required. I've also h

Re: [PATCH 14/21] linux-user/openrisc: Implement setup_sigtramp

2021-06-16 Thread Stafford Horne
On Tue, Jun 15, 2021 at 06:12:02PM -0700, Richard Henderson wrote: > Create and record the rt signal trampoline. > > Cc: Stafford Horne > Signed-off-by: Richard Henderson Reviewed-by: Stafford Horne > --- > linux-user/openrisc/target_signal.h | 2 ++ > linux-user/openrisc/signal.c|

Re: [PATCH v4 15/15] hw/i2c: Introduce i2c_start_recv() and i2c_start_send()

2021-06-16 Thread Richard Henderson
On 6/16/21 2:42 PM, Philippe Mathieu-Daudé wrote: To ease reviewing code using the I2C bus API, introduce the i2c_start_recv() and i2c_start_send() helpers which don't take the confusing 'is_recv' boolean argument. Use these new helpers in the SMBus / AUX bus models. Suggested-by: Richard Hende

Re: [PATCH v4 14/15] hw/i2c: Extract i2c_do_start_transfer() from i2c_start_transfer()

2021-06-16 Thread Richard Henderson
On 6/16/21 2:42 PM, Philippe Mathieu-Daudé wrote: +static int i2c_do_start_transfer(I2CBus *bus, uint8_t address, + enum i2c_event event) { I2CSlaveClass *sc; I2CNode *node; bool bus_scanned = false; +assert(event == I2C_START_RECV || eve

Re: [PATCH v3 06/13] hw/i2c/ppc4xx_i2c: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-16 Thread Corey Minyard
On Thu, Jun 17, 2021 at 01:09:05AM +0200, BALATON Zoltan wrote: > On Wed, 16 Jun 2021, Philippe Mathieu-Daudé wrote: > > On 6/16/21 10:01 PM, BALATON Zoltan wrote: > > > On Wed, 16 Jun 2021, Philippe Mathieu-Daudé wrote: > > > > On 6/16/21 9:16 PM, Corey Minyard wrote: > > > > > On Wed, Jun 16, 202

Re: [PATCH 07/21] linux-user/hexagon: Implement setup_sigtramp

2021-06-16 Thread Richard Henderson
On 6/16/21 2:37 PM, Taylor Simpson wrote: Yes, I'm confused. Why is signal frame unwinding in libgcc? Because it's tied to the compiler, and it was a decent solution back in 1997. I see llvm calls it libunwind, and only has special signal frame support for aarch64. I wonder if ever other ta

Re: [PATCH v4 03/15] hw/display/sm501: Simplify sm501_i2c_write() logic

2021-06-16 Thread BALATON Zoltan
On Wed, 16 Jun 2021, Philippe Mathieu-Daudé wrote: Reviewed-by: Richard Henderson Acked-by: Corey Minyard Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: BALATON Zoltan --- hw/display/sm501.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/hw/display/sm501.c b/h

Re: [PATCH v3 06/13] hw/i2c/ppc4xx_i2c: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-16 Thread BALATON Zoltan
On Wed, 16 Jun 2021, Philippe Mathieu-Daudé wrote: On 6/16/21 10:01 PM, BALATON Zoltan wrote: On Wed, 16 Jun 2021, Philippe Mathieu-Daudé wrote: On 6/16/21 9:16 PM, Corey Minyard wrote: On Wed, Jun 16, 2021 at 06:14:11PM +0200, Philippe Mathieu-Daudé wrote: Instead of using the confuse i2c_se

[PATCH v4 14/15] hw/i2c: Extract i2c_do_start_transfer() from i2c_start_transfer()

2021-06-16 Thread Philippe Mathieu-Daudé
To allow further simplications, extract i2c_do_start_transfer() from i2c_start_transfer(). This is mostly the same function, but the former is static and takes an enum argument. Signed-off-by: Philippe Mathieu-Daudé --- hw/i2c/core.c | 14 -- 1 file changed, 12 insertions(+), 2 delet

[PATCH v4 13/15] hw/i2c: Make i2c_start_transfer() direction argument a boolean

2021-06-16 Thread Philippe Mathieu-Daudé
From: BALATON Zoltan Make the argument representing the direction of the transfer a boolean type. Rename the boolean argument as 'is_recv' to match i2c_recv_send(). Document the function prototype. Signed-off-by: BALATON Zoltan Message-Id: <20200621145235.9e241745...@zero.eik.bme.hu> [PMD: Spli

[PATCH v4 12/15] hw/i2c: Rename i2c_set_slave_address() -> i2c_slave_set_address()

2021-06-16 Thread Philippe Mathieu-Daudé
Other functions from I2C slave API are named "i2c_slave_XXX()". Follow that pattern with set_address(). Add docstring along. No logical change. Patch created mechanically using: $ sed -i s/i2c_set_slave_address/i2c_slave_set_address/ \ $(git grep -l i2c_set_slave_address) Reviewed-by: Rich

[PATCH v4 08/15] hw/misc/auxbus: Explode READ_I2C / WRITE_I2C_MOT cases

2021-06-16 Thread Philippe Mathieu-Daudé
To allow further simplifications in the following commits, start copying WRITE_I2C code to the READ_I2C, and READ_I2C_MOT to WRITE_I2C_MOT. No logical change. Reviewed-by: Richard Henderson Acked-by: Corey Minyard Signed-off-by: Philippe Mathieu-Daudé --- hw/misc/auxbus.c | 53

[PATCH v4 04/15] hw/display/sm501: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-16 Thread Philippe Mathieu-Daudé
Instead of using the confuse i2c_send_recv(), rewrite to directly call i2c_recv() & i2c_send(), resulting in code easier to review. Reviewed-by: Richard Henderson Acked-by: Corey Minyard Signed-off-by: Philippe Mathieu-Daudé --- hw/display/sm501.c | 9 + 1 file changed, 5 insertions(+)

[PATCH v4 15/15] hw/i2c: Introduce i2c_start_recv() and i2c_start_send()

2021-06-16 Thread Philippe Mathieu-Daudé
To ease reviewing code using the I2C bus API, introduce the i2c_start_recv() and i2c_start_send() helpers which don't take the confusing 'is_recv' boolean argument. Use these new helpers in the SMBus / AUX bus models. Suggested-by: Richard Henderson Signed-off-by: Philippe Mathieu-Daudé --- in

[PATCH v4 06/15] hw/i2c/ppc4xx_i2c: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-16 Thread Philippe Mathieu-Daudé
Instead of using the confuse i2c_send_recv(), rewrite to directly call i2c_recv() & i2c_send(), resulting in code easier to review. Reviewed-by: Richard Henderson Acked-by: Corey Minyard Signed-off-by: Philippe Mathieu-Daudé --- hw/i2c/ppc4xx_i2c.c | 13 - 1 file changed, 8 inserti

[PATCH v4 02/15] hw/input/lm832x: Define TYPE_LM8323 in public header

2021-06-16 Thread Philippe Mathieu-Daudé
Define TYPE_LM8323 in the public "hw/input/lm832x.h" header and use it in hw/arm/nseries.c. Reviewed-by: Richard Henderson Acked-by: Corey Minyard Signed-off-by: Philippe Mathieu-Daudé --- include/hw/input/lm832x.h | 2 ++ hw/arm/nseries.c | 2 +- hw/input/lm832x.c | 1 - 3 fi

[PATCH v4 11/15] hw/i2c: Remove confusing i2c_send_recv()

2021-06-16 Thread Philippe Mathieu-Daudé
We replaced all the i2c_send_recv() calls by the clearer i2c_recv() and i2c_send(), so we can remove this confusing API. Reviewed-by: Richard Henderson Acked-by: Corey Minyard Signed-off-by: Philippe Mathieu-Daudé --- include/hw/i2c/i2c.h | 1 - hw/i2c/core.c| 50 +++--

[PATCH v4 09/15] hw/misc/auxbus: Replace 'is_write' boolean by its value

2021-06-16 Thread Philippe Mathieu-Daudé
Remove the 'is_write' boolean by directly using its value in place. Reviewed-by: Richard Henderson Acked-by: Corey Minyard Signed-off-by: Philippe Mathieu-Daudé --- hw/misc/auxbus.c | 28 +++- 1 file changed, 11 insertions(+), 17 deletions(-) diff --git a/hw/misc/auxbu

[PATCH v4 05/15] hw/i2c/ppc4xx_i2c: Add reference to datasheet

2021-06-16 Thread Philippe Mathieu-Daudé
It took me a while to find this model datasheet, since it is an OCR scan. Add a reference to save other developers time. Reviewed-by: Richard Henderson Acked-by: Corey Minyard Signed-off-by: Philippe Mathieu-Daudé --- hw/i2c/ppc4xx_i2c.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw

[PATCH v4 01/15] hw/input/lm832x: Move lm832x_key_event() declaration to "lm832x.h"

2021-06-16 Thread Philippe Mathieu-Daudé
lm832x_key_event() is specific go LM832x devices, not to the I2C bus API. Move it out of "i2c.h" to a new header. Reviewed-by: Richard Henderson Acked-by: Corey Minyard Signed-off-by: Philippe Mathieu-Daudé --- include/hw/i2c/i2c.h | 3 --- include/hw/input/lm832x.h | 26

[PATCH v4 10/15] hw/misc/auxbus: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-16 Thread Philippe Mathieu-Daudé
Instead of using the confuse i2c_send_recv(), replace i2c_send_recv(send = true) by i2c_send() and i2c_send_recv(send = false) by i2c_recv(). During the replacement we also change a while() statement by for(). The resulting code is easier to review. Reviewed-by: Richard Henderson Acked-by: Co

[PATCH v4 07/15] hw/misc/auxbus: Fix MOT/classic I2C mode

2021-06-16 Thread Philippe Mathieu-Daudé
Since its introduction in commit 6fc7f77fd2 i2c_start_transfer() uses incorrectly the direction of the transfer (the last argument is called 'is_recv'). Fix by inverting the argument, we now have is_recv = !is_write. Fixes: 6fc7f77fd2 ("introduce aux-bus") Reported-by: BALATON Zoltan Reviewed-by:

[PATCH v4 03/15] hw/display/sm501: Simplify sm501_i2c_write() logic

2021-06-16 Thread Philippe Mathieu-Daudé
Reviewed-by: Richard Henderson Acked-by: Corey Minyard Signed-off-by: Philippe Mathieu-Daudé --- hw/display/sm501.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/hw/display/sm501.c b/hw/display/sm501.c index 8789722ef27..f276276f7f1 100644 --- a/hw/display/sm501.c +++

[PATCH v4 00/15] hw/i2c: Remove confusing i2c_send_recv() API

2021-06-16 Thread Philippe Mathieu-Daudé
This is a respin of Zoltan's patch: https://www.mail-archive.com/qemu-devel@nongnu.org/msg714711.html Patches 1-13 reviewed (could be queued) Missing review: 14-15 (but optionals) Since v3: - addressed minor review comments from Richard/Corey - added R-b/A-b tags - implemented Richard suggestion

RE: [PATCH 07/21] linux-user/hexagon: Implement setup_sigtramp

2021-06-16 Thread Taylor Simpson
> -Original Message- > From: Richard Henderson > Sent: Wednesday, June 16, 2021 9:51 AM > To: Taylor Simpson ; qemu-devel@nongnu.org > Cc: laur...@vivier.eu; alex.ben...@linaro.org > Subject: Re: [PATCH 07/21] linux-user/hexagon: Implement setup_sigtramp > > On 6/16/21 8:05 AM, Richard

Re: [PATCH 08/21] linux-user/hppa: Document non-use of setup_sigtramp

2021-06-16 Thread Alex Bennée
Richard Henderson writes: > We cannot use a raw sigtramp page for hppa, > but must wait for full vdso support. > > Signed-off-by: Richard Henderson Reviewed-by: Alex Bennée > --- > linux-user/hppa/target_signal.h | 14 ++ > 1 file changed, 14 insertions(+) > > diff --git a/linu

Re: [PATCH v4 6/8] hw/intc: GICv3 redistributor ITS processing

2021-06-16 Thread shashi . mallela
Hi Eric, Have accepted all comments with responses inline (below):- On Sun, 2021-06-13 at 18:26 +0200, Eric Auger wrote: > Hi Shashi, > > On 6/2/21 8:00 PM, Shashi Mallela wrote: > > Implemented lpi processing at redistributor to get lpi config info > s/Implemented/Implement here are elsewhere.

[PATCH v2 19/23] hw/i386: Move pc_madt_cpu_entry() to acpi-pc.c

2021-06-16 Thread Philippe Mathieu-Daudé
pc_madt_cpu_entry() is specific to QEMU 'PC' machines, move it to acpi-pc.c. Signed-off-by: Philippe Mathieu-Daudé --- hw/i386/acpi-common.c | 40 hw/i386/acpi-pc.c | 39 +++ 2 files changed, 39 insertions(+), 40 de

Re: [PATCH v4 3/8] hw/intc: GICv3 ITS command queue framework

2021-06-16 Thread shashi . mallela
Hi Eric, Please find my responses inline (below):- On Sun, 2021-06-13 at 16:13 +0200, Eric Auger wrote: > Hi Sashi, > > On 6/2/21 8:00 PM, Shashi Mallela wrote: > > Added functionality to trigger ITS command queue processing on > > write to CWRITE register and process each command queue entry to

[PATCH v2 14/23] target/i386/sev: Move qmp_query_sev_launch_measure() to sev.c

2021-06-16 Thread Philippe Mathieu-Daudé
Move qmp_query_sev_launch_measure() from monitor.c to sev.c and make sev_get_launch_measurement() static. We don't need the stub anymore, remove it. Signed-off-by: Philippe Mathieu-Daudé --- target/i386/sev_i386.h| 1 - target/i386/monitor.c | 17 - target/i386/s

Re: [PATCH v4 4/8] hw/intc: GICv3 ITS Command processing

2021-06-16 Thread shashi . mallela
Hi Eric, Please find my responses inline (below):- On Sun, 2021-06-13 at 17:55 +0200, Eric Auger wrote: > Hi Shashi, > > On 6/2/21 8:00 PM, Shashi Mallela wrote: > > Added ITS command queue handling for MAPTI,MAPI commands,handled > > ITS > > translation which triggers an LPI via INT command as

Re: [PATCH v4 2/8] hw/intc: GICv3 ITS register definitions added

2021-06-16 Thread shashi . mallela
Hi Eric, Please find my responses inline (below):- On Sat, 2021-06-12 at 08:08 +0200, Eric Auger wrote: > > On 6/2/21 8:00 PM, Shashi Mallela wrote: > > Defined descriptors for ITS device table,collection table and ITS > > command queue entities.Implemented register read/write functions, > > ext

[PATCH v2 22/23] hw/acpi/Kconfig: Add missing Kconfig dependencies (build error)

2021-06-16 Thread Philippe Mathieu-Daudé
The 'microvm' machine misses various dependencies: /usr/bin/ld: libqemu-i386-softmmu.fa.p/hw_i386_acpi-microvm.c.o: in function `acpi_setup_microvm': hw/i386/acpi-microvm.c:247: undefined reference to `acpi_build_tables_init' /usr/bin/ld: libqemu-i386-softmmu.fa.p/hw_i386_acpi-microvm.c.o:

[PATCH v2 13/23] target/i386/sev: Move qmp_query_sev_capabilities() to sev.c

2021-06-16 Thread Philippe Mathieu-Daudé
Move qmp_query_sev_capabilities() from monitor.c to sev.c and make sev_get_capabilities() static. We don't need the stub anymore, remove it. Signed-off-by: Philippe Mathieu-Daudé --- target/i386/sev_i386.h| 1 - target/i386/monitor.c | 5 - target/i386/sev-sysemu-stub.c | 4 +

[PATCH v2 20/23] hw/acpi: Do not restrict ACPI core routines to x86 architecture

2021-06-16 Thread Philippe Mathieu-Daudé
ACPI core routines (in core.c) are not really x86-specific. Signed-off-by: Philippe Mathieu-Daudé --- hw/acpi/meson.build | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/acpi/meson.build b/hw/acpi/meson.build index dd69577212a..c23c67f4283 100644 --- a/hw/acpi/meson.buil

[PATCH v2] accel/tcg: Probe the proper permissions for atomic ops

2021-06-16 Thread Richard Henderson
We had a single ATOMIC_MMU_LOOKUP macro that probed for read+write on all atomic ops. This is incorrect for plain atomic load and atomic store. For user-only, we rely on the host page permissions. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/390 Reviewed-by: Alex Bennée Signed-off-by

[PATCH v2 12/23] target/i386/sev: Move qmp_sev_inject_launch_secret() to sev.c

2021-06-16 Thread Philippe Mathieu-Daudé
Move qmp_sev_inject_launch_secret() from monitor.c to sev.c and make sev_inject_launch_secret() static. We don't need the stub anymore, remove it. Signed-off-by: Philippe Mathieu-Daudé --- target/i386/monitor.c | 31 --- target/i386/sev-sysemu-stub.c | 6 +++-

[PATCH v2 16/23] monitor: Restrict 'info sev' to x86 targets

2021-06-16 Thread Philippe Mathieu-Daudé
Signed-off-by: Philippe Mathieu-Daudé --- include/monitor/hmp-target.h | 1 + include/monitor/hmp.h | 1 - target/i386/sev-sysemu-stub.c | 2 +- target/i386/sev.c | 2 +- 4 files changed, 3 insertions(+), 3 deletions(-) diff --git a/include/monitor/hmp-target.h b/include/mon

[PATCH v2 23/23] hw/i386/Kconfig: Add missing Kconfig dependency (runtime error)

2021-06-16 Thread Philippe Mathieu-Daudé
When building the 'microvm' machine stand-alone we get: $ qemu-system-x86_64 -M microvm ** ERROR:qom/object.c:714:object_new_with_type: assertion failed: (type != NULL) Bail out! ERROR:qom/object.c:714:object_new_with_type: assertion failed: (type != NULL) Aborted (core dumped) Looking

[PATCH v2 11/23] target/i386/sev: Move qmp_query_sev_attestation_report() to sev.c

2021-06-16 Thread Philippe Mathieu-Daudé
Move qmp_query_sev_attestation_report() from monitor.c to sev.c and make sev_get_attestation_report() static. We don't need the stub anymore, remove it. Signed-off-by: Philippe Mathieu-Daudé --- target/i386/sev_i386.h| 2 -- target/i386/monitor.c | 6 -- target/i386/sev-sys

[PATCH v2 21/23] hw/i386: Introduce X86_FW_OVMF Kconfig symbol

2021-06-16 Thread Philippe Mathieu-Daudé
Introduce the X86_FW_OVMF Kconfig symbol for OVMF-specific code. Move the OVMF-specific code from pc_sysfw.c to pc_sysfw_ovmf.c, adding a pair of stubs. Update MAINTAINERS to reach OVMF maintainers when these new files are modified. This fixes when building the microvm machine standalone: /usr/

[PATCH v2 15/23] target/i386/sev: Move qmp_query_sev() & hmp_info_sev() to sev.c

2021-06-16 Thread Philippe Mathieu-Daudé
Move qmp_query_sev() & hmp_info_sev()() from monitor.c to sev.c and make sev_get_info() static. We don't need the stub anymore, remove it. Add a stub for hmp_info_sev(). Signed-off-by: Philippe Mathieu-Daudé --- Note: what is left in sev_i386.h eventually belong to "sysemu/sev.h" meaning we

[PATCH v2 17/23] hw/i386/acpi-common: Remove unused includes

2021-06-16 Thread Philippe Mathieu-Daudé
Signed-off-by: Philippe Mathieu-Daudé --- hw/i386/acpi-common.c | 5 - 1 file changed, 5 deletions(-) diff --git a/hw/i386/acpi-common.c b/hw/i386/acpi-common.c index 1f5947fcf96..77afebd9e1f 100644 --- a/hw/i386/acpi-common.c +++ b/hw/i386/acpi-common.c @@ -21,15 +21,10 @@ */ #include

[PATCH v2 10/23] target/i386/sev: Restrict SEV to system emulation

2021-06-16 Thread Philippe Mathieu-Daudé
SEV is irrelevant on user emulation, so restrict it to sysemu. Some stubs are still required because used in cpu.c by x86_register_cpudef_types(), so move the sysemu specific stubs to sev-sysemu-stub.c instead. This will allow us to simplify monitor.c (which is not available in user emulation) in t

[PATCH v2 18/23] hw/i386: Rename acpi-build.c -> acpi-pc.c

2021-06-16 Thread Philippe Mathieu-Daudé
The acpi-build.c file contains routines common to the QEMU "PC" machines (Q35+ICH & i440FX+PIIX), rename it as acpi-pc.c. Signed-off-by: Philippe Mathieu-Daudé --- hw/i386/{acpi-build.c => acpi-pc.c} | 0 hw/i386/meson.build | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-)

[PATCH v2 04/23] target/i386/monitor: Return QMP error when SEV is disabled in build

2021-06-16 Thread Philippe Mathieu-Daudé
If the management layer tries to inject a secret, it gets an empty response in case the binary built without SEV: { "execute": "sev-inject-launch-secret", "arguments": { "packet-header": "mypkt", "secret": "mypass", "gpa": 4294959104 } } { "return": { } } Make it clearer

[PATCH v2 09/23] target/i386/sev: sev_get_attestation_report use g_autofree

2021-06-16 Thread Philippe Mathieu-Daudé
From: "Dr. David Alan Gilbert" Removes a whole bunch of g_free's and a goto. Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Connor Kuehl Reviewed-by: Brijesh Singh Message-Id: <20210603113017.34922-1-dgilb...@redhat.com> Signed-off-by: Philippe Mathieu-Daudé --- target/i386/sev.c | 11 +

[PATCH v2 03/23] qapi/misc-target: Group SEV QAPI definitions

2021-06-16 Thread Philippe Mathieu-Daudé
There is already a section with various SEV commands / types, so move the SEV guest attestation together. Signed-off-by: Philippe Mathieu-Daudé --- qapi/misc-target.json | 81 +-- 1 file changed, 40 insertions(+), 41 deletions(-) diff --git a/qapi/misc-ta

[PATCH 0/6] virtiofsd: Support for remote blocking posix locks

2021-06-16 Thread Ioannis Angelakopoulos
Hi, Here is the implementation for the remote blocking posix locks in virtiofsd. This patch series also addresses the issues that were not fixed in: [Virtio-fs] [PATCH v2 0/5] [RFC] virtiofsd, vhost-user-fs: Add support for notification queue https://patchwork.kernel.org/project/qemu-devel/cover/

[PATCH v2 05/23] target/i386/cpu: Add missing 'qapi/error.h' header

2021-06-16 Thread Philippe Mathieu-Daudé
Commit 00b81053244 ("target-i386: Remove assert_no_error usage") forgot to add the "qapi/error.h" for &error_abort, add it now. Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Connor Kuehl Signed-off-by: Philippe Mathieu-Daudé --- target/i386/cpu.c | 1 + 1 file changed, 1 insertion(+) diff

[PATCH v2 08/23] target/i386/sev: Mark unreachable code with g_assert_not_reached()

2021-06-16 Thread Philippe Mathieu-Daudé
The unique sev_encrypt_flash() invocation (in pc_system_flash_map) is protected by the "if (sev_enabled())" check, so is not reacheable. Replace the abort() call in sev_es_save_reset_vector() by g_assert_not_reached() which meaning is clearer. Reviewed-by: Connor Kuehl Signed-off-by: Philippe Mat

[PATCH v2 02/23] qapi/misc-target: Wrap long 'SEV Attestation Report' long lines

2021-06-16 Thread Philippe Mathieu-Daudé
Wrap long lines before 70 characters for legibility. Suggested-by: Markus Armbruster Signed-off-by: Philippe Mathieu-Daudé --- Note: it would be nice if checkpatch enforce 70 char for json (or at least QAPI json), that would save future developer modifying QAPI definitions reformatin

[PATCH 5/6] virtiofsd: Thread state cleanup when blocking posix locks are used

2021-06-16 Thread Ioannis Angelakopoulos
Stop virtiofsd thread from sending any notifications/messages through the virtqueue while the guest hard-reboots. If a guest attempts to hard reboot while a virtiofsd thread blocks waiting for a lock held by another guest's virtiofsd process, then QEMU will block the guest from rebooting until the

[PATCH v2 01/23] MAINTAINERS: Add Connor Kuehl as reviewer for AMD SEV

2021-06-16 Thread Philippe Mathieu-Daudé
From: Connor Kuehl It may not be appropriate for me to take over as a maintainer at this time, but I would consider myself familiar with AMD SEV and what this code is meant to be doing as part of a VMM for launching SEV-protected guests. To that end, I would be happy to volunteer as a reviewer f

[PATCH v2 07/23] target/i386/sev: Remove sev_get_me_mask()

2021-06-16 Thread Philippe Mathieu-Daudé
Unused dead code makes review harder, so remove it. Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Connor Kuehl Signed-off-by: Philippe Mathieu-Daudé --- target/i386/sev_i386.h | 1 - target/i386/sev-stub.c | 5 - target/i386/sev.c | 9 - 3 files changed, 15 deletions(-) di

Re: [PATCH 10/11] target/i386/monitor: Move SEV specific commands to sev.c

2021-06-16 Thread Philippe Mathieu-Daudé
On 6/10/21 5:19 PM, Connor Kuehl wrote: > On 6/10/21 1:45 AM, Philippe Mathieu-Daudé wrote: >> Having the HMP/QMP commands defined in monitor.c makes the stubs >> rather complicated when SEV is not built in. To simplify, move the >> SEV functions to sev.c, and remove a layer of stubs. >> >> Also ma

[PATCH v2 00/23] target/i386/sev: Housekeeping (OVMF + SEV-disabled binaries)

2021-06-16 Thread Philippe Mathieu-Daudé
Hi, While testing James & Dov patch: https://www.mail-archive.com/qemu-devel@nongnu.org/msg810571.html I wasted some time trying to figure out how OVMF was supposed to behave until realizing the binary I was using was built without SEV support... Then wrote this series to help other developers to

[PATCH 1/6] virtiofsd: Release file locks using F_UNLCK

2021-06-16 Thread Ioannis Angelakopoulos
From: Vivek Goyal We are emulating posix locks for guest using open file description locks in virtiofsd. When any of the fd is closed in guest, we find associated OFD lock fd (if there is one) and close it to release all the locks. Assumption here is that there is no other thread using lo_inode_

[PATCH v2 06/23] target/i386/sev_i386.h: Remove unused headers

2021-06-16 Thread Philippe Mathieu-Daudé
Declarations don't require these headers, remove them. Reviewed-by: Connor Kuehl Signed-off-by: Philippe Mathieu-Daudé --- target/i386/sev_i386.h | 4 target/i386/sev-stub.c | 1 + 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/target/i386/sev_i386.h b/target/i386/sev_i386.h

[PATCH 3/6] virtiofsd: Specify size of notification buffer using config space

2021-06-16 Thread Ioannis Angelakopoulos
From: Vivek Goyal Daemon specifies size of notification buffer needed and that should be done using config space. Only ->notify_buf_size value of config space comes from daemon. Rest of it is filled by qemu device emulation code. Signed-off-by: Vivek Goyal Signed-off-by: Ioannis Angelakopoulos

[PATCH 6/6] virtiofsd: Custom threadpool for remote blocking posix locks requests

2021-06-16 Thread Ioannis Angelakopoulos
Add a new custom threadpool using posix threads that specifically service locking requests. In the case of a fcntl(SETLKW) request, if the guest is waiting for a lock or locks and issues a hard-reboot through SYSRQ then virtiofsd unblocks the blocked threads by sending a signal to them and waking

[PATCH 2/6] virtiofsd: Create a notification queue

2021-06-16 Thread Ioannis Angelakopoulos
From: Vivek Goyal Add a notification queue which will be used to send async notifications for file lock availability. Signed-off-by: Vivek Goyal Signed-off-by: Ioannis Angelakopoulos --- hw/virtio/vhost-user-fs.c | 30 ++-- include/hw/virtio/vhost-user-fs.h | 2

[PATCH 4/6] virtiofsd: Implement blocking posix locks

2021-06-16 Thread Ioannis Angelakopoulos
From: Vivek Goyal As of now we don't support fcntl(F_SETLKW) and if we see one, we return -EOPNOTSUPP. Change that by accepting these requests and returning a reply immediately asking caller to wait. Once lock is available, send a notification to the waiter indicating lock is available. Signed-

Re: [PATCH v3 06/13] hw/i2c/ppc4xx_i2c: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-16 Thread Philippe Mathieu-Daudé
On 6/16/21 10:01 PM, BALATON Zoltan wrote: > On Wed, 16 Jun 2021, Philippe Mathieu-Daudé wrote: >> On 6/16/21 9:16 PM, Corey Minyard wrote: >>> On Wed, Jun 16, 2021 at 06:14:11PM +0200, Philippe Mathieu-Daudé wrote: Instead of using the confuse i2c_send_recv(), rewrite to directly call i2

Re: [PATCH v3 10/13] hw/misc/auxbus: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-16 Thread BALATON Zoltan
On Wed, 16 Jun 2021, Philippe Mathieu-Daudé wrote: On 6/16/21 8:46 PM, Richard Henderson wrote: On 6/16/21 9:14 AM, Philippe Mathieu-Daudé wrote: @@ -161,12 +157,11 @@ AUXReply aux_request(AUXBus *bus, AUXCommand cmd, uint32_t address,   }     ret = AUX_I2C_ACK; -    while (

Re: [PATCH v3 06/13] hw/i2c/ppc4xx_i2c: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-16 Thread BALATON Zoltan
On Wed, 16 Jun 2021, Philippe Mathieu-Daudé wrote: On 6/16/21 9:16 PM, Corey Minyard wrote: On Wed, Jun 16, 2021 at 06:14:11PM +0200, Philippe Mathieu-Daudé wrote: Instead of using the confuse i2c_send_recv(), rewrite to directly call i2c_recv() & i2c_send(), resulting in code easire to review.

[PATCH v2] target/arm: Implement MTE3

2021-06-16 Thread Peter Collingbourne
MTE3 introduces an asymmetric tag checking mode, in which loads are checked synchronously and stores are checked asynchronously. Add support for it. Signed-off-by: Peter Collingbourne Reviewed-by: Richard Henderson --- v2: - remove unused argument target/arm/cpu64.c | 2 +- target/arm/mt

Re: [PATCH v3 00/13] hw/i2c: Remove confusing i2c_send_recv() API

2021-06-16 Thread Corey Minyard
On Wed, Jun 16, 2021 at 06:14:05PM +0200, Philippe Mathieu-Daudé wrote: > This is a respin of Zoltan's patch: > https://www.mail-archive.com/qemu-devel@nongnu.org/msg714711.html > > Since v2, tried to address Corey's review comments resulting > in a i2c_send_recv() removal and code easier to revie

Re: [PATCH v3 10/13] hw/misc/auxbus: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-16 Thread Philippe Mathieu-Daudé
On 6/16/21 8:46 PM, Richard Henderson wrote: > On 6/16/21 9:14 AM, Philippe Mathieu-Daudé wrote: >> @@ -161,12 +157,11 @@ AUXReply aux_request(AUXBus *bus, AUXCommand >> cmd, uint32_t address, >>   } >>     ret = AUX_I2C_ACK; >> -    while (len > 0) { >> -    if (i2c_sen

Re: [PATCH v3 06/13] hw/i2c/ppc4xx_i2c: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-16 Thread Philippe Mathieu-Daudé
On 6/16/21 9:16 PM, Corey Minyard wrote: > On Wed, Jun 16, 2021 at 06:14:11PM +0200, Philippe Mathieu-Daudé wrote: >> Instead of using the confuse i2c_send_recv(), rewrite to directly >> call i2c_recv() & i2c_send(), resulting in code easire to review. >> >> Signed-off-by: Philippe Mathieu-Daudé >

Re: [PATCH v3 01/13] hw/input/lm832x: Move lm832x_key_event() declaration to "lm832x.h"

2021-06-16 Thread Philippe Mathieu-Daudé
On 6/16/21 8:38 PM, Richard Henderson wrote: > On 6/16/21 9:14 AM, Philippe Mathieu-Daudé wrote: >> lm832x_key_event() is specific go LM832x devices, not to the >> I2C bus API. Move it out of "i2c.h" to a new header. >> >> Signed-off-by: Philippe Mathieu-Daudé >> --- >>   include/hw/i2c/i2c.h 

Re: [PATCH v4 5/7] crypto/tlssession: Introduce qcrypto_tls_creds_check_endpoint() helper

2021-06-16 Thread Philippe Mathieu-Daudé
On 6/16/21 9:12 PM, Richard Henderson wrote: > On 6/16/21 9:22 AM, Philippe Mathieu-Daudé wrote: >> Introduce the qcrypto_tls_creds_check_endpoint() helper >> to avoid accessing QCryptoTLSCreds internal 'endpoint' field >> directly. > > I don't understand this one.  Comment ... > >> +bool qcrypto

Re: [PATCH] docs/system/arm: Document which architecture extensions we emulate

2021-06-16 Thread Peter Maydell
On Tue, 15 Jun 2021 at 17:29, Alex Bennée wrote: > > Peter Maydell writes: > > > These days the Arm architecture has a wide range of fine-grained > > optional extra architectural features. We implement quite a lot > > of these but by no means all of them. Document what we do implement, > > so tha

Re: [PULL 00/25] target-arm queue

2021-06-16 Thread Peter Maydell
: > > https://git.linaro.org/people/pmaydell/qemu-arm.git > tags/pull-target-arm-20210616 > > for you to fetch changes up to 703235a303d6862a7e3f5c6aa9eff7471cb138b2: > > include/qemu/int128.h: Add function to create Int128 from int64_t > (2021-06-16 14:33:52 +0100) >

Re: [PATCH v3 06/13] hw/i2c/ppc4xx_i2c: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-16 Thread Corey Minyard
On Wed, Jun 16, 2021 at 06:14:11PM +0200, Philippe Mathieu-Daudé wrote: > Instead of using the confuse i2c_send_recv(), rewrite to directly > call i2c_recv() & i2c_send(), resulting in code easire to review. > > Signed-off-by: Philippe Mathieu-Daudé > --- > hw/i2c/ppc4xx_i2c.c | 13 -

Re: [PATCH v3 04/13] hw/display/sm501: Replace i2c_send_recv() by i2c_recv() & i2c_send()

2021-06-16 Thread Corey Minyard
On Wed, Jun 16, 2021 at 06:14:09PM +0200, Philippe Mathieu-Daudé wrote: > Instead of using the confuse i2c_send_recv(), rewrite to directly > call i2c_recv() & i2c_send(), resulting in code easire to review. ^easier > > Signed-off-by: Philippe M

  1   2   3   4   >