[Qemu-devel] [Bug 1726394] Re: Passes through prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, address)

2017-10-23 Thread Julian Andres Klode
Returning EINVAL would make sense, as that's what a pre-seccomp kernel or a kernel built without seccomp support would do. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1726394 Title: Passes throug

Re: [Qemu-devel] qemu compile error

2017-10-23 Thread Chen, Farrah
Thank you very much! I removed "1>/dev/null 2>&1" in scripts/git-submodule.sh and found I can't git clone git://git.qemu-project.org/dtc.git without tsocks. I used Daniel's approach, created the wrapper script called 'git' that runs 'exec tsocks /usr/bin/git "$@"', it succeeded. Considering we st

Re: [Qemu-devel] qemu compile error

2017-10-23 Thread Daniel P. Berrange
On Mon, Oct 23, 2017 at 01:43:30PM +, Chen, Farrah wrote: > Thank you very much! > I removed "1>/dev/null 2>&1" in scripts/git-submodule.sh and found I can't > git clone git://git.qemu-project.org/dtc.git without tsocks. > I used Daniel's approach, created the wrapper script called 'git' that r

Re: [Qemu-devel] [Qemu-arm] [PATCH] hw/arm/virt: support 4 serial ports

2017-10-23 Thread Philippe Mathieu-Daudé
Hi Peter, On 10/23/2017 10:11 AM, Peter Maydell wrote: > This is really the documentation being wrong -- that is actually > a PC specific thing. In QEMU generally, -serial can be used > for as many serial ports as the machine model provides, up > to a maximum of four. FYI I'm still working on not

Re: [Qemu-devel] Qemu query ( support for new board)

2017-10-23 Thread Peter Maydell
On 23 October 2017 at 12:57, Fahad Butt wrote: > 1- I want to know whether qemu can be cycle accurate or not? from > my search i believe it is not cycle accurate. But is it possible? > Cycle accuracy? You're correct that QEMU is not cycle accurate. In general for modern complex CPUs cycle accurat

Re: [Qemu-devel] [PATCH v2] Fix compile with --disable-tpm

2017-10-23 Thread Stefan Berger
On 10/23/2017 06:24 AM, BALATON Zoltan wrote: Signed-off-by: BALATON Zoltan Tested-by: Stefan Berger --- tpm.c | 35 ++- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/tpm.c b/tpm.c index 45520f5..ed78ead 100644 --- a/tpm.c +++ b/tpm.c @@

Re: [Qemu-devel] [Qemu-arm] [PATCH] hw/arm/virt: support 4 serial ports

2017-10-23 Thread Jason A. Donenfeld
Hey Peter, I really do need more serial ports. Two, actually. I'm using qemu on build.wireguard.com for CI. I have normal output come on ttyS0 (ttyAMA0) and then if it's successful, the final step is writing "success" into ttyS1 (ttyAMA1), so that I can confirm with certainty that the tests succee

Re: [Qemu-devel] [PATCH v2 06/10] migration: Make sure that we pass the right cache size

2017-10-23 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > Instead of passing silently round down the number of pages, make it an > error that the cache size is not a power of 2. > > Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert > --- > migration/page_cache.c | 12 +++- > 1 fil

[Qemu-devel] [PATCH v6 4/9] memfd: add hugetlb support

2017-10-23 Thread Marc-André Lureau
Linux commit 749df87bd7bee5a79cef073f5d032ddb2b211de8 (v4.14-rc1) added a new flag MFD_HUGETLB to memfd_create() that specify the file to be created resides in the hugetlbfs filesystem. This is the generic hugetlbfs filesystem not associated with any specific mount point. hugetlbfs does not suppo

[Qemu-devel] [PATCH v6 3/9] memfd: add error argument, instead of perror()

2017-10-23 Thread Marc-André Lureau
This will allow callers to silence error report when the call is allowed to failed. Signed-off-by: Marc-André Lureau --- include/qemu/memfd.h | 5 +++-- hw/virtio/vhost.c| 8 +++- util/memfd.c | 57 +++- 3 files changed, 40 insert

[Qemu-devel] [PATCH v6 0/9] Add memfd memory backend

2017-10-23 Thread Marc-André Lureau
Add a new Linux-specific memory backend, similar to hostmem-file, except that it doesn't need file path. It also try to enforce memory sealing if available. It is thus slightly easier and secure, and is compatible with transparent huge-pages since Linux 4.8. Since Linux 4.14, memfd supports explic

[Qemu-devel] [PATCH v6 1/9] memfd: split qemu_memfd_alloc()

2017-10-23 Thread Marc-André Lureau
Add a function to only create a memfd, without mmap. The function is used in the following memory backend. Signed-off-by: Marc-André Lureau Reviewed-by: Philippe Mathieu-Daudé --- include/qemu/memfd.h | 1 + util/memfd.c | 61 +++- 2 file

[Qemu-devel] [PATCH v6 2/9] memfd: remove needless include

2017-10-23 Thread Marc-André Lureau
Signed-off-by: Marc-André Lureau Reviewed-by: Philippe Mathieu-Daudé --- util/memfd.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/util/memfd.c b/util/memfd.c index e9c1a0e700..b5b7a41347 100644 --- a/util/memfd.c +++ b/util/memfd.c @@ -27,8 +27,6 @@ #include "qemu/osdep.h" -#includ

[Qemu-devel] [PATCH v6 6/9] Add memfd based hostmem

2017-10-23 Thread Marc-André Lureau
Add a new memory backend, similar to hostmem-file, except that it doesn't need to create files. It also enforces memory sealing. This backend is mainly useful for sharing the memory with other processes. Note that Linux supports transparent huge-pages of shmem/memfd memory since 4.8. It is relati

[Qemu-devel] [PATCH v6 5/9] memfd: add hugetlbsize argument

2017-10-23 Thread Marc-André Lureau
Learn to specificy hugetlb size as qemu_memfd_create() argument. Signed-off-by: Marc-André Lureau --- include/qemu/memfd.h | 2 +- util/memfd.c | 22 ++ 2 files changed, 19 insertions(+), 5 deletions(-) diff --git a/include/qemu/memfd.h b/include/qemu/memfd.h index

[Qemu-devel] [PATCH v6 7/9] tests: keep compiling failing vhost-user tests

2017-10-23 Thread Marc-André Lureau
Let's protect the failing tests under a QTEST_VHOST_USER_FIXME environment variable, so we keep compiling the tests and we can easily run them. Signed-off-by: Marc-André Lureau --- tests/vhost-user-test.c | 27 ++- 1 file changed, 14 insertions(+), 13 deletions(-) diff -

[Qemu-devel] [PATCH v6 9/9] tests: use memfd in vhost-user-test

2017-10-23 Thread Marc-André Lureau
This will exercise the memfd memory backend and should generally be better for testing than memory-backend-file (thanks to anonymous files and sealing). If memfd is available, it is preferred. However, in order to check that file & memfd backends both work correctly, the read-guest-mem test is ch

Re: [Qemu-devel] [Qemu-block][PATCH] qemu-block: add support HMB with feature commands.

2017-10-23 Thread Keith Busch
On Sat, Oct 21, 2017 at 03:54:16PM +0900, Minwoo Im wrote: > Add support HMB(Host Memory Block) with feature commands(Get Feature, Set > Feature). > nvme-4.14 tree supports HMB features. > This patch will make nvme controller to return 32MiB preferred size of HMB to > host via identify command. >

[Qemu-devel] [PATCH v6 8/9] vhost-user-test: make read-guest-mem setup its own qemu

2017-10-23 Thread Marc-André Lureau
Signed-off-by: Marc-André Lureau --- tests/vhost-user-test.c | 66 ++--- 1 file changed, 35 insertions(+), 31 deletions(-) diff --git a/tests/vhost-user-test.c b/tests/vhost-user-test.c index 7fc6f85888..2da6b6d61f 100644 --- a/tests/vhost-user-test.c

Re: [Qemu-devel] [PATCH v2 07/10] migration: Don't play games with the requested cache size

2017-10-23 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > Now that we check that the value passed is a power of 2, we don't need > to play games when comparing what is the size that is going to take > the cache. > > Signed-off-by: Juan Quintela > --- > migration/ram.c | 11 ++- > 1 file changed, 6

Re: [Qemu-devel] [PATCH v1] os-posix: Add -unshare option

2017-10-23 Thread Ross Lagerwall
On 10/19/2017 05:24 PM, Daniel P. Berrange wrote: On Thu, Oct 19, 2017 at 05:04:19PM +0100, Ross Lagerwall wrote: Add an option to allow calling unshare() just before starting guest execution. The option allows unsharing one or more of the mount namespace, the network namespace, and the IPC name

Re: [Qemu-devel] [PATCH v2 08/10] migration: No need to return the size of the cache

2017-10-23 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > After the previous commits, we make sure that the value passed is > right, or we just drop an error. So now we return if there is one > error or we have setup correctly the value passed. > > Signed-off-by: Juan Quintela > --- > migration/migration.

[Qemu-devel] [PULL 0/3] MIPS queue

2017-10-23 Thread Yongbok Kim
The following changes since commit e822e81e350825dd94f41ee2538ff1432b812eb9: Merge remote-tracking branch 'remotes/stefanha/tags/block-pull-request' into staging (2017-10-20 15:04:00 +0100) are available in the git repository at: git://github.com/yongbok/upstream-qemu.git target-mips.next

[Qemu-devel] [PULL 3/3] MAINTAINERS: Update Paul Burton's email address

2017-10-23 Thread Yongbok Kim
From: Paul Burton Update my email address from paul.bur...@imgtec.com to paul.bur...@mips.com, since MIPS will soon no longer be a part of Imagination Technologies & as such the @imgtec.com address will soon cease to function. A mapping is added in .mailmap such that git reports the new @mips.co

[Qemu-devel] [PULL 1/3] MAINTAINERS: Update Yongbok Kim's email address

2017-10-23 Thread Yongbok Kim
Update my email address to mips.com Signed-off-by: Yongbok Kim --- MAINTAINERS |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index 1217542..245f7d5 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -162,7 +162,7 @@ F: disas/microblaze.c MI

[Qemu-devel] [PULL 2/3] MAINTAINERS: Update James Hogan's email address

2017-10-23 Thread Yongbok Kim
From: James Hogan Update my imgtec.com email address to my kernel.org one in MAINTAINERS as MIPS will soon no longer be part of Imagination Technologies, and add a mapping in .mailcap so get_maintainer.pl reports the right address. Signed-off-by: James Hogan Cc: Michael Tokarev Cc: Laurent Viv

Re: [Qemu-devel] [PATCH v1] os-posix: Add -unshare option

2017-10-23 Thread Daniel P. Berrange
On Mon, Oct 23, 2017 at 03:30:05PM +0100, Ross Lagerwall wrote: > On 10/19/2017 05:24 PM, Daniel P. Berrange wrote: > > On Thu, Oct 19, 2017 at 05:04:19PM +0100, Ross Lagerwall wrote: > > > Add an option to allow calling unshare() just before starting guest > > > execution. The option allows unshar

Re: [Qemu-devel] [PATCH v1] os-posix: Add -unshare option

2017-10-23 Thread Ross Lagerwall
On 10/23/2017 03:50 PM, Daniel P. Berrange wrote: On Mon, Oct 23, 2017 at 03:30:05PM +0100, Ross Lagerwall wrote: On 10/19/2017 05:24 PM, Daniel P. Berrange wrote: On Thu, Oct 19, 2017 at 05:04:19PM +0100, Ross Lagerwall wrote: Add an option to allow calling unshare() just before starting gues

Re: [Qemu-devel] [PATCH v2 09/10] migration: Make xbzrle_cache_size a migration parameter

2017-10-23 Thread Dr. David Alan Gilbert
* Juan Quintela (quint...@redhat.com) wrote: > Right now it is a variable in MigrationState instead of a > MigrationParameter. The change allows to set it as the rest of the > Migration parameters, from the command line, with > query_migration_paramters, set_migrate_parameters, etc. > > Signed-of

Re: [Qemu-devel] [PATCH v1] os-posix: Add -unshare option

2017-10-23 Thread Daniel P. Berrange
On Mon, Oct 23, 2017 at 04:01:12PM +0100, Ross Lagerwall wrote: > On 10/23/2017 03:50 PM, Daniel P. Berrange wrote: > > On Mon, Oct 23, 2017 at 03:30:05PM +0100, Ross Lagerwall wrote: > > > On 10/19/2017 05:24 PM, Daniel P. Berrange wrote: > > > > On Thu, Oct 19, 2017 at 05:04:19PM +0100, Ross Lage

[Qemu-devel] QMP, HMP: introduce 'writeconfig' command

2017-10-23 Thread Vadim Galitsyn
Hi Guys, This thread is a continuation of discussion started in http://lists.nongnu.org/archive/html/qemu-devel/2017-02/msg03182.html. This series introduces ‘writeconfig’ command support for QMP and HMP monitors. This functionality might be useful for live migration for cases when guest config

[Qemu-devel] [PATCH 1/4] qmp: introduce 'writeconfig' command

2017-10-23 Thread Vadim Galitsyn
Add support for `writeconfig' command for QMP monitor. This is a simple way to keep track of current state of VM after series of hotplugs and/or hotunplugs of different devices. Signed-off-by: Vadim Galitsyn Signed-off-by: Eduardo Otubo Cc: Markus Armbruster Cc: Eric Blake Cc: qemu-devel@nongn

[Qemu-devel] [PATCH 4/4] tests: test-hmp: print command execution result

2017-10-23 Thread Vadim Galitsyn
Provide HMP monitor command execution result as it would be seen by user who established an HMP monitor session. Currently many commands may silently fail without any sign of that. This patch let this info to be printed once test is running in verbose mode. For the future it might be useful to fa

[Qemu-devel] [PATCH 2/4] hmp: introduce 'writeconfig' command

2017-10-23 Thread Vadim Galitsyn
Add 'writeconfig' command for HMP monitor. This command is a sibling of QMP command 'writeconfig'. This is a simple way to keep track of current state of VM after series of hotplugs and/or hotunplugs of different devices. Signed-off-by: Vadim Galitsyn Signed-off-by: Eduardo Otubo Cc: Dr. David

[Qemu-devel] [PATCH 3/4] tests: test-hmp: extend with 'writeconfig' command

2017-10-23 Thread Vadim Galitsyn
Extend list of test cases with 'writeconfig' command. Signed-off-by: Vadim Galitsyn Cc: Dr. David Alan Gilbert Cc: qemu-devel@nongnu.org --- tests/test-hmp.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/test-hmp.c b/tests/test-hmp.c index 5677fbf775..8e21eee61c 100644 --- a/tests/t

Re: [Qemu-devel] [PATCH v2 08/10] migration: No need to return the size of the cache

2017-10-23 Thread Juan Quintela
"Dr. David Alan Gilbert" wrote: > * Juan Quintela (quint...@redhat.com) wrote: >> After the previous commits, we make sure that the value passed is >> right, or we just drop an error. So now we return if there is one >> error or we have setup correctly the value passed. >> >> Signed-off-by: Juan

[Qemu-devel] [RFC v2 1/4] hw/intc/arm_gicv3_its: Don't abort on table save failure

2017-10-23 Thread Eric Auger
The ITS is not fully properly reset at the moment. Caches are not emptied. After a reset, in case we attempt to save the state before the bound devices have registered their MSIs and after the 1st level table has been allocated by the ITS driver (device BASER is valid), the first level entries are

[Qemu-devel] [RFC v2 0/4] vITS Reset

2017-10-23 Thread Eric Auger
At the moment the ITS is not properly reset. On System reset or reboot, previous ITS register values and caches are left unchanged. Some of the registers might point to some guest RAM tables which are not valid anymore. This leads to state inconsistencies that are detected by the kernel save/restor

[Qemu-devel] [RFC v2 3/4] linux-headers: Partial header update for ITS reset

2017-10-23 Thread Eric Auger
This aims at importing the KVM_DEV_ARM_ITS_CTRL_RESET attribute which allows to trigger a reset of the in-kernel emulated ITS. This is not yet upstream but can be found on the follwing branch: https://github.com/eauger/linux/tree/v4.14-rc2-its-reset-v2 Signed-off-by: Eric Auger --- linux-header

[Qemu-devel] [RFC v2 2/4] hw/intc/arm_gicv3_its: Implement a minimalist reset

2017-10-23 Thread Eric Auger
At the moment the ITS is not properly reset and this causes various bugs on save/restore. We implement a minimalist cold reset through individual register writes. This does not void the ITS cache though. This full reset will be addressed through a specific ioctl. Signed-off-by: Eric Auger --- t

Re: [Qemu-devel] [PATCH] Fix compile with --disable-tpm

2017-10-23 Thread BALATON Zoltan
On Mon, 23 Oct 2017, Philippe Mathieu-Daudé wrote: On 10/23/2017 08:09 AM, Philippe Mathieu-Daudé wrote: On 10/23/2017 07:24 AM, BALATON Zoltan wrote: [...] info = g_new0(TPMInfoList, 1); +#ifdef CONFIG_TPM info->value = tpm_backend_query_tpm(drv); - +#endif if (!cur

[Qemu-devel] [RFC v2 4/4] hw/intc/arm_gicv3_its: Implement full reset

2017-10-23 Thread Eric Auger
Voiding the ITS caches is not supposed to happen via individual register writes. So we introduced a dedicated ITS KVM device ioctl to perform a cold reset of the ITS: KVM_DEV_ARM_VGIC_GRP_CTRL/KVM_DEV_ARM_ITS_CTRL_RESET. Let's use this latter if the kernel supports it. Signed-off-by: Eric Auger -

[Qemu-devel] Is Cortex-R8 support planned?

2017-10-23 Thread Dong-In Kang
Hello, I know there is no support for Cortex-R8 guest architecture now. Is it planned? How much man-hour would be needed to implement Cortex-R8 support for Qemu? Thanks, David

[Qemu-devel] [PULL 01/21] migration: Fix migrate_test_apply for multifd parameters

2017-10-23 Thread Juan Quintela
They were missing when introduced on the tree Signed-off-by: Juan Quintela Reviewed-by: Peter Xu --- migration/migration.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/migration/migration.c b/migration/migration.c index 98429dc843..fb62a639d8 100644 --- a/migration/migration.c +++

[Qemu-devel] [PULL 06/21] migration: Add 'pause-before-switchover' capability

2017-10-23 Thread Juan Quintela
From: "Dr. David Alan Gilbert" When 'pause-before-switchover' is enabled, the outgoing migration will pause before invalidating the block devices and serializing the device state. At this point the management layer gets the chance to clean up any device jobs or other device users before the migra

[Qemu-devel] [PULL 03/21] migration: Make cache size elements use the right types

2017-10-23 Thread Juan Quintela
Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert --- migration/page_cache.c | 8 migration/page_cache.h | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/migration/page_cache.c b/migration/page_cache.c index 381e555ddb..6b2dd77cf0 100644 --- a/migrat

[Qemu-devel] [PULL 11/21] migration: allow cancel to unpause

2017-10-23 Thread Juan Quintela
From: "Dr. David Alan Gilbert" If a migration_cancel is issued during the new paused state, kick the pause_sem to get to unpause so it can cancel. Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Peter Xu Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/migration.c |

[Qemu-devel] [PULL 00/21] Migration pull request

2017-10-23 Thread Juan Quintela
e822e81e350825dd94f41ee2538ff1432b812eb9: Merge remote-tracking branch 'remotes/stefanha/tags/block-pull-request' into staging (2017-10-20 15:04:00 +0100) are available in the git repository at: git://github.com/juanquintela/qemu.git tags/migration/20171023 for you to fetch cha

[Qemu-devel] [PULL 08/21] migration: Wait for semaphore before completing migration

2017-10-23 Thread Juan Quintela
From: "Dr. David Alan Gilbert" Wait for a semaphore before completing the migration, if the previously added capability was enabled. Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Peter Xu Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/migration.c | 38 +++

[Qemu-devel] [PULL 13/21] migration: provide ram_state_init()

2017-10-23 Thread Juan Quintela
From: Peter Xu The old ram_state_init() is not really initializing the RAMState only, but including lots of other stuff that is RAM-related. Renaming it to ram_init_all(). Instead, provide a real ram_state_init(). Signed-off-by: Peter Xu Reviewed-by: Juan Quintela Signed-off-by: Juan Quintel

[Qemu-devel] [PULL 10/21] migrate: HMP migate_continue

2017-10-23 Thread Juan Quintela
From: "Dr. David Alan Gilbert" HMP equivalent to the just added migrate-continue Unpause a migrate paused at a given state. Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Peter Xu Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- hmp-commands.hx | 12 hmp.c

[Qemu-devel] [PULL 09/21] migration: migrate-continue

2017-10-23 Thread Juan Quintela
From: "Dr. David Alan Gilbert" A new qmp command allows the caller to continue from a given paused state. Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Peter Xu Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/migration.c | 11 +++ qapi/migration.json | 1

[Qemu-devel] [PULL 07/21] migration: Add 'pre-switchover' and 'device' statuses

2017-10-23 Thread Juan Quintela
From: "Dr. David Alan Gilbert" Add two statuses for use when the 'pause-before-switchover' capability is enabled. 'pre-switchover' is the state that we wait in for management to allow us to continue. 'device' is the state we enter while serialising the devices after management gives us the OK.

[Qemu-devel] [PULL 04/21] migration: Move xbzrle cache resize error handling to xbzrle_cache_resize

2017-10-23 Thread Juan Quintela
Signed-off-by: Juan Quintela Reviewed-by: Peter Xu --- migration/migration.c | 18 +- migration/ram.c | 22 -- migration/ram.h | 2 +- 3 files changed, 22 insertions(+), 20 deletions(-) diff --git a/migration/migration.c b/migration/migration.c i

[Qemu-devel] [PULL 16/21] migration: new ram_init_bitmaps()

2017-10-23 Thread Juan Quintela
From: Peter Xu Rearrange the bitmap initialization and the first sync. Since at it, make sure the locks are taken/released in correct order (I moved RCU unlock upper - though it may not affect much). Signed-off-by: Peter Xu Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migrati

[Qemu-devel] [PULL 17/21] migration: postcopy_place_page factoring out

2017-10-23 Thread Juan Quintela
From: Alexey Perevalov Need to mark copied pages as closer as possible to the place where it tracks down. That will be necessary in futher patch. Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Peter Xu Reviewed-by: Juan Quintela Signed-off-by: Alexey Perevalov Signed-off-by: Juan Quintela

[Qemu-devel] [PULL 02/21] migratiom: Remove max_item_age parameter

2017-10-23 Thread Juan Quintela
It was not used at all since commit: 27af7d6ea5015e5ef1f7985eab94a8a218267a2b which replaced its use by the dirty sync count. Signed-off-by: Juan Quintela Reviewed-by: Peter Xu --- migration/page_cache.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/migration/page_cache.c b/migration/p

[Qemu-devel] [PULL 15/21] migration: clean up xbzrle cache init/destroy

2017-10-23 Thread Juan Quintela
From: Peter Xu Let's further simplify ram_init_all() and ram_save_cleanup() by abstract all the XBZRLE related codes into their own functions. When allocating xbzrle cache, we are always very careful on -ENOMEM; which makes sense. Replacing the last g_malloc0() with g_try_malloc0(), then refact

[Qemu-devel] [PULL 19/21] migration: add bitmap for received page

2017-10-23 Thread Juan Quintela
From: Alexey Perevalov This patch adds ability to track down already received pages, it's necessary for calculation vCPU block time in postcopy migration feature, and for recovery after postcopy migration failure. Also it's necessary to solve shared memory issue in postcopy livemigration. Inform

[Qemu-devel] [PULL 20/21] qapi: Fix grammar in x-multifd-page-count descriptions

2017-10-23 Thread Juan Quintela
Reported-by: Eric Blake Signed-off-by: Juan Quintela --- qapi/migration.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/qapi/migration.json b/qapi/migration.json index 272f191551..6ae866e1aa 100644 --- a/qapi/migration.json +++ b/qapi/migration.json @@ -480,7 +480,

[Qemu-devel] [PULL 05/21] migration: Make cache_init() take an error parameter

2017-10-23 Thread Juan Quintela
Once there, take a total size instead of the size of the pages. We move the check that the new_size is bigger than one page from xbzrle_cache_resize(). Signed-off-by: Juan Quintela Reviewed-by: Peter Xu -- Fix typo spotted by Peter Xu --- migration/page_cache.c | 17 +++-- migrat

[Qemu-devel] [PULL 12/21] migration: pause-before-switchover for postcopy

2017-10-23 Thread Juan Quintela
From: "Dr. David Alan Gilbert" Add pause-before-switchover support for postcopy. After starting postcopy it will transition active->pre-switchover->postcopy_active Signed-off-by: Dr. David Alan Gilbert Reviewed-by: Peter Xu Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- mig

[Qemu-devel] [PULL 21/21] migration: Improve migration thread error handling

2017-10-23 Thread Juan Quintela
We now report errors also when we finish migration, not only on info migrate. We plan to use this error from several places, and we want the first error to happen to win, so we add an mutex to order it. Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert --- migration/migration.c

Re: [Qemu-devel] [Qemu-block] [PATCH] qemu-block: add support HMB with feature commands.

2017-10-23 Thread Stefan Hajnoczi
On Sat, Oct 21, 2017 at 03:54:16PM +0900, Minwoo Im wrote: > Add support HMB(Host Memory Block) with feature commands(Get Feature, Set > Feature). > nvme-4.14 tree supports HMB features. > This patch will make nvme controller to return 32MiB preferred size of HMB to > host via identify command. >

[Qemu-devel] [PULL 14/21] migration: provide ram_state_cleanup

2017-10-23 Thread Juan Quintela
From: Peter Xu There are two Mutexes that are created but not yet destroyed for RAMState. Fix that. Since we are at it, provide helper function to clean up RAMState. Signed-off-by: Peter Xu Reviewed-by: Juan Quintela Signed-off-by: Juan Quintela --- migration/ram.c | 13 ++--- 1 fi

[Qemu-devel] [PULL 18/21] migration: introduce qemu_ufd_copy_ioctl helper

2017-10-23 Thread Juan Quintela
From: Alexey Perevalov Just for placing auxilary operations inside helper, auxilary operations like: track received pages, notify about copying operation in futher patches. Reviewed-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert Reviewed-by: Peter Xu Signed-off-by: Alexey Perevalov Si

Re: [Qemu-devel] [libfdt][PATCH v3] implement strnlen for systems that need it

2017-10-23 Thread Stefan Hajnoczi
On Sun, Oct 22, 2017 at 10:50:16PM -0400, John Arbuckle wrote: > Prior the Mac OS 10.7, the function strnlen() was not available. This patch > implements strnlen() on Mac OS X versions that are below 10.7. > > Signed-off-by: John Arbuckle > --- > v3 changes: > - Replaced loop with memchr() > > v

Re: [Qemu-devel] [libfdt][PATCH v3] implement strnlen for systems that need it

2017-10-23 Thread Peter Maydell
On 23 October 2017 at 17:09, Stefan Hajnoczi wrote: >> +/* strnlen() is not available on Mac OS < 10.7 */ >> +# if (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_7) > > Does this cover the case where MAC_OS_X_VERSION_MAX_ALLOWED is set to > <1070 on a 10.7+ build machine? It's possible that

Re: [Qemu-devel] Unable to clone git repository from git.qemu.org

2017-10-23 Thread Stefan Hajnoczi
On Sun, Oct 22, 2017 at 11:13:12AM -0500, Eduardo A. Bustamante López wrote: > I apologize if this is not the right mailing list for this report. I'm unable > to clone the git repository from > git://git.qemu.org/qemu.git (which is listed on > https://www.qemu.org/contribute/). The issue is fixe

Re: [Qemu-devel] [PATCH V8] qqq: module for synchronizing with a simulation

2017-10-23 Thread Emilio G. Cota
On Tue, Sep 19, 2017 at 17:43:06 -0400, nutar...@ornl.gov wrote: > += Synchronizing the virtual clock with an external source = > + > +QEMU has a protocol for synchronizing its virtual clock > +with the clock of a simulator in which QEMU is embedded > +as a component. This options is enabled with t

[Qemu-devel] [PATCH] hw/pci-host/gpex: Improve INTX to gsi routing error checking

2017-10-23 Thread Eric Auger
We exposed gpex_set_irq_num() for machines to set the INTx to GSI routing. However if the machine forgets to call that function we currently do not check the association was properly done. Let's initialize gsi values to -1 and if this value is found in gpex_route_intx_pin_to_irq, set the routing mo

Re: [Qemu-devel] [PATCH] BCM2837 and machine raspi3

2017-10-23 Thread Andrew Baumann via Qemu-devel
> From: Qemu-devel On Behalf Of bzt bzt > Sent: Sunday, 22 October 2017 06:21 > > I've added support for "-M raspi3" to qemu. This is my first patch, I hope > it's okay. The github repo is here: https://github.com/bztsrc/qemu-raspi3 > in case my patch does not work for some reason. Thanks for the

Re: [Qemu-devel] [PATCH] qemu-pr-helper: Do not use {0} for initialization

2017-10-23 Thread Stefan Hajnoczi
On Fri, Oct 20, 2017 at 01:21:21PM +0200, Paolo Bonzini wrote: > The first field in struct dm_ioctl is an array, and old GCC warns > about it with -Wmissing-braces (GCC <= 4.8). The "{0}" universal > zero initializer is only useful if the other side might be a scalar; > for a struct, "{}" is enoug

Re: [Qemu-devel] [PATCH v7 08/52] tcg: Introduce temp_arg, export temp_idx

2017-10-23 Thread Emilio G. Cota
On Fri, Oct 20, 2017 at 16:19:39 -0700, Richard Henderson wrote: > From: Richard Henderson > > At the same time, adrop the TCGContext argument and use tcg_ctx instead. s/adrop/drop/ :P Emilio

Re: [Qemu-devel] [PATCH v7 16/52] tcg: Introduce tcgv_{i32, i64, ptr}_{arg, temp}

2017-10-23 Thread Emilio G. Cota
On Fri, Oct 20, 2017 at 16:19:47 -0700, Richard Henderson wrote: > Transform TCGv_* to an "argument" or a temporary. > For now, an argument is simply the temporary index. > > Signed-off-by: Richard Henderson Reviewed-by: Emilio G. Cota E.

Re: [Qemu-devel] [PATCH v7 17/52] tcg: Introduce temp_tcgv_{i32, i64, ptr}

2017-10-23 Thread Emilio G. Cota
On Fri, Oct 20, 2017 at 16:19:48 -0700, Richard Henderson wrote: > Signed-off-by: Richard Henderson Reviewed-by: Emilio G. Cota E.

Re: [Qemu-devel] [PATCH v4 2/4] vhost-user-blk: introduce a new vhost-user-blk host device

2017-10-23 Thread Stefan Hajnoczi
On Mon, Oct 23, 2017 at 04:26:36AM +, Liu, Changpeng wrote: > > > > -Original Message- > > From: Stefan Hajnoczi [mailto:stefa...@gmail.com] > > Sent: Friday, October 20, 2017 5:55 PM > > To: Liu, Changpeng > > Cc: qemu-devel@nongnu.org; pbonz...@redhat.com; m...@redhat.com; > > marc

Re: [Qemu-devel] [PATCH v7 18/52] tcg: Remove GET_TCGV_* and MAKE_TCGV_*

2017-10-23 Thread Emilio G. Cota
On Fri, Oct 20, 2017 at 16:19:49 -0700, Richard Henderson wrote: > The GET and MAKE functions weren't really specific enough. > We now have a full compliment of functions that convert exactly s/compliment/complement/ > between temporaries, arguments, tcgv pointers, and indices. > > The target/sp

Re: [Qemu-devel] [PATCH v7 19/52] tcg: Remove TCGV_EQUAL*

2017-10-23 Thread Emilio G. Cota
On Fri, Oct 20, 2017 at 16:19:50 -0700, Richard Henderson wrote: > When we used structures for TCGv_*, we needed a macro in order to > perform a comparison. Now that we use pointers, this is just clutter. > > Signed-off-by: Richard Henderson Reviewed-by: Emilio G. Cota E.

Re: [Qemu-devel] [PATCH v1 2/2] ide: support reporting of rotation rate

2017-10-23 Thread John Snow
On 10/20/2017 05:02 AM, Daniel P. Berrange wrote: > On Fri, Oct 20, 2017 at 10:42:21AM +0200, Kevin Wolf wrote: >> [ Cc: qemu-block ] >> >> Am 04.10.2017 um 13:40 hat Daniel P. Berrange geschrieben: >>> The Linux kernel will query the ATA IDENTITY DEVICE data, word 217 >>> to determine the rotati

Re: [Qemu-devel] host physical address width issues/questions for x86_64

2017-10-23 Thread Prasad Singamsetty
On 10/22/2017 11:37 PM, Peter Xu wrote: On Fri, Oct 20, 2017 at 03:54:21PM -0700, Prasad Singamsetty wrote: On 10/18/2017 8:33 PM, Peter Xu wrote: On Wed, Oct 18, 2017 at 10:19:31AM -0700, Prasad Singamsetty wrote: On 10/16/2017 8:56 PM, Peter Xu wrote: On Mon, Oct 16, 2017 at 10:02:25A

Re: [Qemu-devel] [PATCH v4] NUMA: Enable adding NUMA node implicitly

2017-10-23 Thread no-reply
Hi, This series failed build test on s390x host. Please find the details below. Type: series Message-id: 1508722422-3861-1-git-send-email-douly.f...@cn.fujitsu.com Subject: [Qemu-devel] [PATCH v4] NUMA: Enable adding NUMA node implicitly === TEST SCRIPT BEGIN === #!/bin/bash # Testing script wil

Re: [Qemu-devel] [PATCH v4 1/4] vhost-user: add new vhost user messages to support virtio config space

2017-10-23 Thread Stefan Hajnoczi
On Mon, Oct 23, 2017 at 04:47:00AM +, Liu, Changpeng wrote: > > > > -Original Message- > > From: Stefan Hajnoczi [mailto:stefa...@gmail.com] > > Sent: Friday, October 20, 2017 6:01 PM > > To: Michael S. Tsirkin > > Cc: Liu, Changpeng ; qemu-devel@nongnu.org; > > pbonz...@redhat.com;

Re: [Qemu-devel] QEMU CII Best Practices record

2017-10-23 Thread Stefan Hajnoczi
On Fri, Oct 13, 2017 at 02:25:07PM +0100, Daniel P. Berrange wrote: > Many projects these days are recording progress wrt CII best practices > for FLOOS projects. I filled out a record for QEMU: > > https://bestpractices.coreinfrastructure.org/projects/1309 > > I only looked at the 'Passing' cr

Re: [Qemu-devel] [PATCH v7 21/52] tcg: Use offsets not indices for TCGv_*

2017-10-23 Thread Emilio G. Cota
On Fri, Oct 20, 2017 at 16:19:52 -0700, Richard Henderson wrote: > Using the offset of a temporary, relative to TCGContext, rather than > its index means that we don't use 0. That leaves offset 0 free for > a NULL representation without having to leave index 0 unused. > > Signed-off-by: Richard H

Re: [Qemu-devel] [PATCH v7 22/52] tcg: Use pointers in TCGOp->args

2017-10-23 Thread Emilio G. Cota
On Fri, Oct 20, 2017 at 16:19:53 -0700, Richard Henderson wrote: > This limits the indexing into tcg_ctx.temps to initial > opcode generation time. > > Signed-off-by: Richard Henderson Reviewed-by: Emilio G. Cota E.

Re: [Qemu-devel] [Qemu-block] [PATCH] block: all I/O should be completed before removing throttle timers.

2017-10-23 Thread Stefan Hajnoczi
On Sat, Oct 21, 2017 at 01:34:00PM +0800, Zhengui Li wrote: > From: Zhengui > > In blk_remove_bs, all I/O should be completed before removing throttle > timers. If there has inflight I/O, removing throttle timers here will > cause the inflight I/O never return. > This patch add bdrv_drained_begin

Re: [Qemu-devel] [PATCH v7 24/52] tcg: Add CPUState cflags_next_tb

2017-10-23 Thread Emilio G. Cota
On Fri, Oct 20, 2017 at 16:19:55 -0700, Richard Henderson wrote: > We were generating code during tb_invalidate_phys_page_range, > check_watchpoint, cpu_io_recompile, and (seemingly) discarding > the TB, assuming that it would magically be picked up during > the next iteration through the cpu_exec

Re: [Qemu-devel] [PATCH v7 25/52] tcg: Include CF_COUNT_MASK in CF_HASH_MASK

2017-10-23 Thread Emilio G. Cota
On Fri, Oct 20, 2017 at 16:19:56 -0700, Richard Henderson wrote: > Signed-off-by: Richard Henderson Reviewed-by: Emilio G. Cota E.

Re: [Qemu-devel] QEMU CII Best Practices record

2017-10-23 Thread Peter Maydell
On 13 October 2017 at 14:25, Daniel P. Berrange wrote: > Many projects these days are recording progress wrt CII best practices > for FLOOS projects. I filled out a record for QEMU: > > https://bestpractices.coreinfrastructure.org/projects/1309 > > I only looked at the 'Passing' criteria, not co

Re: [Qemu-devel] [PATCH v7 36/52] tcg: Add CF_LAST_IO + CF_USE_ICOUNT to CF_HASH_MASK

2017-10-23 Thread Emilio G. Cota
On Fri, Oct 20, 2017 at 16:20:07 -0700, Richard Henderson wrote: > These flags are used by target/*/translate.c, > and affect code generation. > > Signed-off-by: Richard Henderson Reviewed-by: Emilio G. Cota E.

Re: [Qemu-devel] [PATCH v7 37/52] tcg: Remove CF_IGNORE_ICOUNT

2017-10-23 Thread Emilio G. Cota
On Fri, Oct 20, 2017 at 16:20:08 -0700, Richard Henderson wrote: > Now that we have curr_cflags, we can include CF_USE_ICOUNT > early and then remove it as necessary. > > Signed-off-by: Richard Henderson Reviewed-by: Emilio G. Cota E.

Re: [Qemu-devel] [PATCH v7 00/52] tcg queued patches

2017-10-23 Thread Emilio G. Cota
On Fri, Oct 20, 2017 at 16:19:31 -0700, Richard Henderson wrote: > A bit silly to keep calling this "tb_lock removal", since it > doesn't quite, and it has accumulated several additional patches. Thanks for doing all this work! I think I went through all of the patches. I also did some testing (t

[Qemu-devel] [PATCH] hw/ide/ahci: Move allwinner code into a separate file

2017-10-23 Thread Thomas Huth
The allwinner code is only needed for the allwinner board (for which we also have a separate CONFIG_ALLWINNER_A10 config switch), so it does not make sense that we compile this for all the other boards that need AHCI, too. Let's move it to a separate file that is only compiled when CONFIG_ALLWINNER

[Qemu-devel] [Bug 1714331] Re: Virtual machines not working anymore on 2.10

2017-10-23 Thread Laszlo Ersek (Red Hat)
See also LP#1725560. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1714331 Title: Virtual machines not working anymore on 2.10 Status in QEMU: New Bug description: Using 2.10, my virtual mach

[Qemu-devel] [Bug 1715700] Re: Windows 7 guest won't boot on qemu 2.10 (works on 2.9)

2017-10-23 Thread Laszlo Ersek (Red Hat)
See also LP#1725560. -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1715700 Title: Windows 7 guest won't boot on qemu 2.10 (works on 2.9) Status in QEMU: Fix Committed Bug description: Qemu ve

[Qemu-devel] [PATCH v2 00/27] Initial i.MX7 support

2017-10-23 Thread Andrey Smirnov
Hi everyone, This v2 of the patch series containing the work that I've done in order to enable support for i.MX7 emulation in QEMU. As the one before last commit in the series states the supported i.MX7 features are: * up to 2 Cortex A9 cores (SMP works with PSCI) * A7 MPCORE (identical

[Qemu-devel] [PATCH v2 02/27] imx_fec: Refactor imx_eth_enable_rx()

2017-10-23 Thread Andrey Smirnov
Refactor imx_eth_enable_rx() to have more meaningfull variable name than 'tmp' and to reduce number of logical negations done. Cc: Peter Maydell Cc: Jason Wang Cc: Philippe Mathieu-Daudé Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Reviewed-by: Peter Maydell Signed-

[Qemu-devel] [PATCH v2 01/27] imx_fec: Do not link to netdev

2017-10-23 Thread Andrey Smirnov
Binding to a particular netdev doesn't seem to belong to this layer and should probably be done as a part of board or SoC specific code. Convert all of the users of this IP block to use qdev_set_nic_properties() instead. Cc: Peter Maydell Cc: Jason Wang Cc: Philippe Mathieu-Daudé Cc: qemu-deve

[Qemu-devel] [PATCH v2 04/27] imx_fec: Use ENET_FTRL to determine truncation length

2017-10-23 Thread Andrey Smirnov
Frame truncation length, TRUNC_FL, is determined by the contents of ENET_FTRL register, so convert the code to use it instead of a hardcoded constant. To avoid the case where TRUNC_FL is greater that ENET_MAX_FRAME_SIZE, increase the value of the latter to its theoretical maximum of 16K. Cc: Pete

<    1   2   3   >