[Qemu-devel] [PATCH] hw/ppc/prep: Remove superfluous call to soundhw_init()

2017-06-08 Thread Thomas Huth
When using the 40p machine, soundhw_init() is currently called twice, one time from vl.c and one time from ibm_40p_init(). The call in ibm_40p_init() was likely just a copy-and-paste from a old version of the prep machine - but there the call to audio_init() (which was the previous name of this fun

Re: [Qemu-devel] [PATCH v3 3/5] xics: setup cpu at realize time

2017-06-08 Thread Greg Kurz
On Fri, 9 Jun 2017 12:24:52 +1000 David Gibson wrote: > On Thu, Jun 08, 2017 at 10:45:30AM +0200, Greg Kurz wrote: > > On Thu, 8 Jun 2017 12:01:12 +1000 > > David Gibson wrote: > > > > > On Wed, Jun 07, 2017 at 07:17:09PM +0200, Greg Kurz wrote: > > > > Until recently, spapr used to allocat

Re: [Qemu-devel] [RFC v2 0/8] VIRTIO-IOMMU device

2017-06-08 Thread Auger Eric
Hi Bharat, On 09/06/2017 08:16, Bharat Bhushan wrote: > Hi Eric, > >> -Original Message- >> From: Eric Auger [mailto:eric.au...@redhat.com] >> Sent: Wednesday, June 07, 2017 9:31 PM >> To: eric.auger@gmail.com; eric.au...@redhat.com; >> peter.mayd...@linaro.org; alex.william...@redhat

Re: [Qemu-devel] [PATCH V6 10/10] docs/colo-proxy.txt: Update colo-proxy usage of net driver with vnet_header

2017-06-08 Thread Jason Wang
On 2017年06月07日 17:55, Zhang Chen wrote: Signed-off-by: Zhang Chen --- docs/colo-proxy.txt | 26 ++ 1 file changed, 26 insertions(+) diff --git a/docs/colo-proxy.txt b/docs/colo-proxy.txt index c4941de..f6a624f 100644 --- a/docs/colo-proxy.txt +++ b/docs/colo-proxy.t

Re: [Qemu-devel] [PATCH v8 02/11] migration: pass MigrationIncomingState* into migration check functions

2017-06-08 Thread Alexey Perevalov
On 06/09/2017 07:10 AM, Peter Xu wrote: On Wed, Jun 07, 2017 at 12:46:29PM +0300, Alexey Perevalov wrote: That tiny refactoring is necessary to be able to set UFFD_FEATURE_THREAD_ID while requesting features, and then to create downtime context in case when kernel supports it. Signed-off-by: Al

Re: [Qemu-devel] [PATCH V6 09/10] net/filter-rewriter.c: Make filter-rewriter support vnet_hdr_len

2017-06-08 Thread Jason Wang
On 2017年06月07日 17:55, Zhang Chen wrote: We add the vnet_hdr_support option for filter-rewriter, default is disable. If you use virtio-net-pci net driver, please enable it. You can use it for example: -object filter-rewriter,id=rew0,netdev=hn0,queue=all,vnet_hdr_support We get the vnet_hdr_len

Re: [Qemu-devel] [PATCH V6 08/10] net/colo-compare.c: Add vnet packet's tcp/udp/icmp compare

2017-06-08 Thread Jason Wang
On 2017年06月07日 17:55, Zhang Chen wrote: COLO-Proxy just focus on packet payload, So we skip vnet header. s/So/so/ Signed-off-by: Zhang Chen --- net/colo-compare.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/net/colo-compare.c b/net/colo-compare.c index e

Re: [Qemu-devel] [RFC v2 0/8] VIRTIO-IOMMU device

2017-06-08 Thread Bharat Bhushan
Hi Eric, > -Original Message- > From: Eric Auger [mailto:eric.au...@redhat.com] > Sent: Wednesday, June 07, 2017 9:31 PM > To: eric.auger@gmail.com; eric.au...@redhat.com; > peter.mayd...@linaro.org; alex.william...@redhat.com; m...@redhat.com; > qemu-...@nongnu.org; qemu-devel@nongnu.

Re: [Qemu-devel] [PATCH V6 04/10] net/net.c: Add vnet_hdr support in SocketReadState

2017-06-08 Thread Jason Wang
On 2017年06月07日 17:55, Zhang Chen wrote: We add a flag to dicide whether net_fill_rstate() to read s/dicide/decide/ and s/to/needs/ the vnet_hdr_len or not. Signed-off-by: Zhang Chen Suggested-by: Jason Wang --- include/net/net.h | 6 +- net/filter-mirror.c | 1 + net/net.c

Re: [Qemu-devel] [PATCH V6 03/10] net/filter-mirror.c: Add new option to enable vnet support for filter-redirector

2017-06-08 Thread Jason Wang
On 2017年06月07日 17:55, Zhang Chen wrote: We add the vnet_hdr_support option for filter-redirector, default is disable. s/disable/disabled/ If you use virtio-net-pci net driver, please enable it. Because colo-compare or other modules needs the vnet_hdr_len to parse packet, so we add this new

Re: [Qemu-devel] [PATCH V6 02/10] net/filter-mirror.c: Make filter mirror support vnet support.

2017-06-08 Thread Jason Wang
On 2017年06月07日 17:55, Zhang Chen wrote: We add the vnet_hdr_support option for filter-mirror, default is disable. s/disable/disabled/ If you use virtio-net-pci net driver, please enable it. You can use it for example: -object filter-mirror,id=m0,netdev=hn0,queue=tx,outdev=mirror0,vnet_hdr_s

Re: [Qemu-devel] [PATCH v8 07/11] migration: add bitmap for copied page

2017-06-08 Thread Peter Xu
On Wed, Jun 07, 2017 at 05:13:00PM +0300, Alexey Perevalov wrote: > On 06/07/2017 12:46 PM, Alexey Perevalov wrote: > >This patch adds ability to track down already copied > >pages, it's necessary for calculation vCPU block time in > >postcopy migration feature, maybe for restore after > >postcopy

Re: [Qemu-devel] [PATCH] timer/aspeed: fix timer enablement when a reload is not set

2017-06-08 Thread Cédric Le Goater
On 06/09/2017 04:26 AM, Andrew Jeffery wrote: > On Tue, 2017-06-06 at 10:55 +0200, Cédric Le Goater wrote: >> When a timer is enabled before a reload value is set, the controller >> waits for a reload value to be set before starting decrementing. This >> fix tries to cover that case by changing the

Re: [Qemu-devel] [PATCH] target/sh4: optimize cross-page and indirect jumps

2017-06-08 Thread Richard Henderson
On 06/07/2017 02:20 PM, Aurelien Jarno wrote: if (ctx->singlestep_enabled) gen_helper_debug(cpu_env); -tcg_gen_exit_tb(0); +tcg_gen_lookup_and_goto_ptr(cpu_pc); That really should be an else for that if, since helper_debug doesn't return. r~

[Qemu-devel] [PATCH v5 6/7] tcg/arm: Try pc-relative addresses for movi

2017-06-08 Thread Richard Henderson
Signed-off-by: Richard Henderson --- tcg/arm/tcg-target.inc.c | 44 +--- 1 file changed, 29 insertions(+), 15 deletions(-) diff --git a/tcg/arm/tcg-target.inc.c b/tcg/arm/tcg-target.inc.c index fce382f..18708b1 100644 --- a/tcg/arm/tcg-target.inc.c +++ b/t

[Qemu-devel] [PATCH v5 1/7] util: add cacheinfo

2017-06-08 Thread Richard Henderson
From: "Emilio G. Cota" Add helpers to gather cache info from the host at init-time. For now, only export the host's I/D cache line sizes, which we will use to improve cache locality to avoid false sharing. Suggested-by: Richard Henderson Suggested-by: Geert Martin Ijewski Tested-by:Geert

[Qemu-devel] [PATCH v5 0/7] tcg: allocate TB structs preceding translate

2017-06-08 Thread Richard Henderson
This is a follow-up to Emilio's patch set. My primary changes to Emilio's patches are to the first patch, in merging the existing implementations from tcg/ppc/tcg-target.inc.c into util/cacheinfo.c. Then I've a few follow-up patches to take advantage of the new TB placement for arm platforms. I'

[Qemu-devel] [PATCH v5 7/7] tcg/arm: Use ldr (literal) for goto_tb

2017-06-08 Thread Richard Henderson
The new placement of the TB means that we can use one insn to load the goto_tb destination directly from the TB. Signed-off-by: Richard Henderson --- tcg/arm/tcg-target.inc.c | 23 ++- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/tcg/arm/tcg-target.inc.c b/t

Re: [Qemu-devel] [PATCH v4 1/6] xics: introduce macros for ICP/ICS link properties

2017-06-08 Thread Cédric Le Goater
On 06/09/2017 04:10 AM, David Gibson wrote: > On Thu, Jun 08, 2017 at 07:26:35PM +0200, Cédric Le Goater wrote: >> On 06/08/2017 07:00 PM, Greg Kurz wrote: >>> On Thu, 8 Jun 2017 18:08:44 +0200 >>> Cédric Le Goater wrote: >>> >>> FWIW, other people do that as well (see hw/i386/pc_q35.c for exa

[Qemu-devel] [PATCH v5 3/7] tcg/aarch64: Use ADR in tcg_out_movi

2017-06-08 Thread Richard Henderson
The new placement of the TB means that we can use one insn to load the return value for exit_tb returning the TB pointer. Tested-by: Emilio G. Cota Signed-off-by: Richard Henderson --- tcg/aarch64/tcg-target.inc.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tcg/aar

[Qemu-devel] [PATCH v5 5/7] tcg/arm: Remove limit on code buffer size

2017-06-08 Thread Richard Henderson
Since we're no longer using a direct branch, we have no limit on the branch distance. Signed-off-by: Richard Henderson --- translate-all.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/translate-all.c b/translate-all.c index bb094ad..966747a 100644 --- a/translate-all.c +++ b/translate-al

[Qemu-devel] [PULL 11/20] spapr: Rework DRC name handling

2017-06-08 Thread David Gibson
DRC objects have a get_name method which returns the DRC name generated when the DRC is created. Replace that with a fixed spapr_drc_name() function which generates the name on the fly from other information. This means: * We get rid of a method with only one implementation, and only local

[Qemu-devel] [PULL 16/20] xics: introduce macros for ICP/ICS link properties

2017-06-08 Thread David Gibson
From: Greg Kurz These properties are part of the XICS API. They deserve to appear explicitely in the XICS header file. Signed-off-by: Greg Kurz Signed-off-by: David Gibson --- hw/intc/xics.c | 8 hw/ppc/pnv_core.c | 3 ++- hw/ppc/pnv_psi.c| 3 ++- hw/ppc/spapr.

[Qemu-devel] [PATCH v5 0/7] tcg: allocate TB structs preceding translate

2017-06-08 Thread Richard Henderson
This is a follow-up to Emilio's patch set. My primary changes to Emilio's patches are to the first patch, in merging the existing implementations from tcg/ppc/tcg-target.inc.c into util/cacheinfo.c. Then I've a few follow-up patches to take advantage of the new TB placement for arm platforms. I'

[Qemu-devel] [PATCH v5 4/7] tcg/arm: Use indirect branch for goto_tb

2017-06-08 Thread Richard Henderson
Signed-off-by: Richard Henderson --- include/exec/exec-all.h | 5 + tcg/arm/tcg-target.inc.c | 17 ++--- 2 files changed, 3 insertions(+), 19 deletions(-) diff --git a/include/exec/exec-all.h b/include/exec/exec-all.h index 87ae10b..724ec73 100644 --- a/include/exec/exec-all.h

[Qemu-devel] [PULL 14/20] hw/ppc/spapr: Adjust firmware name for PCI bridges

2017-06-08 Thread David Gibson
From: Thomas Huth SLOF uses "pci" as name for PCI bridges nodes in the device tree instead of "pci-bridges", so booting via bootindex from a device behind a PCI bridge currently does not work since QEMU passes the wrong name in the "qemu,boot-list" property. Fix it by changing the name of the PCI

[Qemu-devel] [PULL 17/20] xics: pass appropriate types to realize() handlers.

2017-06-08 Thread David Gibson
From: Greg Kurz It makes more sense to pass an IPCState * to handlers of ICPStateClass instead of a DeviceState *, if only to benefit from compile time type checking. The same goes with ICSStateClass. While here, we also change the declaration of ICPStateClass in xics.h for consistency. Signed-

[Qemu-devel] [PATCH 1/3] Guess L1 cache linesize for aarch64

2017-06-08 Thread Richard Henderson
Using the cache hierarchy linesize minimum in CTR_EL0. See the comment within the code for rationale. * sysdeps/unix/sysv/linux/aarch64/sysconf.c: New file. Cc: Marcus Shawcroft --- sysdeps/unix/sysv/linux/aarch64/sysconf.c | 55 +++ 1 file changed, 55 insert

[Qemu-devel] [PATCH v5 2/7] tcg: allocate TB structs before the corresponding translated code

2017-06-08 Thread Richard Henderson
From: "Emilio G. Cota" Allocating an arbitrarily-sized array of tbs results in either (a) a lot of memory wasted or (b) unnecessary flushes of the code cache when we run out of TB structs in the array. An obvious solution would be to just malloc a TB struct when needed, and keep the TB array as

[Qemu-devel] [PULL 18/20] xics: setup cpu at realize time

2017-06-08 Thread David Gibson
From: Greg Kurz Until recently, spapr used to allocate ICPState objects for the lifetime of the machine. They would only be associated to vCPUs in xics_cpu_setup() when plugging a CPU core. Now that ICPState objects have the same lifecycle as vCPUs, it is possible to associate them during realiz

[Qemu-devel] [PULL 13/20] xics: add reset() handler to ICPStateClass

2017-06-08 Thread David Gibson
From: Greg Kurz Taking into account that qemu_set_irq() returns immediatly if its first argument is NULL, icp_kvm_reset() largely duplicates icp_reset(). This patch introduces a reset() handler, so that the common logic can be implemented in icp_reset() only. While there we can also drop icp_kv

[Qemu-devel] [PATCH v5 0/7] tcg: allocate TB structs preceding translate

2017-06-08 Thread Richard Henderson
This is a follow-up to Emilio's patch set. My primary changes to Emilio's patches are to the first patch, in merging the existing implementations from tcg/ppc/tcg-target.inc.c into util/cacheinfo.c. Then I've a few follow-up patches to take advantage of the new TB placement for arm platforms. I'

[Qemu-devel] [PULL 15/20] hw/cpu: core.c can be compiled as common object

2017-06-08 Thread David Gibson
From: Thomas Huth There does not seem to be any target specific code in core.c, so we can put it into "common-obj" instead of "obj" to compile it only once for all targets. Signed-off-by: Thomas Huth Reviewed-by: Juan Quintela Signed-off-by: David Gibson --- hw/cpu/Makefile.objs | 3 +-- 1 f

[Qemu-devel] [PULL 20/20] Revert "spapr: fix memory hot-unplugging"

2017-06-08 Thread David Gibson
From: Laurent Vivier This reverts commit fe6824d12642b005c69123ecf8631f9b13553f8b. Conflicts hw/ppc/spapr_drc.c, because get_index() has been renamed spapr_get_index(). This didn't fix the problem. Once the hotplug has been started some memory is allocated and some structures are allocated. We

[Qemu-devel] [PULL 19/20] xics: drop ICPStateClass::cpu_setup() handler

2017-06-08 Thread David Gibson
From: Greg Kurz The cpu_setup() handler is only implemented by xics_kvm, where it really does a typical "realize" job. Moreover, the realize() handler is called shortly after cpu_setup(), on the same path. This patch converts xics_kvm to implement realize() instead of cpu_setup(). Signed-off-by

[Qemu-devel] [PULL 04/20] pseries: Correct panic behaviour for pseries machine type

2017-06-08 Thread David Gibson
The pseries machine type doesn't usually use the 'pvpanic' device as such, because it has a firmware/hypervisor facility with roughly the same purpose. The 'ibm,os-term' RTAS call notifies the hypervisor that the guest has crashed. Our implementation of this call was sending a GUEST_PANICKED qmp

[Qemu-devel] [PULL 07/20] spapr: Clean up RTAS set-indicator

2017-06-08 Thread David Gibson
In theory the RTAS set-indicator call can be used for a number of "indicators" defined by PAPR. In practice the only ones we're ever likely to implement are those used for Dynamic Reconfiguration (i.e. hotplug). Because of this, the current implementation determines the associated DRC object, befo

[Qemu-devel] [PULL 05/20] spapr: Clean up DR entity sense handling

2017-06-08 Thread David Gibson
DRC classes have an entity_sense method to determine (in a specific PAPR sense) the presence or absence of a device plugged into a DRC. However, we only have one implementation of the method, which explicitly tests for different DRC types. This changes it to instead have different method implemen

[Qemu-devel] [PULL 09/20] spapr: Change DRC attach & detach methods to functions

2017-06-08 Thread David Gibson
DRC objects have attach & detach methods, but there's only one implementation. Although there are some differences in its behaviour for different DRC types, the overall structure is the same, so while we might want different method implementations for some parts, we're unlikely to want them for th

[Qemu-devel] [PULL 01/20] target/ppc: pass const string to kvmppc_is_mem_backend_page_size_ok()

2017-06-08 Thread David Gibson
From: Greg Kurz This function has three implementations. Two are stubs that do nothing and the third one only passes the obj_path argument to: Object *object_resolve_path(const char *path, bool *ambiguous); Signed-off-by: Greg Kurz Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Thomas Huth

[Qemu-devel] [PULL 10/20] spapr: Fold spapr_phb_{add, remove}_pci_device() into their only callers

2017-06-08 Thread David Gibson
Both functions are fairly short, and so are their callers. There's no particular logical distinction between them, so fold them together. Signed-off-by: David Gibson Reviewed-by: Michael Roth Acked-by: Michael Roth --- hw/ppc/spapr_pci.c | 63 --

[Qemu-devel] [PULL 08/20] spapr: Clean up handling of DR-indicator

2017-06-08 Thread David Gibson
There are 3 types of "indicator" associated with hotplug in the PAPR spec the "allocation state", "isolation state" and "DR-indicator". The first two are intimately tied to the various state transitions associated with hotplug. The DR-indicator, however, is different and simpler. It's basically

[Qemu-devel] [PULL 06/20] spapr: Don't misuse DR-indicator in spapr_recover_pending_dimm_state()

2017-06-08 Thread David Gibson
With some combinations of migration and hotplug we can lost temporary state indicating how many DRCs (guest side hotplug handles) are still connected to a DIMM object in the process of removal. When we hit that situation spapr_recover_pending_dimm_state() is used to scan more extensively and work

[Qemu-devel] [PULL 00/20] ppc-for-2.10 queue 20170609

2017-06-08 Thread David Gibson
The following changes since commit 64175afc695c0672876fbbfc31b299c86d562cb4: arm_gicv3: Fix ICC_BPR1 reset value when EL3 not implemented (2017-06-07 17:21:44 +0100) are available in the git repository at: git://github.com/dgibson/qemu.git tags/ppc-for-2.10-20170609 for you to fetch change

[Qemu-devel] [PULL 12/20] pnv_core: drop reference on ICPState object during CPU realization

2017-06-08 Thread David Gibson
From: Greg Kurz Similarly to what was done to spapr with commit 249127d0dfeb, this patch ensures that we don't keep an extra reference on the ICPState object. Also since the object was just created and not reparented yet, the call to object_property_add_child() should never fail: let's pass &erro

[Qemu-devel] [PULL 03/20] spapr: fix memory leak in spapr_memory_pre_plug()

2017-06-08 Thread David Gibson
From: Greg Kurz The string returned by object_property_get_str() is dynamically allocated. (Spotted by Coverity, CID 1375942) Signed-off-by: Greg Kurz Signed-off-by: David Gibson --- hw/ppc/spapr.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/hw/ppc/spapr.c b/hw/pp

[Qemu-devel] [PULL 02/20] target/ppc: fix memory leak in kvmppc_is_mem_backend_page_size_ok()

2017-06-08 Thread David Gibson
From: Greg Kurz The string returned by object_property_get_str() is dynamically allocated. Signed-off-by: Greg Kurz Reviewed-by: Thomas Huth Signed-off-by: David Gibson --- target/ppc/kvm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/target/ppc/kvm.c b/target/ppc/kvm.c index 8881762.

Re: [Qemu-devel] [PATCH v1 1/1] char-socket: Don't report TCP socket waiting as an error

2017-06-08 Thread Markus Armbruster
Alistair Francis writes: > On Thu, Jun 8, 2017 at 10:56 AM, Markus Armbruster wrote: >> Alistair Francis writes: >> >>> On Wed, Jun 7, 2017 at 11:03 PM, Markus Armbruster >>> wrote: Alistair Francis writes: > On Wed, Jun 7, 2017 at 12:19 AM, Markus Armbruster > wrote: >>>

Re: [Qemu-devel] [PATCH RFC] spapr: ignore interrupts during reset state

2017-06-08 Thread Nikunj A Dadhania
David Gibson writes: > On Thu, Jun 08, 2017 at 12:06:08PM +0530, Nikunj A Dadhania wrote: >> Rebooting a SMP TCG guest is broken for both single/multi threaded TCG. > > Ouch. When exactly did this happen? Broken since long > I know that smp boot used to work under TCG, albeit very slowly. SMP

Re: [Qemu-devel] 答复: Re: [PATCHv2 02/04] colo-compare: Process pactkets in the IOThread ofthe primary

2017-06-08 Thread Jason Wang
On 2017年06月08日 17:16, wang.yong...@zte.com.cn wrote: >> From: Wang Yong <wang.yong...@zte.com.cn> >> >> Process pactkets in the IOThread which arrived over the socket. >> we use qio_channel_set_aio_fd_handler to set the handlers on the >> IOThread AioContext.then the packets from the prima

Re: [Qemu-devel] [PATCH v8 02/11] migration: pass MigrationIncomingState* into migration check functions

2017-06-08 Thread Peter Xu
On Wed, Jun 07, 2017 at 12:46:29PM +0300, Alexey Perevalov wrote: > That tiny refactoring is necessary to be able to set > UFFD_FEATURE_THREAD_ID while requesting features, and then > to create downtime context in case when kernel supports it. > > Signed-off-by: Alexey Perevalov > --- > migratio

[Qemu-devel] [PATCH v2 5/6] migration: move skip_configuration out

2017-06-08 Thread Peter Xu
It was in SaveState but now moved to MigrationState altogether. Again, using HW_COMPAT_2_3 for old PC/SPAPR machines, and register_compat_prop() for xen_init(). Signed-off-by: Peter Xu --- hw/i386/pc_piix.c | 1 - hw/ppc/spapr.c| 1 - hw/xen/xen-common.c |

[Qemu-devel] [PATCH v2 6/6] migration: move skip_section_footers

2017-06-08 Thread Peter Xu
Move it into MigrationState, with a property binded to it. Same trick is played like previous patches. Signed-off-by: Peter Xu --- hw/i386/pc_piix.c | 1 - hw/ppc/spapr.c| 1 - hw/xen/xen-common.c | 2 +- include/hw/compat.h | 4 include/m

[Qemu-devel] [PATCH v2 3/6] migration: move global_state.optional out

2017-06-08 Thread Peter Xu
Put it into MigrationState then we can use the properties to specify whether to enable storing global state. Removing global_state_set_optional() since now we can use HW_COMPAT_2_3 for x86/power in general, and the register_compat_prop() for xen_init(). Signed-off-by: Peter Xu --- hw/i386/pc_pi

[Qemu-devel] [PATCH v2 2/6] migration: let MigrationState be a qdev

2017-06-08 Thread Peter Xu
Let the old man "MigrationState" join the object family. Direct benefit is that we can start to use all the property features derived from current QDev, like: HW_COMPAT_* bits, command line setup for migration parameters (so will never need to set them up each time using HMP/QMP, this is really, re

[Qemu-devel] [PATCH v2 4/6] migration: move only_migratable to MigrationState

2017-06-08 Thread Peter Xu
One less global variable, and it does only matter with migration. We keep the old "--only-migratable" option, but also now we support: -global migration.only-migratable=true Currently still keep the old interface. Signed-off-by: Peter Xu --- include/migration/migration.h | 3 +++ include/sy

[Qemu-devel] [PATCH v2 0/6] migration: objectify MigrationState

2017-06-08 Thread Peter Xu
v2 - (I didn't add Juan's r-b since I touched the patches) - remove once parameter in migrate_get_current() since not needed - add one more patch to export register_compat_prop(), then use it in the following patches in xen_init(). I picked this topic out as suggested by Juan. Also I did what Ju

[Qemu-devel] [PATCH v2 1/6] machine: export register_compat_prop()

2017-06-08 Thread Peter Xu
We have HW_COMPAT_*, however that's only binded to machines, not other things (like accelerators). Behind it, it was register_compat_prop() that played the trick. Let's export the function for further use outside HW_COMPAT_* magic. CC: Eduardo Habkost CC: Markus Armbruster CC: Marcel Apfelbaum

Re: [Qemu-devel] [PATCH 0/7] KVM: MMU: fast write protect

2017-06-08 Thread Xiao Guangrong
On 05/30/2017 12:48 AM, Paolo Bonzini wrote: On 23/05/2017 04:23, Xiao Guangrong wrote: Ping... Sorry to disturb, just make this patchset not be missed. :) It won't. :) I'm going to look at it and the dirty page ring buffer this week. Ping.. :)

Re: [Qemu-devel] [PATCH v1] virtio-net: enable configurable tx queue size

2017-06-08 Thread Wei Wang
On 06/09/2017 03:01 AM, Michael S. Tsirkin wrote: On Wed, Jun 07, 2017 at 09:04:29AM +0800, Wei Wang wrote: On 06/05/2017 11:38 PM, Michael S. Tsirkin wrote: On Mon, Jun 05, 2017 at 04:57:29PM +0800, Wei Wang wrote: This patch enables the virtio-net tx queue size to be configurable between 256

Re: [Qemu-devel] [PATCH v4 0/6] spapr/xics: fix migration of older machine types

2017-06-08 Thread David Gibson
On Thu, Jun 08, 2017 at 03:42:32PM +0200, Greg Kurz wrote: > I've provided answers for all comments from the v3 review that I deliberately > don't address in v4. I've merged patches 1-4. 5 & 6 I'm still reviewing. > > v4: - some patches from v3 got merged > - added some more preparatory cle

Re: [Qemu-devel] [PATCH 2/3] exec: simplify address_space_get_iotlb_entry

2017-06-08 Thread David Gibson
On Fri, Jun 09, 2017 at 09:58:47AM +0800, Peter Xu wrote: > On Thu, Jun 08, 2017 at 09:59:50PM +0300, Michael S. Tsirkin wrote: > > On Thu, Jun 08, 2017 at 02:11:50PM +0800, Peter Xu wrote: > > > On Wed, Jun 07, 2017 at 04:07:20PM +0300, Michael S. Tsirkin wrote: > > > > On Wed, Jun 07, 2017 at 11:

Re: [Qemu-devel] [PATCH v3 3/5] xics: setup cpu at realize time

2017-06-08 Thread David Gibson
On Thu, Jun 08, 2017 at 10:45:30AM +0200, Greg Kurz wrote: > On Thu, 8 Jun 2017 12:01:12 +1000 > David Gibson wrote: > > > On Wed, Jun 07, 2017 at 07:17:09PM +0200, Greg Kurz wrote: > > > Until recently, spapr used to allocate ICPState objects for the lifetime > > > of the machine. They would onl

Re: [Qemu-devel] [PATCH RFC] spapr: ignore interrupts during reset state

2017-06-08 Thread David Gibson
On Thu, Jun 08, 2017 at 12:06:08PM +0530, Nikunj A Dadhania wrote: > Rebooting a SMP TCG guest is broken for both single/multi threaded TCG. Ouch. When exactly did this happen? I know that smp boot used to work under TCG, albeit very slowly. > When reset happens, all the CPUs are in halted stat

Re: [Qemu-devel] [PATCH v4 1/6] xics: introduce macros for ICP/ICS link properties

2017-06-08 Thread David Gibson
On Thu, Jun 08, 2017 at 07:26:35PM +0200, Cédric Le Goater wrote: > On 06/08/2017 07:00 PM, Greg Kurz wrote: > > On Thu, 8 Jun 2017 18:08:44 +0200 > > Cédric Le Goater wrote: > > > > FWIW, other people do that as well (see hw/i386/pc_q35.c for example). > > > > well, I don'

Re: [Qemu-devel] [PATCH] hw/cpu: core.c can be compiled as common object

2017-06-08 Thread David Gibson
On Thu, Jun 08, 2017 at 04:23:34PM +0200, Juan Quintela wrote: > Thomas Huth wrote: > > There does not seem to be any target specific code in core.c, so we can > > put it into "common-obj" instead of "obj" to compile it only once for > > all targets. > > > > Signed-off-by: Thomas Huth > > It com

Re: [Qemu-devel] [PATCH v2 2/2] Revert "spapr: fix memory hot-unplugging"

2017-06-08 Thread David Gibson
On Thu, Jun 08, 2017 at 07:27:43PM +0200, Laurent Vivier wrote: > This reverts commit fe6824d12642b005c69123ecf8631f9b13553f8b. > > Conflicts hw/ppc/spapr_drc.c, because get_index() has been renamed > spapr_get_index(). > > This didn't fix the problem. Once the hotplug has been started > some mem

[Qemu-devel] [PATCH v8 6/7] trace: [tcg, trivial] Re-align generated code

2017-06-08 Thread Emilio G. Cota
From: Lluís Vilanova Last patch removed a nesting level in generated code. Re-align all code generated by backends to be 4-column aligned. Signed-off-by: Lluís Vilanova Signed-off-by: Emilio G. Cota --- scripts/tracetool/backend/dtrace.py | 4 ++-- scripts/tracetool/backend/ftrace.py | 20 ++

[Qemu-devel] [PATCH v8 1/7] exec: [tcg] Refactor flush of per-CPU virtual TB cache

2017-06-08 Thread Emilio G. Cota
From: Lluís Vilanova The function is reused in later patches. Signed-off-by: Lluís Vilanova Reviewed-by: Richard Henderson Signed-off-by: Emilio G. Cota --- cputlb.c| 2 +- include/exec/exec-all.h | 6 ++ translate-all.c | 15 ++- 3 files changed, 17

Re: [Qemu-devel] [PATCH] Add manpage for QEMU Backup Tool

2017-06-08 Thread no-reply
Hi, This series seems to have some coding style problems. See output below for more information: Subject: [Qemu-devel] [PATCH] Add manpage for QEMU Backup Tool Message-id: 1496957498-17127-1-git-send-email-chugh.ish...@research.iiit.ac.in Type: series === TEST SCRIPT BEGIN === #!/bin/bash BASE=

[Qemu-devel] [PATCH v8 0/7] trace: [tcg] Optimize per-vCPU tracing states

2017-06-08 Thread Emilio G. Cota
This is my own respin of Lluís' v7: https://lists.gnu.org/archive/html/qemu-devel/2017-01/msg02741.html Changes from v7: - Ported to current dev tree. - Allocate cpu->trace_dstate statically. This * allows us to drop the event_count inline patch. * simplifies and improves the performance o

Re: [Qemu-devel] [PATCH] timer/aspeed: fix timer enablement when a reload is not set

2017-06-08 Thread Andrew Jeffery
On Tue, 2017-06-06 at 10:55 +0200, Cédric Le Goater wrote: > When a timer is enabled before a reload value is set, the controller > waits for a reload value to be set before starting decrementing. This > fix tries to cover that case by changing the timer expiry only when > a reload value is valid.

[Qemu-devel] [PATCH v8 2/7] cpu: allocate cpu->trace_dstate in place

2017-06-08 Thread Emilio G. Cota
There's little point in dynamically allocating the bitmap if we know at compile-time the max number of events we want to support. Thus, make room in the struct for the bitmap, which will make things easier later: this paves the way for upcoming changes, in which we'll use a u32 to fully capture cpu

[Qemu-devel] [PATCH v8 5/7] trace: [tcg] Do not generate TCG code to trace dinamically-disabled events

2017-06-08 Thread Emilio G. Cota
From: Lluís Vilanova If an event is dynamically disabled, the TCG code that calls the execution-time tracer is not generated. Removes the overheads of execution-time tracers for dynamically disabled events. As a bonus, also avoids checking the event state when the execution-time tracer is called

[Qemu-devel] [PATCH v8 4/7] exec: [tcg] Use different TBs according to the vCPU's dynamic tracing state

2017-06-08 Thread Emilio G. Cota
From: Lluís Vilanova Every vCPU now uses a separate set of TBs for each set of dynamic tracing event state values. Each set of TBs can be used by any number of vCPUs to maximize TB reuse when vCPUs have the same tracing state. This feature is later used by tracetool to optimize tracing of guest

[Qemu-devel] [PATCH v8 7/7] trace: [trivial] Statically enable all guest events

2017-06-08 Thread Emilio G. Cota
From: Lluís Vilanova The optimizations of this series makes it feasible to have them available on all builds. Signed-off-by: Lluís Vilanova Signed-off-by: Emilio G. Cota --- trace-events | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/trace-events b/trace-events inde

[Qemu-devel] [PATCH v8 3/7] trace: [tcg] Delay changes to dynamic state when translating

2017-06-08 Thread Emilio G. Cota
From: Lluís Vilanova This keeps consistency across all decisions taken during translation when the dynamic state of a vCPU is changed in the middle of translating some guest code. Signed-off-by: Lluís Vilanova Reviewed-by: Richard Henderson [cota: use CPU_TRACE_DSTATE_MAX_EVENTS instead of tra

[Qemu-devel] [PATCH] Add manpage for QEMU Backup Tool

2017-06-08 Thread Ishani Chugh
Signed-off-by: Ishani Chugh --- Makefile| 2 +- contrib/backup/qemu-backup.texi | 147 2 files changed, 148 insertions(+), 1 deletion(-) create mode 100644 contrib/backup/qemu-backup.texi diff --git a/Makefile b/Makefile index c

Re: [Qemu-devel] [PATCH 2/3] exec: simplify address_space_get_iotlb_entry

2017-06-08 Thread Peter Xu
On Thu, Jun 08, 2017 at 09:59:50PM +0300, Michael S. Tsirkin wrote: > On Thu, Jun 08, 2017 at 02:11:50PM +0800, Peter Xu wrote: > > On Wed, Jun 07, 2017 at 04:07:20PM +0300, Michael S. Tsirkin wrote: > > > On Wed, Jun 07, 2017 at 11:44:43AM +0800, Peter Xu wrote: > > > > On Wed, Jun 07, 2017 at 09:

Re: [Qemu-devel] [RFC v5 2/4] hw/intc/arm_gicv3_its: Implement state save/restore

2017-06-08 Thread Shannon Zhao
On 2017/4/14 20:46, Eric Auger wrote: [...] > @@ -43,6 +50,7 @@ struct GICv3ITSState { > > /* Registers */ > uint32_t ctlr; > +uint32_t iidr; I think this should reset in gicv3_its_common_reset Thanks, -- Shannon

Re: [Qemu-devel] [PATCH] q35/mch: implement extended TSEG sizes

2017-06-08 Thread Michael S. Tsirkin
On Fri, Jun 09, 2017 at 01:01:54AM +0200, Laszlo Ersek wrote: > On 06/08/17 21:55, Michael S. Tsirkin wrote: > > On Thu, Jun 08, 2017 at 09:48:53PM +0200, Gerd Hoffmann wrote: > >> Hi, > >> > >>> I really dislike negotiation being re-invented for each device. Do > >>> we > >>> need these tricks?

Re: [Qemu-devel] [PATCH qemu v7] memory/iommu: QOM'fy IOMMU MemoryRegion

2017-06-08 Thread David Gibson
On Thu, Jun 08, 2017 at 05:30:57PM +0200, Paolo Bonzini wrote: 1;4602;0c> > > On 08/06/2017 16:58, David Gibson wrote: > > So, doing that via the standard macro wrappers would be slow, because > > it does type verification. However, looking up the class function is > > fundamentally: > > > >

[Qemu-devel] [PATCH v2] block: change variable names in BlockDriverState

2017-06-08 Thread Manos Pitsidianakis
Change the 'int count' parameter in *pwrite_zeros, *pdiscard related functions (and some others) to 'int bytes', as they both refer to bytes. This helps with code legibility. Signed-off-by: Manos Pitsidianakis --- block/blkdebug.c | 36 +++ block/blkrepl

Re: [Qemu-devel] [PATCH] q35/mch: implement extended TSEG sizes

2017-06-08 Thread Laszlo Ersek
On 06/08/17 21:55, Michael S. Tsirkin wrote: > On Thu, Jun 08, 2017 at 09:48:53PM +0200, Gerd Hoffmann wrote: >> Hi, >> >>> I really dislike negotiation being re-invented for each device. Do >>> we >>> need these tricks? Can we just do fw cfg with standard discovery? >>> This ties in with my pr

Re: [Qemu-devel] [PATCH 2/4] xenfb: Activate mouse handler

2017-06-08 Thread Stefano Stabellini
On Thu, 8 Jun 2017, Owen Smith wrote: > Mouse events are only delivered to the first handler in the chain. > Activating the xenfb mouse event handler so that mouse events can > be passed over the shared ring protocol. > Note: The keyboard handler is activated internally by the add > call. I am not

Re: [Qemu-devel] [PATCH 1/4] xenfb: Add feature-vkbd-standalone

2017-06-08 Thread Stefano Stabellini
On Thu, 8 Jun 2017, Owen Smith wrote: > Advertise "feature-vkbd-standalone" to indicate the backend > can connect without a vfb device connection. > When "request-vkbd-standalone" is set to 1, the backend does > not wait for a QemuConsole to be setup before connecting the > vkbd device. This also

[Qemu-devel] [PATCH] nbd: Fix regression on resiliency to port scan

2017-06-08 Thread Eric Blake
Back in qemu 2.5, qemu-nbd was immune to port probes (a transient server would not quit, regardless of how many probe connections came and went, until a connection actually negotiated). But we broke that in commit ee7d7aa when removing the return value to nbd_client_new(), although that patch also

Re: [Qemu-devel] [PATCH 0/4] xenfb: Add vkbd-only option

2017-06-08 Thread Stefano Stabellini
On Thu, 8 Jun 2017, Owen Smith wrote: > Adds the ability for a vkbd device to connect without the > QemuConsole, in order to support a standalone PV mouse and > keyboard frontend. > This series adds a new feature flag, which will need adding > to the xen's include/public/io/kbdif.h Please do so, I

Re: [Qemu-devel] [PATCH 5/5] vnc: No need for Error** parameter at vnc_client_io_error()

2017-06-08 Thread Eric Blake
On 06/08/2017 12:44 PM, Eduardo Habkost wrote: -ssize_t vnc_client_io_error(VncState *vs, ssize_t ret, Error **errp) +ssize_t vnc_client_io_error(VncState *vs, ssize_t ret, Error *err) { >>> >>> This is unusual. >> >> Why? I would say that using Error** for input (and not output)

Re: [Qemu-devel] [PATCH] Remove restriction that prevents bootimg elf64 images

2017-06-08 Thread Anatol Pomozov
+reply-all On Thu, Jun 8, 2017 at 1:41 PM, Adam Lackorzynski wrote: > > On Tue Jun 06, 2017 at 21:41:48 -0700, Anatol Pomozov wrote: >> It is possible to create a 64 bit elf image that has valid multiboot header. >> qemu should be able to boot such images. > > But this 64bit image actually starts

Re: [Qemu-devel] [PATCH] Remove restriction that prevents bootimg elf64 images

2017-06-08 Thread Adam Lackorzynski
On Tue Jun 06, 2017 at 21:41:48 -0700, Anatol Pomozov wrote: > It is possible to create a 64 bit elf image that has valid multiboot header. > qemu should be able to boot such images. But this 64bit image actually starts with 32bit code, right? So it's a 32bit program and the check verifies that t

Re: [Qemu-devel] [PATCH v4 0/7] tcg: allocate TB structs preceding translate

2017-06-08 Thread Richard Henderson
On 06/08/2017 10:44 AM, Emilio G. Cota wrote: On Thu, Jun 08, 2017 at 09:44:11 -0700, Richard Henderson wrote: On 06/07/2017 04:30 PM, Emilio G. Cota wrote: On Wed, Jun 07, 2017 at 08:55:29 -0700, Richard Henderson wrote: Then I've a few follow-up patches to take advantage of the new TB placem

Re: [Qemu-devel] [PATCH 5/5] coccinelle: prefer glib g_new/g_renew macros

2017-06-08 Thread Eric Blake
On 06/08/2017 03:50 AM, Markus Armbruster wrote: >>> Your script differs from Markus', we should figure out if they can be >>> merged into one. >> >> One notable difference is that I abuse expression, instead of type. I didn't >> manage to teach spatch about the includes and custom type (--all-inc

Re: [Qemu-devel] [PATCH 5/5] coccinelle: prefer glib g_new/g_renew macros

2017-06-08 Thread Eric Blake
On 06/08/2017 03:23 AM, Marc-André Lureau wrote: >> >> Your script differs from Markus', we should figure out if they can be >> merged into one. > > One notable difference is that I abuse expression, instead of type. I didn't > manage to teach spatch about the includes and custom type (--all-incl

Re: [Qemu-devel] [PATCH] spapr: manage hotplugged devices while the VM is not started

2017-06-08 Thread Michael Roth
Quoting David Gibson (2017-05-30 23:35:57) > On Tue, May 30, 2017 at 06:04:45PM +0200, Laurent Vivier wrote: > > For QEMU, a hotlugged device is a device added using the HMP/QMP > > interface. > > For SPAPR, a hotplugged device is a device added while the > > machine is running. In this case QEMU d

Re: [Qemu-devel] [PATCH v1 1/1] char-socket: Don't report TCP socket waiting as an error

2017-06-08 Thread Alistair Francis
On Thu, Jun 8, 2017 at 10:56 AM, Markus Armbruster wrote: > Alistair Francis writes: > >> On Wed, Jun 7, 2017 at 11:03 PM, Markus Armbruster wrote: >>> Alistair Francis writes: >>> On Wed, Jun 7, 2017 at 12:19 AM, Markus Armbruster wrote: > Paolo Bonzini writes: > >> On

Re: [Qemu-devel] [PATCH] q35/mch: implement extended TSEG sizes

2017-06-08 Thread Michael S. Tsirkin
On Thu, Jun 08, 2017 at 09:48:53PM +0200, Gerd Hoffmann wrote: > Hi, > > > I really dislike negotiation being re-invented for each device.  Do > > we > > need these tricks?  Can we just do fw cfg with standard discovery? > > This ties in with my proposal to generalize smi features to > > generic

Re: [Qemu-devel] [PATCH] q35/mch: implement extended TSEG sizes

2017-06-08 Thread Gerd Hoffmann
Hi, > I really dislike negotiation being re-invented for each device.  Do > we > need these tricks?  Can we just do fw cfg with standard discovery? > This ties in with my proposal to generalize smi features to > generic ones. Device properties should be part of the device. We should have done t

[Qemu-devel] [PATCH RFC v19 11/13] target-avr: Put all translation code into one compilation unit

2017-06-08 Thread Michael Rolnik
From: Michael Rolnik From: Richard Henderson Signed-off-by: Richard Henderson --- target/avr/Makefile.objs| 2 - target/avr/decode.c | 6 +- target/avr/translate-inst.c | 198 ++-- target/avr/translate-inst.h | 113 --

[Qemu-devel] [PATCH RFC v19 10/13] target-avr: Put env pointer in DisasContext

2017-06-08 Thread Michael Rolnik
From: Michael Rolnik From: Richard Henderson Signed-off-by: Richard Henderson --- target/avr/translate-inst.c | 298 ++-- target/avr/translate-inst.h | 194 ++-- target/avr/translate.c | 16 +-- target/avr/translate.h

  1   2   3   4   >