Re: [PULL 04/20] crypto: Redundant type conversion for AES_KEY pointer

2020-05-04 Thread Daniel P . Berrangé
Hi Chen, This patch triggered a build failure in QEMU about discarding the "const" qualifier. IOW, the type conversion is not redundant after all - it is required in order to explicitly discard "const". I believe we can probably fix this by changing qcrypto_cipher_aes_ecb_(en|de)crypt() methods

Re: [PATCH v2 6/6] iotests: Add test 291 to for qemu-img bitmap coverage

2020-05-04 Thread Max Reitz
On 21.04.20 23:20, Eric Blake wrote: > Add a new test covering the 'qemu-img bitmap' subcommand, as well as > 'qemu-img convert --bitmaps', both added in recent patches. > > Signed-off-by: Eric Blake > --- > tests/qemu-iotests/291 | 103 + > tests/qemu-iot

Re: [PATCH] Fix iotest 153

2020-05-04 Thread Max Reitz
On 04.05.20 11:41, Maxim Levitsky wrote: > On Mon, 2020-05-04 at 11:22 +0200, Max Reitz wrote: >> On 03.05.20 18:49, Maxim Levitsky wrote: >>> Commit f62514b3def5fb2acbef64d0e053c0c31fa45aff made qemu-img reject -o "" >>> but this test uses it >>> >>> Since this test only tries to do a dry-run run

Re: [PATCH] Fix iotest 153

2020-05-04 Thread Maxim Levitsky
On Mon, 2020-05-04 at 15:08 +0200, Max Reitz wrote: > On 04.05.20 11:41, Maxim Levitsky wrote: > > On Mon, 2020-05-04 at 11:22 +0200, Max Reitz wrote: > > > On 03.05.20 18:49, Maxim Levitsky wrote: > > > > Commit f62514b3def5fb2acbef64d0e053c0c31fa45aff made qemu-img reject -o > > > > "" but this

Re: [PATCH] Makefile: Let the 'help' target list the helper targets

2020-05-04 Thread Stefan Hajnoczi
On Thu, Apr 23, 2020 at 12:43:45PM +0200, Philippe Mathieu-Daudé wrote: > List the name of the helper targets when calling 'make help', > along with the tool targets: > > $ make help > [...] > > Helper targets: > fsdev/virtfs-proxy-helper - Build virtfs-proxy-helper > scsi/qemu

Re: [PATCH v3 08/15] acpi: serial: don't use _STA method

2020-05-04 Thread Gerd Hoffmann
> > -static Aml *build_com_device_aml(uint8_t uid) > > +static void build_com_device_aml(Aml *scope, uint8_t uid) > > { > > Aml *dev; > > Aml *crs; > > -Aml *method; > > -Aml *if_ctx; > > -Aml *else_ctx; > > -Aml *zero = aml_int(0); > > -Aml *is_present = aml_local

[PATCH v2] Fix iotest 153

2020-05-04 Thread Maxim Levitsky
Commit f62514b3def5fb2acbef64d0e053c0c31fa45aff made qemu-img reject -o "" but this test uses it. Since this test only tries to do a dry-run run of qemu-img amend, replace the -o "" with dummy -o "size=$size". Fixes: f62514b3def5fb2acbef64d0e053c0c31fa45aff Signed-off-by: Maxim Levitsky --- te

Re: [PATCH v3 10/15] acpi: parallel: don't use _STA method

2020-05-04 Thread Gerd Hoffmann
Hi, > Also, it may be worth a ISA_PARALLEL_IOBASE 0x378 definition cleanup like > you did with the RTC. Next patch in series deals with that. take care, Gerd

[PATCH v5] audio/jack: add JACK client audiodev

2020-05-04 Thread Geoffrey McRae
This commit adds a new audiodev backend to allow QEMU to use JACK as both an audio sink and source. Signed-off-by: Geoffrey McRae --- audio/Makefile.objs| 5 + audio/audio.c | 1 + audio/audio_template.h | 2 + audio/jackaudio.c | 707 +

Re: [PATCH] iotests/041: Fix NBD socket path

2020-05-04 Thread Stefan Hajnoczi
On Fri, Apr 24, 2020 at 03:46:26PM +0200, Max Reitz wrote: > We should put all UNIX socket files into the sock_dir, not test_dir. > > Reported-by: Elena Ufimtseva > Signed-off-by: Max Reitz > --- > tests/qemu-iotests/041 | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Cool, thanks for

Re: [PATCH v3 10/15] acpi: parallel: don't use _STA method

2020-05-04 Thread Gerd Hoffmann
On Thu, Apr 30, 2020 at 06:25:24PM +0200, Igor Mammedov wrote: > On Wed, 29 Apr 2020 15:59:58 +0200 > Gerd Hoffmann wrote: > > > The _STA method dates back to the days where we had a static DSDT. The > > device is listed in the DSDT table unconditionally and the _STA method > > checks a bit in t

Re: [PATCH v2 3/6] qemu-img: Add bitmap sub-command

2020-05-04 Thread Eric Blake
On 5/4/20 5:01 AM, Max Reitz wrote: +.. option:: bitmap {--add [-g GRANULARITY] [--disabled] | --remove | --clear | --enable | --disable | --merge SOURCE_BITMAP [-b SOURCE_FILE [-F SOURCE_FMT]]} [--object OBJECTDEF] [--image-opts] [-f FMT] FILENAME BITMAP So I can do multiple operations in one

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

2020-05-04 Thread Peter Maydell
e-tracking branch 'remotes/marcel/tags/rdma-pull-request' into > staging (2020-05-03 14:12:56 +0100) > > are available in the Git repository at: > > https://git.linaro.org/people/pmaydell/qemu-arm.git > tags/pull-target-arm-20200504 > > for you to fetch change

Re: [Bug 1875762] [NEW] Poor disk performance on sparse VMDKs

2020-05-04 Thread Stefan Hajnoczi
On Tue, Apr 28, 2020 at 10:45:07PM -, Alan Murtagh wrote: > QEMU appears to suffer from remarkably poor disk performance when > writing to sparse-extent VMDKs. Of course it's to be expected that > allocation takes time and sparse VMDKs peform worse than allocated > VMDKs, but surely not on the

Re: [PATCH] chardev: enable distinct input for -chardev file

2020-05-04 Thread Stefan Hajnoczi
On Fri, May 01, 2020 at 01:25:59PM -0400, Alexander Bulekov wrote: > char-file already supports distinct paths for input/output but it was > only possible to specify a distinct input through QMP. With this change, > we can also specify a distinct input with the -chardev file argument: > qemu -c

Re: [PATCH v2 4/6] qcow2: Expose bitmaps' size during measure

2020-05-04 Thread Eric Blake
On 5/4/20 6:36 AM, Max Reitz wrote: On 21.04.20 23:20, Eric Blake wrote: It's useful to know how much space can be occupied by qcow2 persistent bitmaps, even though such metadata is unrelated to the guest-visible data. Report this value as an additional field. Update iotest 190 to cover it and

Re: [PATCH v3 15/15] acpi: simplify build_isa_devices_aml()

2020-05-04 Thread Gerd Hoffmann
On Thu, Apr 30, 2020 at 08:48:31AM +0200, Philippe Mathieu-Daudé wrote: > Cc'ing IPMI maintainer. > > On 4/29/20 4:00 PM, Gerd Hoffmann wrote: > > x86 machines can have a single ISA bus only. > > I disagree with the comment. > Machines can have multiple ISA bus. Note *x86* machines. Given x86 h

Re: [PATCH] qcow2: Avoid integer wraparound in qcow2_co_truncate()

2020-05-04 Thread Alberto Garcia
On Fri 01 May 2020 08:48:31 PM CEST, Eric Blake wrote: > Since your reproducer triggers assertion failure, I suggest doing this > instead: >>> +++ b/block/qcow2.c >>> @@ -4234,6 +4234,9 @@ static int coroutine_fn >>> qcow2_co_truncate(BlockDriverState *bs, int64_t offset, >>>   if ((flags & B

Re: [PATCH] virtiofsd: Use clone() and not unshare(), support non-root

2020-05-04 Thread Stefan Hajnoczi
On Fri, May 01, 2020 at 02:25:48PM -0400, Colin Walters wrote: > I'd like to make use of virtiofs as part of our tooling in > https://github.com/coreos/coreos-assembler > Most of the code runs as non-root today; qemu also runs as non-root. > We use 9p right now. > > virtiofsd's builtin sandboxing

Re: [Query] VM CPU scheduling

2020-05-04 Thread Stefan Hajnoczi
On Sun, May 03, 2020 at 05:04:10PM +0530, Ramesh B wrote: > Hi All, > > I started recently using QEMU for OS virtualization. > Want to know/understand about scheduling. > > Environment: > Host OS: Ubuntu 18.4 + KVM enable > QEMU: 4.2 > Workstation/Desktop: x86_64 > > Would like to understand, >

Re: [Query] VM CPU scheduling

2020-05-04 Thread Lukas Straub
On Sun, 3 May 2020 17:04:10 +0530 Ramesh B wrote: > Hi All, > > I started recently using QEMU for OS virtualization. > Want to know/understand about scheduling. > > Environment: > Host OS: Ubuntu 18.4 + KVM enable > QEMU: 4.2 > Workstation/Desktop: x86_64 > > Would like to understand, > > 1.

Re: [PATCH v2] Fix iotest 153

2020-05-04 Thread Maxim Levitsky
On Mon, 2020-05-04 at 15:55 +0200, Max Reitz wrote: > On 04.05.20 15:19, Maxim Levitsky wrote: > > Commit f62514b3def5fb2acbef64d0e053c0c31fa45aff made qemu-img reject -o "" > > but this test uses it. > > Since this test only tries to do a dry-run run of qemu-img amend, > > replace the -o "" with

Re: [PATCH v2] Fix iotest 153

2020-05-04 Thread Max Reitz
On 04.05.20 15:19, Maxim Levitsky wrote: > Commit f62514b3def5fb2acbef64d0e053c0c31fa45aff made qemu-img reject -o "" > but this test uses it. > Since this test only tries to do a dry-run run of qemu-img amend, > replace the -o "" with dummy -o "size=$size". > > Fixes: f62514b3def5fb2acbef64d0e05

Re: [PATCH v6 4/8] acpi: Refactor the source of host bridge and build tables for pxb

2020-05-04 Thread Michael S. Tsirkin
On Wed, Apr 08, 2020 at 08:58:12PM +0800, Yubo Miao wrote: > From: miaoyubo > > The resources of pxbs and obtained by crs_build and the resources > used by pxbs would be moved form the resources defined for host-bridge. > > The resources for pxb are composed of the bar space of the > pci-bridge/

Re: [PATCH] chardev: enable distinct input for -chardev file

2020-05-04 Thread Alexander Bulekov
On 200501 1325, Alexander Bulekov wrote: ... > diff --git a/qemu-options.hx b/qemu-options.hx > index 292d4e7c0c..bbb091872f 100644 > --- a/qemu-options.hx > +++ b/qemu-options.hx > @@ -2938,7 +2938,7 @@ DEF("chardev", HAS_ARG, QEMU_OPTION_chardev, > "-chardev > vc,id=id[[,width=width][,heigh

Re: [PATCH RESEND v3 1/2] Makefile: libfdt: build only the strict necessary

2020-05-04 Thread David Gibson
On Wed, Apr 29, 2020 at 01:47:47PM +0200, Claudio Fontana wrote: > just a gentle ping on this one, now that 5.0 is out, is proceeding > with this ok? Yes, go for it. -- David Gibson| I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank y

Re: [PATCH v6 2/8] fw_cfg: Write the extra roots into the fw_cfg

2020-05-04 Thread Michael S. Tsirkin
On Wed, Apr 08, 2020 at 08:58:10PM +0800, Yubo Miao wrote: > From: miaoyubo > > Write the extra roots into the fw_cfg therefore the uefi could > get the extra roots. Only if the uefi know there are extra roots, > the config space of devices behind the root could be obtained. > > Signed-off-by: m

Re: [PATCH v6 5/8] acpi: Align the size to 128k

2020-05-04 Thread Michael S. Tsirkin
On Wed, Apr 08, 2020 at 08:58:13PM +0800, Yubo Miao wrote: > From: miaoyubo > > If table size is changed between virt_acpi_build and > virt_acpi_build_update, the table size would not be updated to > UEFI, therefore, just align the size to 128kb, which is enough > and same with x86. It would warn

Re: [PATCH] virtiofsd: Use clone() and not unshare(), support non-root

2020-05-04 Thread Marc-André Lureau
Hi On Fri, May 1, 2020 at 8:29 PM Colin Walters wrote: > > I'd like to make use of virtiofs as part of our tooling in > https://github.com/coreos/coreos-assembler > Most of the code runs as non-root today; qemu also runs as non-root. > We use 9p right now. > > virtiofsd's builtin sandboxing effec

Re: [PATCH RESEND v3 0/4] virtio-pci: enable blk and scsi multi-queue by default

2020-05-04 Thread Michael S. Tsirkin
On Fri, Mar 20, 2020 at 10:30:37AM +, Stefan Hajnoczi wrote: > v3: > * Add new performance results that demonstrate the scalability > * Mention that this is PCI-specific [Cornelia] > v2: > * Let the virtio-DEVICE-pci device select num-queues because the optimal >multi-queue configuration

[PATCH v2 01/10] net: cadence_gem: Fix debug statements

2020-05-04 Thread Sai Pavan Boddu
Enabling debug breaks the build, Fix them and make debug statements always compilable. Fix few statements to use sized integer casting. Signed-off-by: Sai Pavan Boddu --- hw/net/cadence_gem.c | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/hw/ne

[PATCH v2 03/10] net: cadence_gem: Fix irq update w.r.t queue

2020-05-04 Thread Sai Pavan Boddu
Set irq's specific to a queue, present implementation is setting q1 irq based on q0 status. Signed-off-by: Sai Pavan Boddu --- hw/net/cadence_gem.c | 25 +++-- 1 file changed, 3 insertions(+), 22 deletions(-) diff --git a/hw/net/cadence_gem.c b/hw/net/cadence_gem.c index 6cb

[PATCH v2 02/10] net: cadence_gem: Fix the queue address update during wrap around

2020-05-04 Thread Sai Pavan Boddu
During wrap around and reset, queues are pointing to initial base address of queue 0, irrespective of what queue we are dealing with. Fix it by assigning proper base address every time. Signed-off-by: Sai Pavan Boddu --- hw/net/cadence_gem.c | 29 + 1 file changed, 25

[PATCH v2 08/10] net: cadence_gem: Update the reset value for interrupt mask register

2020-05-04 Thread Sai Pavan Boddu
Mask all interrupt on reset. Signed-off-by: Sai Pavan Boddu --- hw/net/cadence_gem.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/net/cadence_gem.c b/hw/net/cadence_gem.c index 9eb72a2..ac3a553 100644 --- a/hw/net/cadence_gem.c +++ b/hw/net/cadence_gem.c @@ -1348,6 +1348,7 @@ static vo

[PATCH v2 05/10] net: cadence_gem: Set ISR according to queue in use

2020-05-04 Thread Sai Pavan Boddu
Set ISR according to queue in use, added interrupt support for all queues. Signed-off-by: Sai Pavan Boddu --- hw/net/cadence_gem.c | 31 ++- 1 file changed, 22 insertions(+), 9 deletions(-) diff --git a/hw/net/cadence_gem.c b/hw/net/cadence_gem.c index c532a14..beb38

[PATCH v2 00/10] Cadence GEM Fixes

2020-05-04 Thread Sai Pavan Boddu
Hi, Following patch series fixes issues with priority queues, Adds JUMBO Frame support, Makes Debug statements compilable & Fixes related to multicast frames. Changes for V2: Fixed build failure on fedora docker machine Fix buggy debug print to use sized integer casting Sai Pavan

[PATCH v2 04/10] net: cadence_gem: Define access permission for interrupt registers

2020-05-04 Thread Sai Pavan Boddu
Q1 to Q7 ISR's are clear-on-read, IER/IDR registers are write-only, mask reg are read-only. Signed-off-by: Sai Pavan Boddu --- hw/net/cadence_gem.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/hw/net/cadence_gem.c b/hw/net/cadence_gem.c index a930bf1..c532a14 100644 --- a/

[PATCH v2 07/10] net: cadnece_gem: Update irq_read_clear field of designcfg_debug1 reg

2020-05-04 Thread Sai Pavan Boddu
Advertise support of clear-on-read for ISR registers. Signed-off-by: Sai Pavan Boddu --- hw/net/cadence_gem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/net/cadence_gem.c b/hw/net/cadence_gem.c index 848be3f..9eb72a2 100644 --- a/hw/net/cadence_gem.c +++ b/hw/net/cade

[PATCH v2 09/10] net: cadence_gem: TX_LAST bit should be set by guest

2020-05-04 Thread Sai Pavan Boddu
TX_LAST bit should not be set by hardware, its set by guest to inform the last bd of the frame. Signed-off-by: Sai Pavan Boddu Signed-off-by: Edgar E. Iglesias --- hw/net/cadence_gem.c | 6 -- 1 file changed, 6 deletions(-) diff --git a/hw/net/cadence_gem.c b/hw/net/cadence_gem.c index ac3

[PATCH v2 10/10] net: cadence_gem: Fix RX address filtering

2020-05-04 Thread Sai Pavan Boddu
From: Tong Ho Two defects are fixed: 1/ Detection of multicast frames 2/ Treating drop of mis-addressed frames as non-error Signed-off-by: Tong Ho Signed-off-by: Edgar E. Iglesias Signed-off-by: Sai Pavan Boddu --- hw/net/cadence_gem.c | 26 +++--- 1 file changed, 11 ins

[PATCH v2 06/10] net: cadence_gem: Add support for jumbo frames

2020-05-04 Thread Sai Pavan Boddu
Jumbo frames of size 10240 bytes is added. Signed-off-by: Sai Pavan Boddu --- hw/net/cadence_gem.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/hw/net/cadence_gem.c b/hw/net/cadence_gem.c index beb38ec..848be3f 100644 --- a/hw/net/cadence_gem.c +++ b/hw/net/cadence_ge

[PATCH v2 0/1] target/arm: Remove access_el3_aa32ns()

2020-05-04 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Hi, Laurent reported hitting the assert in access_el3_aa32ns() when accessing 32-bit versions of some of the virtualization regs when EL3 is 64-bit. I think we got this wrong back then and it seems to me like we should remove direct usage of access_el3_aa32ns() and alw

[PATCH v2] qcow2: Avoid integer wraparound in qcow2_co_truncate()

2020-05-04 Thread Alberto Garcia
After commit f01643fb8b47e8a70c04bbf45e0f12a9e5bc54de when an image is extended and BDRV_REQ_ZERO_WRITE is set then the new clusters are zeroized. The code however does not detect correctly situations when the old and the new end of the image are within the same cluster. The problem can be reprodu

Re: [PATCH v1 1/1] target/arm: Drop access_el3_aa32ns()

2020-05-04 Thread Edgar E. Iglesias
On Mon, May 04, 2020 at 12:01:07PM +0100, Peter Maydell wrote: > On Tue, 28 Apr 2020 at 17:03, Edgar E. Iglesias > wrote: > > > > From: "Edgar E. Iglesias" > > > > Calling access_el3_aa32ns() works for AArch32 only cores > > but it does not handle 32-bit EL2 on top of 64-bit EL3 > > for mixed 32/

[PATCH] tests/qht-bench: Fix Clang 'int-conversion' warning

2020-05-04 Thread Philippe Mathieu-Daudé
When building with Clang 10 on Fedora 32, we get: tests/qht-bench.c:287:29: error: implicit conversion from 'unsigned long' to 'double' changes value from 18446744073709551615 to 18446744073709551616 [-Werror,-Wimplicit-int-float-conversion] *threshold = rate * UINT64_MAX;

Re: [PATCH] virtiofsd: Use clone() and not unshare(), support non-root

2020-05-04 Thread Colin Walters
On Mon, May 4, 2020, at 10:07 AM, Marc-André Lureau wrote: > Now that systemd-nspawn works without privileges, isn't that also a > solution? One that would fit both system and session level > permissions, and integration with other services? This is a complex topic and one I should probably wr

[PATCH v2 1/1] target/arm: Drop access_el3_aa32ns()

2020-05-04 Thread Edgar E. Iglesias
From: "Edgar E. Iglesias" Calling access_el3_aa32ns() works for AArch32 only cores but it does not handle 32-bit EL2 on top of 64-bit EL3 for mixed 32/64-bit cores. Merge access_el3_aa32ns_aa64any() into access_el3_aa32ns() and only use the latter. Fixes: 68e9c2fe65 ("target-arm: Add VTCR_EL2")

[PULL 00/29] virtio,acpi,pci,pc: backlog from pre-5.0

2020-05-04 Thread Michael S. Tsirkin
The following changes since commit 9af638cc1f665712522608c5d6b8c03d8fa67666: Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20200504' into staging (2020-05-04 13:37:17 +0100) are available in the Git repository at: git://git.kernel.org/pub/scm/virt/kvm/ms

[PULL 03/29] move 'typedef Aml' to qemu/types.h

2020-05-04 Thread Michael S. Tsirkin
From: Gerd Hoffmann Signed-off-by: Gerd Hoffmann Reviewed-by: Igor Mammedov Message-Id: <20200429140003.7336-2-kra...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Reviewed-by: Philippe Mathieu-Daudé --- include/hw/acpi/aml-build.h | 1 - include/qemu/typedef

[PULL 09/29] virtio-vga: fix virtio-vga bar ordering

2020-05-04 Thread Michael S. Tsirkin
From: Anthoine Bourgeois With virtio-vga, pci bar are reordered. Bar #2 is used for compatibility with stdvga. By default, bar #2 is used by virtio modern io bar. This bar is the last one introduce in the virtio pci bar layout and it's crushed by the virtio-vga reordering. So virtio-vga and moder

[PULL 08/29] rtc: add RTC_ISA_BASE

2020-05-04 Thread Michael S. Tsirkin
From: Gerd Hoffmann Add and use RTC_ISA_BASE define instead of hardcoding 0x70. Signed-off-by: Gerd Hoffmann Message-Id: <20200429140003.7336-7-kra...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Igor Mammedov

[PULL 01/29] hw/pci/pcie: Forbid hot-plug if it's disabled on the slot

2020-05-04 Thread Michael S. Tsirkin
From: Julia Suvorova Raise an error when trying to hot-plug/unplug a device through QMP to a device with disabled hot-plug capability. This makes the device behaviour more consistent and provides an explanation of the failure in the case of asynchronous unplug. Signed-off-by: Julia Suvorova Mes

[PULL 11/29] vhost-user-blk: fix invalid memory access

2020-05-04 Thread Michael S. Tsirkin
From: Li Feng when s->inflight is freed, vhost_dev_free_inflight may try to access s->inflight->addr, it will retrigger the following issue. ==7309==ERROR: AddressSanitizer: heap-use-after-free on address 0x604001020d18 at pc 0x55ce948a bp 0x7fffb170 sp 0x7fffb160 READ of size 8 at

[PULL 02/29] hw/pci/pcie: Replace PCI_DEVICE() casts with existing variable

2020-05-04 Thread Michael S. Tsirkin
From: Julia Suvorova A little cleanup is possible because of hotplug_pdev introduction. Signed-off-by: Julia Suvorova Message-Id: <20200427182440.92433-3-jus...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Reviewed-by: Marcel Apfelbaum --- hw/pci/pcie.c | 6

[PULL 13/29] checkpatch: ignore allowed diff list

2020-05-04 Thread Michael S. Tsirkin
Allow changing allowed diff list at any point: - when changing code under test - when adding expected files It's just a list of files so easy to review and merge anyway. Signed-off-by: Michael S. Tsirkin --- scripts/checkpatch.pl | 11 ++- 1 file changed, 6 insertions(+), 5 deletions(-)

[PULL 06/29] acpi: drop pointless _STA method

2020-05-04 Thread Michael S. Tsirkin
From: Gerd Hoffmann When returning a constant there is no point in having a method in the first place, _STA can be a simple integer instead. Signed-off-by: Gerd Hoffmann Reviewed-by: Igor Mammedov Message-Id: <20200429140003.7336-5-kra...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off

[PULL 19/29] tests: Update ACPI tables list for upcoming arm/virt test changes

2020-05-04 Thread Michael S. Tsirkin
From: Shameer Kolothum This is in preparation to update test_acpi_virt_tcg_memhp() with pc-dimm and nvdimm. Update the bios-tables-test-allowed-diff.h with the affected ACPI tables so that "make check" doesn't fail. Also add empty files for new tables required for new test. Signed-off-by: Shame

[PULL 14/29] acpi: DSDT without _STA

2020-05-04 Thread Michael S. Tsirkin
commit f6595976e699 ("acpi: drop pointless _STA method") replaced _STA method with simple name object. Update DSDT accordingly. Signed-off-by: Michael S. Tsirkin --- tests/qtest/bios-tables-test-allowed-diff.h | 17 - tests/data/acpi/pc/DSDT | Bin 5131 -> 512

[PULL 07/29] acpi: add ISADeviceClass->build_aml()

2020-05-04 Thread Michael S. Tsirkin
From: Gerd Hoffmann Also add isa_aml_build() function which walks all isa devices. This allows to move aml builder code to isa devices. Signed-off-by: Gerd Hoffmann Reviewed-by: Igor Mammedov Message-Id: <20200429140003.7336-6-kra...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by:

[PULL 05/29] qtest: allow DSDT acpi table changes

2020-05-04 Thread Michael S. Tsirkin
From: Gerd Hoffmann Signed-off-by: Gerd Hoffmann Message-Id: <20200429140003.7336-4-kra...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin --- tests/qtest/bios-tables-test-allowed-diff.h | 17 + 1 file changed, 17 insertions(+) diff --git a/tests

[PULL 15/29] hw/acpi/nvdimm: Fix for NVDIMM incorrect DSM output buffer length

2020-05-04 Thread Michael S. Tsirkin
From: Shameer Kolothum As per ACPI spec 6.3, Table 19-419 Object Conversion Rules, if the Buffer Field <= to the size of an Integer (in bits), it will be treated as an integer. Moreover, the integer size depends on DSDT tables revision number. If revision number is < 2, integer size is 32 bits, o

[PULL 12/29] checkpatch: fix acpi check with multiple file name

2020-05-04 Thread Michael S. Tsirkin
Using global expected/nonexpected values causes false positives when testing multiple patches in one checkpatch run: one patch can change expected, another one non-expected. Use local variables within process() to fix that. Signed-off-by: Michael S. Tsirkin --- scripts/checkpatch.pl | 22 ++

[PULL 23/29] acpi: unit-test: Ignore diff in WAET ACPI table

2020-05-04 Thread Michael S. Tsirkin
From: Liran Alon This is done as a preparation for the following patch to expose WAET ACPI table to guest. This patch performs steps 1-3 as describes in tests/qtest/bios-tables-test.c. Signed-off-by: Liran Alon Message-Id: <20200313145009.144820-2-liran.a...@oracle.com> Reviewed-by: Michael S.

Infinite loop in bus_unparent(), qdev bug or qdev misuse?

2020-05-04 Thread Markus Armbruster
I stumbled over this while working on a feature branch. Instead of throwing the whole branch at you as a reproducer, I give you a mock up. This is fdctrl_connect_drives(): dev = qdev_create(&fdctrl->bus.bus, "floppy"); qdev_prop_set_uint32(dev, "unit", i); qdev_prop_set_e

[PULL 20/29] bios-tables-test: test pc-dimm and nvdimm coldplug for arm/virt

2020-05-04 Thread Michael S. Tsirkin
From: Shameer Kolothum Since we now have both pc-dimm and nvdimm support, update test_acpi_virt_tcg_memhp() to include those. Signed-off-by: Shameer Kolothum Message-Id: <20200421125934.14952-7-shameerali.kolothum.th...@huawei.com> Acked-by: Peter Maydell Tested-by: Eric Auger Reviewed-by: Mi

[PULL 16/29] nvdimm: Use configurable ACPI IO base and size

2020-05-04 Thread Michael S. Tsirkin
From: Kwangwoo Lee This patch makes IO base and size configurable to create NPIO AML for ACPI NFIT. Since a different architecture like AArch64 does not use port-mapped IO, a configurable IO base is required to create correct mapping of ACPI IO address and size. Signed-off-by: Kwangwoo Lee Sign

[PULL 25/29] acpi: unit-test: Update WAET ACPI Table expected binaries

2020-05-04 Thread Michael S. Tsirkin
From: Liran Alon This is done according to step (6) in the process described at tests/qtest/bios-tables-test.c. Expected WAET.dsl: [000h 4]Signature : "WAET"[Windows ACPI Emulated Devices Table] [004h 0004 4] Table Length : 0028 [008h 0008

[PULL 21/29] tests/acpi: add expected tables for bios-tables-test

2020-05-04 Thread Michael S. Tsirkin
From: Shameer Kolothum Because of the following changes, the expeacted tables for bios-tables-test needs to be updated. 1. Changed NVDIM DSM output buffer AML code. 2. Updated arm/virt test_acpi_virt_tcg_memhp() to add pc-dimm/nvdimm Signed-off-by: Shameer Kolothum Message-Id: <20200421125934.

[PULL 22/29] Refactor vhost_user_set_mem_table functions

2020-05-04 Thread Michael S. Tsirkin
From: Raphael Norwitz vhost_user_set_mem_table() and vhost_user_set_mem_table_postcopy() have gotten convoluted, and have some identical code. This change moves the logic populating the VhostUserMemory struct and fds array from vhost_user_set_mem_table() and vhost_user_set_mem_table_postcopy() t

[PULL 27/29] hw/i386/vmport: Remove unused 'hw/input/i8042.h' include

2020-05-04 Thread Michael S. Tsirkin
From: Philippe Mathieu-Daudé Remove unused "hw/input/i8042.h" include. Signed-off-by: Philippe Mathieu-Daudé Message-Id: <20200504083342.24273-3-f4...@amsat.org> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin --- hw/i386/vmport.c | 1 - 1 file changed, 1 deletion(-) diff

Re: [PATCH v2] tests/qht-bench: Fix Clang 'int-conversion' warning

2020-05-04 Thread Philippe Mathieu-Daudé
Wrong subject =) v3 coming... On 5/4/20 4:41 PM, Philippe Mathieu-Daudé wrote: When building with Clang 10 on Fedora 32, we get: tests/qht-bench.c:287:29: error: implicit conversion from 'unsigned long' to 'double' changes value from 18446744073709551615 to 18446744073709551616 [-Werror,-W

[PULL 29/29] hw/i386: Make vmmouse helpers static

2020-05-04 Thread Michael S. Tsirkin
From: Philippe Mathieu-Daudé The vmmouse helpers are only used in hw/i386/vmmouse.c, make them static. Signed-off-by: Philippe Mathieu-Daudé Message-Id: <20200504083342.24273-5-f4...@amsat.org> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin --- include/hw/i386/pc.h | 4 --

[PULL 26/29] hw/i386/pc: Create 'vmport' device in place

2020-05-04 Thread Michael S. Tsirkin
From: Philippe Mathieu-Daudé Signed-off-by: Philippe Mathieu-Daudé Message-Id: <20200504083342.24273-2-f4...@amsat.org> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin --- include/hw/i386/pc.h | 6 -- hw/i386/pc.c | 2 +- 2 files changed, 1 insertion(+), 7 deleti

[PULL 24/29] acpi: Add Windows ACPI Emulated Device Table (WAET)

2020-05-04 Thread Michael S. Tsirkin
From: Liran Alon Microsoft introduced this ACPI table to avoid Windows guests performing various workarounds for device erratas. As the virtual device emulated by VMM may not have the errata. Currently, WAET allows hypervisor to inform guest about two specific behaviors: One for RTC and the othe

Re: [PATCH v2 02/10] net: cadence_gem: Fix the queue address update during wrap around

2020-05-04 Thread Edgar E. Iglesias
On Mon, May 04, 2020 at 07:36:00PM +0530, Sai Pavan Boddu wrote: > During wrap around and reset, queues are pointing to initial base > address of queue 0, irrespective of what queue we are dealing with. > Fix it by assigning proper base address every time. Might want to add wrappers e.g: static in

[PULL 18/29] hw/arm/virt: Add nvdimm hotplug support

2020-05-04 Thread Michael S. Tsirkin
From: Shameer Kolothum This adds support for nvdimm hotplug events through GED and enables nvdimm for the arm/virt. Now Guests with ACPI can have both cold and hot plug of nvdimms. Hot removal functionality is not yet supported. Signed-off-by: Shameer Kolothum Reviewed-by: Igor Mammedov Revie

[PULL 28/29] hw/i386: Add 'vmport.h' local header

2020-05-04 Thread Michael S. Tsirkin
From: Philippe Mathieu-Daudé Move 'vmport' related declarations in a target-specific header. Signed-off-by: Philippe Mathieu-Daudé Message-Id: <20200504083342.24273-4-f4...@amsat.org> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin --- hw/i386/vmport.h | 34

Re: [PATCH] hostmem: don't use mbind() if host-nodes is epmty

2020-05-04 Thread Philippe Mathieu-Daudé
On 5/1/20 10:57 AM, Daniel P. Berrangé wrote: On Thu, Apr 30, 2020 at 11:46:06AM -0400, Igor Mammedov wrote: Since 5.0 QEMU uses hostmem backend for allocating main guest RAM. The backend however calls mbind() which is typically NOP in case of default policy/absent host-nodes bitmap. However whe

Re: [PATCH v2] qcow2: Avoid integer wraparound in qcow2_co_truncate()

2020-05-04 Thread Kevin Wolf
Am 04.05.2020 um 16:23 hat Alberto Garcia geschrieben: > After commit f01643fb8b47e8a70c04bbf45e0f12a9e5bc54de when an image is > extended and BDRV_REQ_ZERO_WRITE is set then the new clusters are > zeroized. > > The code however does not detect correctly situations when the old and > the new end o

[PULL 17/29] hw/arm/virt: Add nvdimm hot-plug infrastructure

2020-05-04 Thread Michael S. Tsirkin
From: Kwangwoo Lee This adds support to init nvdimm acpi state and build nvdimm acpi tables. Please note nvdimm_support is not yet enabled. Signed-off-by: Kwangwoo Lee Signed-off-by: Eric Auger Signed-off-by: Shameer Kolothum Reviewed-by: Igor Mammedov Message-Id: <20200421125934.14952-4-sha

Re: [PATCH v3 15/15] acpi: simplify build_isa_devices_aml()

2020-05-04 Thread Philippe Mathieu-Daudé
On 5/4/20 3:46 PM, Gerd Hoffmann wrote: On Thu, Apr 30, 2020 at 08:48:31AM +0200, Philippe Mathieu-Daudé wrote: Cc'ing IPMI maintainer. On 4/29/20 4:00 PM, Gerd Hoffmann wrote: x86 machines can have a single ISA bus only. I disagree with the comment. Machines can have multiple ISA bus.

[PULL 10/29] virtio-pci: update virtio pci bar layout documentation

2020-05-04 Thread Michael S. Tsirkin
From: Anthoine Bourgeois The modern io bar was never documented. Signed-off-by: Anthoine Bourgeois Message-Id: <20200422215455.10244-2-anthoine.bourge...@gmail.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin Reviewed-by: Gerd Hoffmann --- hw/virtio/virtio-pci.c | 1 +

Re: [PATCH v2 01/10] net: cadence_gem: Fix debug statements

2020-05-04 Thread Edgar E. Iglesias
On Mon, May 04, 2020 at 07:35:59PM +0530, Sai Pavan Boddu wrote: > Enabling debug breaks the build, Fix them and make debug statements > always compilable. Fix few statements to use sized integer casting. > > Signed-off-by: Sai Pavan Boddu > --- > hw/net/cadence_gem.c | 28 ++

Re: [PATCH v2 03/10] net: cadence_gem: Fix irq update w.r.t queue

2020-05-04 Thread Edgar E. Iglesias
On Mon, May 04, 2020 at 07:36:01PM +0530, Sai Pavan Boddu wrote: > Set irq's specific to a queue, present implementation is setting q1 irq > based on q0 status. Reviewed-by: Edgar E. Iglesias > > Signed-off-by: Sai Pavan Boddu > --- > hw/net/cadence_gem.c | 25 +++-- >

Re: [PATCH] tests/qht-bench: Fix Clang 'int-conversion' warning

2020-05-04 Thread Philippe Mathieu-Daudé
On 5/4/20 4:26 PM, Philippe Mathieu-Daudé wrote: When building with Clang 10 on Fedora 32, we get: tests/qht-bench.c:287:29: error: implicit conversion from 'unsigned long' to 'double' changes value from 18446744073709551615 to 18446744073709551616 [-Werror,-Wimplicit-int-float-conversion]

Re: [PATCH v3 08/15] acpi: serial: don't use _STA method

2020-05-04 Thread Philippe Mathieu-Daudé
On 5/4/20 3:19 PM, Gerd Hoffmann wrote: -static Aml *build_com_device_aml(uint8_t uid) +static void build_com_device_aml(Aml *scope, uint8_t uid) { Aml *dev; Aml *crs; -Aml *method; -Aml *if_ctx; -Aml *else_ctx; -Aml *zero = aml_int(0); -Aml *is_present = aml_

[PULL 04/29] acpi: add aml builder stubs

2020-05-04 Thread Michael S. Tsirkin
From: Gerd Hoffmann Needed when moving aml builder code to devices. Signed-off-by: Gerd Hoffmann Reviewed-by: Igor Mammedov Message-Id: <20200429140003.7336-3-kra...@redhat.com> Reviewed-by: Michael S. Tsirkin Signed-off-by: Michael S. Tsirkin --- hw/acpi/aml-build-stub.c | 79 +

[PATCH v2] tests/qht-bench: Fix Clang 'int-conversion' warning

2020-05-04 Thread Philippe Mathieu-Daudé
When building with Clang 10 on Fedora 32, we get: tests/qht-bench.c:287:29: error: implicit conversion from 'unsigned long' to 'double' changes value from 18446744073709551615 to 18446744073709551616 [-Werror,-Wimplicit-int-float-conversion] *threshold = rate * UINT64_MAX;

Re: [PATCH] qcow2: Avoid integer wraparound in qcow2_co_truncate()

2020-05-04 Thread Eric Blake
On 5/4/20 8:47 AM, Alberto Garcia wrote: Drop this hunk (leave zero_start unchanged), and instead... So, using your numbers, pre-patch, we have zero_start = 0x9 (0x82000 rounded up to 0x1 alignment).  post-patch, the new MIN() lowers it back to 0x8dc00 (the new size), which is unalign

Re: [PATCH v2 04/10] net: cadence_gem: Define access permission for interrupt registers

2020-05-04 Thread Edgar E. Iglesias
On Mon, May 04, 2020 at 07:36:02PM +0530, Sai Pavan Boddu wrote: > Q1 to Q7 ISR's are clear-on-read, IER/IDR registers > are write-only, mask reg are read-only. > > Signed-off-by: Sai Pavan Boddu > --- > hw/net/cadence_gem.c | 14 ++ > 1 file changed, 14 insertions(+) > > diff --git

Re: [PATCH 2/4] coroutine: Add check for SafeStack in sigalstack

2020-05-04 Thread Philippe Mathieu-Daudé
On 4/29/20 9:44 PM, Daniele Buono wrote: LLVM's SafeStack instrumentation cannot be used inside signal handlers that make use of sigaltstack(). Since coroutine-sigaltstack relies on sigaltstack(), it is not compatible with SafeStack. The resulting binary is incorrect, with different coroutines sh

Re: [PATCH v2 05/10] net: cadence_gem: Set ISR according to queue in use

2020-05-04 Thread Edgar E. Iglesias
On Mon, May 04, 2020 at 07:36:03PM +0530, Sai Pavan Boddu wrote: > Set ISR according to queue in use, added interrupt support for > all queues. Would it help to add a gem_set_isr(CadenceGEMState *s, int q, uint32_t flag) ? Instead of open coding these if (q == 0) else... all over the place... Any

[PATCH v3] tests/qht-bench: Fix Clang 'implicit-int-float-conversion' warning

2020-05-04 Thread Philippe Mathieu-Daudé
When building with Clang 10 on Fedora 32, we get: tests/qht-bench.c:287:29: error: implicit conversion from 'unsigned long' to 'double' changes value from 18446744073709551615 to 18446744073709551616 [-Werror,-Wimplicit-int-float-conversion] *threshold = rate * UINT64_MAX;

Re: [PATCH 0/4] Add support for SafeStack

2020-05-04 Thread Philippe Mathieu-Daudé
On 4/29/20 9:44 PM, Daniele Buono wrote: LLVM supports SafeStack instrumentation to protect against stack buffer overflows, since version 3.7 From https://clang.llvm.org/docs/SafeStack.html: "It works by separating the program stack into two distinct regions: the safe stack and the unsafe stack

Re: Infinite loop in bus_unparent(), qdev bug or qdev misuse?

2020-05-04 Thread Paolo Bonzini
On 04/05/20 16:38, Markus Armbruster wrote: > makes no progreess because OBJECT(dev)->parent is still null, and > therefore object_unparent() does nothing. > > Possible culprit: qdev_try_create() calls qdev_set_parent_bus(), which > adds the device to the bus, but leaves ->parent null. If this is

[PULL v2 1/4] fuzz: select fuzz target using executable name

2020-05-04 Thread Stefan Hajnoczi
From: Alexander Bulekov The fuzzers are built into a binary (e.g. qemu-fuzz-i386). To select the device to fuzz/fuzz target, we usually use the --fuzz-target= argument. This commit allows the fuzz-target to be specified using the name of the executable. If the executable name ends with -target-FU

[PULL v2 0/4] Block patches

2020-05-04 Thread Stefan Hajnoczi
The following changes since commit 9af638cc1f665712522608c5d6b8c03d8fa67666: Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-20200504' into staging (2020-05-04 13:37:17 +0100) are available in the Git repository at: https://github.com/stefanha/qemu.git tags/

[PULL v2 2/4] lockable: fix __COUNTER__ macro to be referenced properly

2020-05-04 Thread Stefan Hajnoczi
From: Daniel Brodsky - __COUNTER__ doesn't work with ## concat - replaced ## with glue() macro so __COUNTER__ is evaluated Fixes: 3284c3ddc4 Signed-off-by: Daniel Brodsky Message-id: 20200404042108.389635-2-dnbrd...@gmail.com Signed-off-by: Stefan Hajnoczi --- include/qemu/lockable.h | 7 +++

[PULL v2 4/4] lockable: Replace locks with lock guard macros

2020-05-04 Thread Stefan Hajnoczi
From: Simran Singhal Replace manual lock()/unlock() calls with lock guard macros (QEMU_LOCK_GUARD/WITH_QEMU_LOCK_GUARD). Signed-off-by: Simran Singhal Reviewed-by: Yuval Shaia Reviewed-by: Marcel Apfelbaum Tested-by: Yuval Shaia Message-id: 20200402065035.GA15477@simran-Inspiron-5558 Signed-o

[PULL v2 3/4] lockable: replaced locks with lock guard macros where appropriate

2020-05-04 Thread Stefan Hajnoczi
From: Daniel Brodsky - ran regexp "qemu_mutex_lock\(.*\).*\n.*if" to find targets - replaced result with QEMU_LOCK_GUARD if all unlocks at function end - replaced result with WITH_QEMU_LOCK_GUARD if unlock not at end Signed-off-by: Daniel Brodsky Reviewed-by: Juan Quintela Message-id: 20200404

<    1   2   3   4   5   6   >