Re: [Qemu-devel] [PATCH v4 4/9] Add virt-v3 machine that uses GIC-500

2015-07-02 Thread Pavel Fedin
Hi! > I think you should leave out the software emulation part for this > series and let's concentrate on getting this in first. Ok. > Also, you should make sure you have an agreement with Shlomo about > taking over his patches before doing so (maybe you are already?). Shlomo has posted his

Re: [Qemu-devel] [PATCH v3 00/16] Add an IPMI device to QEMU

2015-07-02 Thread Paolo Bonzini
On 09/06/2015 03:11, miny...@acm.org wrote: > I have reworked the QEMU IPMI patches, and I believe this design > improves greatly on the previous one. The suggestions made all > resulted in better design. To start an IPMI interface > with this, you would use: > > -device ipmi-bmc-sim,id=bmc0

Re: [Qemu-devel] [PATCH 02/18] virtio: run drivers in 32bit mode

2015-07-02 Thread Paolo Bonzini
On 29/06/2015 10:53, Gerd Hoffmann wrote: > virtio version 1.0 registers can (and actually do in the qemu > implementation) live in mmio space. So we must run the blk and > scsi virtio drivers in 32bit mode, otherwise we can't access them. > > This also allows to drop a bunch of GET_LOWFLAT cal

[Qemu-devel] quorum: validate vote threshold against num_children even if read-pattern is fifo

2015-07-02 Thread Wen Congyang
We need to use threshold to check if too many write operation fails. If threshold is larger than num children, we always get write error event even if all write operations success. Signed-off-by: Wen Congyang --- block/quorum.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-)

Re: [Qemu-devel] [PATCH 4/4] spapr: SPLPAR Characteristics

2015-07-02 Thread Bharata B Rao
On Fri, Jul 3, 2015 at 9:12 AM, Sam Bobroff wrote: > Improve the SPLPAR Characteristics information: > > Add MaxPlatProcs: set to max_cpus, the maximum CPUs that could be > addded to the system. > Add DesMem: set to the initial memory of the system. > Add DesProcs: set to smp_cpus,

Re: [Qemu-devel] [Qemu-ppc] [PATCH v3 0/4] target-ppc: Add FWNMI support in qemu for powerKVM guests

2015-07-02 Thread David Gibson
On Thu, Jul 02, 2015 at 07:11:52PM +1000, Alexey Kardashevskiy wrote: > On 04/02/2015 03:46 PM, David Gibson wrote: > >On Thu, Apr 02, 2015 at 03:28:11PM +1100, Alexey Kardashevskiy wrote: > >>On 11/19/2014 04:48 PM, Aravinda Prasad wrote: > >>> > >>> > >>>On Tuesday 11 November 2014 08:54 AM, Davi

[Qemu-devel] [PATCH] axienet: Flush queued packets when rx is done

2015-07-02 Thread Fam Zheng
eth_can_rx checks s->rxsize and returns false if it is non-zero. Because of the .can_receive semantics change, this will make the incoming queue disabled by peer, until it is explicitly flushed. So we should flush it when s->rxsize is becoming zero. Do it by adding a BH that calls qemu_flush_queue

Re: [Qemu-devel] [PATCH] virtio-net: Drop net_virtio_info.can_receive

2015-07-02 Thread Fam Zheng
On Fri, 07/03 09:12, Fam Zheng wrote: > On Thu, 07/02 18:46, Michael S. Tsirkin wrote: > > On Thu, Jul 02, 2015 at 01:46:26PM +0100, Stefan Hajnoczi wrote: > > > On Tue, Jun 30, 2015 at 04:35:24PM +0800, Jason Wang wrote: > > > > On 06/30/2015 11:06 AM, Fam Zheng wrote: > > > > > virtio_net_receive

[Qemu-devel] [PATCH 2/4] spapr: Add /rtas/ibm,change-msix-capable

2015-07-02 Thread Sam Bobroff
QEMU is MSI-X capable and makes it available via ibm,change-msi, so we should indicate this by adding /rtas/ibm,change-msix-capable to the device tree. This is specificed by PAPR. Signed-off-by: Sam Bobroff --- hw/ppc/spapr.c | 4 1 file changed, 4 insertions(+) diff --git a/hw/ppc/spapr.

[Qemu-devel] [PATCH 4/4] spapr: SPLPAR Characteristics

2015-07-02 Thread Sam Bobroff
Improve the SPLPAR Characteristics information: Add MaxPlatProcs: set to max_cpus, the maximum CPUs that could be addded to the system. Add DesMem: set to the initial memory of the system. Add DesProcs: set to smp_cpus, the inital number of CPUs in the system. These tokens and

[Qemu-devel] [PATCH 0/4] spapr: Small PAPR compliance fixes

2015-07-02 Thread Sam Bobroff
This patch set contains several small fixes to make QEMU more PAPR compliant. Sam Bobroff (4): spapr: Add /ibm,partition-name spapr: Add /rtas/ibm,change-msix-capable spapr: Make ibm,change-msi respect 3 return values spapr: SPLPAR Characteristics hw/ppc/spapr.c | 9 + hw

[Qemu-devel] [PATCH 1/4] spapr: Add /ibm,partition-name

2015-07-02 Thread Sam Bobroff
QEMU has a notion of the guest name, so if it's present we might as well put that into the device tree as /ibm,partition-name. This is specificed by PAPR. Signed-off-by: Sam Bobroff --- hw/ppc/spapr.c | 5 + 1 file changed, 5 insertions(+) diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index

[Qemu-devel] [PATCH 3/4] spapr: Make ibm, change-msi respect 3 return values

2015-07-02 Thread Sam Bobroff
Currently, rtas_ibm_change_msi() always returns four values even if less are specified. Correct this by only returning the fourth parameter if it was requested. This is specified by PAPR. Signed-off-by: Sam Bobroff --- hw/ppc/spapr_pci.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)

Re: [Qemu-devel] [v8][RESEND][PATCH 00/10] xen: add Intel IGD passthrough

2015-07-02 Thread Chen, Tiejun
On 2015/7/2 0:03, Stefano Stabellini wrote: Aside from a couple of really minor stylistic issues, I think the patch Thanks for your review. series can go in from my point of view. However it looks like you are still missing a few acked-by/reviewed-by on the non-xen patches. Just yesterday M

[Qemu-devel] [Bug 1469946] Re: guest can't get IP when create guest with bridge.

2015-07-02 Thread chao zhou
Since commit 6e99c63 "net/socket: Drop net_socket_can_send" and friends, net queues need to be explicitly flushed after qemu_can_send_packet() returns false, because the netdev side will disable the polling of fd. This fixes the case of "cont" after "stop" (or migration), i.e. vm_running changes t

Re: [Qemu-devel] [v8][RESEND][PATCH 09/10] xen, gfx passthrough: register host bridge specific to passthrough

2015-07-02 Thread Chen, Tiejun
>> #ifdef CONFIG_XEN +static void igd_passthrough_pc_init_pci(MachineState *machine) +{ +pc_init1(machine, + TYPE_I440FX_PCI_HOST_BRIDGE, + TYPE_IGD_PASSTHROUGH_I440FX_PCI_DEVICE); +} + +static void pc_init_pci(MachineState *machine) +{ +pc_init1(machine, +

Re: [Qemu-devel] [PULL 23/27] migration: create migration event

2015-07-02 Thread Wen Congyang
On 07/03/2015 12:10 AM, Juan Quintela wrote: > We have one argument that tells us what event has happened. This patch brokes 'make check' Thanks Wen Congyang > > Signed-off-by: Juan Quintela > Reviewed-by: Eric Blake > --- > docs/qmp/qmp-events.txt | 14 ++ > migration/migration.

Re: [Qemu-devel] [v8][RESEND][PATCH 08/10] xen, gfx passthrough: register a isa bridge

2015-07-02 Thread Chen, Tiejun
+static void +xen_igd_passthrough_isa_bridge_create(XenPCIPassthroughState *s, + XenHostPCIDevice *dev) +{ +uint16_t gpu_dev_id; +PCIDevice *d = &s->dev; + +if (!is_igd_vga_passthrough(dev)) { +return; +} I would rather move the if int

Re: [Qemu-devel] [PATCH] virtio-net: Drop net_virtio_info.can_receive

2015-07-02 Thread Fam Zheng
On Thu, 07/02 18:46, Michael S. Tsirkin wrote: > On Thu, Jul 02, 2015 at 01:46:26PM +0100, Stefan Hajnoczi wrote: > > On Tue, Jun 30, 2015 at 04:35:24PM +0800, Jason Wang wrote: > > > On 06/30/2015 11:06 AM, Fam Zheng wrote: > > > > virtio_net_receive still does the check by calling > > > > virtio_

Re: [Qemu-devel] [PATCH COLO-BLOCK v7 00/17] Block replication for continuous checkpoints

2015-07-02 Thread Wen Congyang
On 07/02/2015 10:47 PM, Michael R. Hines wrote: > Is this up to date: > > On 06/29/2015 10:34 PM, Wen Congyang wrote: >> Block replication is a very important feature which is used for >> continuous checkpoints(for example: COLO). >> >> Usage: >> Please refer to docs/block-replication.txt >> >> Yo

Re: [Qemu-devel] [PATCH COLO-BLOCK v7 00/17] Block replication for continuous checkpoints

2015-07-02 Thread Wen Congyang
On 07/02/2015 10:59 PM, Michael R. Hines wrote: > On 06/29/2015 10:34 PM, Wen Congyang wrote: >> Block replication is a very important feature which is used for >> continuous checkpoints(for example: COLO). >> >> Usage: >> Please refer to docs/block-replication.txt >> >> You can get the patch here:

[Qemu-devel] [PATCH v2] ne2000: Drop ne2000_can_receive

2015-07-02 Thread Fam Zheng
This moves the behavior of ne2000_can_receive to ne2000_receive. The logic is when the NIC is stopped we drop the packet, when the buffer is full we queue it and try flush later. ne2000_buffer_full is determined by s->curpag, s->boundary, s->start and s->stop. Add a flush in ne2000_ioport_write as

Re: [Qemu-devel] [PATCH COLO-BLOCK v7 02/17] quorum: implement block driver interfaces add/delete a BDS's child

2015-07-02 Thread Wen Congyang
On 07/02/2015 11:21 PM, Alberto Garcia wrote: > On Thu 02 Jul 2015 04:30:50 PM CEST, Wen Congyang wrote: > >>> 2) Did you think of any API to update vote_threshold? Currently it >>> cannot be higher than num_children, so it's effectively limited by >>> the number of children that are attac

Re: [Qemu-devel] [PATCH v2] raw-posix.c: remove raw device access for cdrom

2015-07-02 Thread Programmingkid
Allows QEMU running on Mac OS X guest to use the real CD-ROM drive. This patch doesn't actually remove raw device access. I'm just using the same name as the last patch. Why should we test for /dev/disk1s0 when /dev/rdisk1s0 works? By avoiding using the raw device we gain speed. When a read takes

Re: [Qemu-devel] [PATCH for-2.4] net-hub: Drop can_receive

2015-07-02 Thread Fam Zheng
On Thu, 07/02 14:30, Stefan Hajnoczi wrote: > On Tue, Jun 30, 2015 at 10:29:20AM +0800, Fam Zheng wrote: > > It returns true as long as there is another attached port. This is not > > strictly necessary because even if there is only one port (the sender), > > net_hub_port_receive could succeed with

Re: [Qemu-devel] [PATCH v3 00/16] Add an IPMI device to QEMU

2015-07-02 Thread Benjamin Herrenschmidt
On Mon, 2015-06-08 at 20:11 -0500, miny...@acm.org wrote: > I have reworked the QEMU IPMI patches, and I believe this design > improves greatly on the previous one. The suggestions made all > resulted in better design. To start an IPMI interface > with this, you would use: > > -device ipmi-bmc

Re: [Qemu-devel] [PATCH] raw-posix.c: remove raw device access for cdrom

2015-07-02 Thread Programmingkid
On Jul 2, 2015, at 10:33 AM, Laurent Vivier wrote: > > > On 02/07/2015 16:20, Paolo Bonzini wrote: >> >> >> On 02/07/2015 16:18, Laurent Vivier wrote: > I'm okay with doing the simple thing, but it needs a comment for > non-BSDers. >>> So, what we have to do, in our case, for MacOS X

[Qemu-devel] [PATCH 2/3] arm_mptimer: Fix ONE-SHOT -> PERIODIC mode change

2015-07-02 Thread Dmitry Osipenko
Timer won't start periodic ticking if ONE-SHOT -> PERIODIC mode change happened after one-shot tick was completed. Fix it by starting ticking only if timer was disabled previously and isn't ticking right now. Signed-off-by: Dmitry Osipenko --- hw/timer/arm_mptimer.c | 9 +++-- 1 file changed

[Qemu-devel] [PATCH 3/3] arm_mptimer: Respect IT bit state

2015-07-02 Thread Dmitry Osipenko
Timer fires interrupt regardless of current IT(interrupt enable) bit state. Fix it by making timer to respect IT state. Signed-off-by: Dmitry Osipenko --- hw/timer/arm_mptimer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/timer/arm_mptimer.c b/hw/timer/arm_mptimer.c in

[Qemu-devel] arm_mptimer fixes

2015-07-02 Thread Dmitry Osipenko
Hello, this series fixes 3 arm_mptimer issues. All 3 patches were successfully tested on ARM Cortex-A9 QEMU machine booting Linux kernel and behavior was compared to real hw by running couple handcrafted mptimer tests. arm_mptimer: Fix timer shutdown arm_mptimer: Fix ONE-SHOT -> PERIODIC mode chan

[Qemu-devel] [PATCH 1/3 v3] arm_mptimer: Fix timer shutdown

2015-07-02 Thread Dmitry Osipenko
Timer, running in periodic mode, can't be stopped or coming one-shot tick won't be canceled because timer control code just doesn't handle timer disabling. Fix it by deleting timer if enable bit isn't set. Signed-off-by: Dmitry Osipenko --- v2: Avoid calling timer_del() if the timer was already

[Qemu-devel] [PATCH] target-ppc: fix hugepage support when using memory-backend-file

2015-07-02 Thread Michael Roth
Current PPC code relies on -mem-path being used in order for hugepage support to be detected. With the introduction of MemoryBackendFile we can now handle this via: -object memory-file-backend,mem-path=...,id=hugemem0 \ -numa node,id=mem0,memdev=hugemem0 Management tools like libvirt treat the

[Qemu-devel] [PATCH v1 02/10] xen/pt: Sync up the dev.config and data values.

2015-07-02 Thread Konrad Rzeszutek Wilk
For a passthrough device we maintain a state of emulated registers value contained within d->config. We also consult the host registers (and apply ro and write masks) whenever the guest access the registers. This is done in xen_pt_pci_write_config and xen_pt_pci_read_config. Also in this picture w

[Qemu-devel] [PATCH v1 07/10] xen/pt: Log xen_host_pci_get/set errors in MSI code.

2015-07-02 Thread Konrad Rzeszutek Wilk
We seem to only use these functions when de-activating the MSI - so just log errors. Reviewed-by: Stefano Stabellini Signed-off-by: Konrad Rzeszutek Wilk --- hw/xen/xen_pt_msi.c | 18 ++ 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/hw/xen/xen_pt_msi.c b/hw/xen/

[Qemu-devel] [PATCH v1 05/10] xen/pt: Remove XenPTReg->data field.

2015-07-02 Thread Konrad Rzeszutek Wilk
We do not want to have two entries to cache the guest configuration registers: XenPTReg->data and dev.config. Instead we want to use only the dev.config. To do without much complications we rip out the ->data field and replace it with an pointer to the dev.config. This way we have the type-checkin

[Qemu-devel] [PATCH v1 09/10] xen/pt: Move bulk of xen_pt_unregister_device in its own routine.

2015-07-02 Thread Konrad Rzeszutek Wilk
This way we can call it if we fail during init. This code movement introduces no changes. Acked-by: Stefano Stabellini Signed-off-by: Konrad Rzeszutek Wilk --- hw/xen/xen_pt.c | 119 +--- 1 file changed, 62 insertions(+), 57 deletions(-) dif

[Qemu-devel] [PATCH v1 04/10] xen/pt: Use xen_host_pci_get_[byte, word, long] instead of xen_host_pci_get_long

2015-07-02 Thread Konrad Rzeszutek Wilk
Otherwise we get: xen_pt_config_reg_init: Offset 0x0004 mismatch! Emulated=0x, host=0x2300017, syncing to 0x2300014. xen_pt_config_reg_init: Error: Offset 0x0004:0x2300014 expands past register size(2)! which is not surprising. We read the value as an 32-bit (from host), then operate it as

[Qemu-devel] [PATCH v1 03/10] xen/pt: Check if reg->init function sets the 'data' past the reg->size

2015-07-02 Thread Konrad Rzeszutek Wilk
It should never happen, but in case it does (an developer adds a new register and the 'init_val' expands past the register size) we want to report. The code will only write up to reg->size so there is no runtime danger of the register spilling across other ones - however to catch this sort of thing

[Qemu-devel] [PATCH v1 06/10] xen/pt: Log xen_host_pci_get in two init functions

2015-07-02 Thread Konrad Rzeszutek Wilk
To help with troubleshooting in the field. Acked-by: Stefano Stabellini Signed-off-by: Konrad Rzeszutek Wilk --- hw/xen/xen_pt_config_init.c | 9 + 1 file changed, 9 insertions(+) diff --git a/hw/xen/xen_pt_config_init.c b/hw/xen/xen_pt_config_init.c index 0a710a2..a2af415 100644 --- a

[Qemu-devel] [PATCH v1 10/10] xen/pt: Check for return values for xen_host_pci_[get|set] in init

2015-07-02 Thread Konrad Rzeszutek Wilk
and if we have failures we call xen_pt_destroy introduced in 'xen/pt: Move bulk of xen_pt_unregister_device in its own routine.' and free all of the allocated structures. Acked-by: Stefano Stabellini Signed-off-by: Konrad Rzeszutek Wilk --- hw/xen/xen_pt.c | 24 1 file

[Qemu-devel] [PATCH v1 01/10] xen/pt: Use xen_host_pci_get_[byte|word] instead of dev.config

2015-07-02 Thread Konrad Rzeszutek Wilk
During init time we treat the dev.config area as a cache of the host view. However during execution time we treat it as guest view (by the generic PCI API). We need to sync Xen's code to the generic PCI API view. This is the first step by replacing all of the code that uses dev.config or pci_get_[b

[Qemu-devel] [PATCH v1] Remove XenPTReg->data and use dev.config for guest configuration values.

2015-07-02 Thread Konrad Rzeszutek Wilk
Since RFC [https://lists.gnu.org/archive/html/qemu-devel/2015-06/msg07350.html] - Added Acks - Fixed bugs This patchset is dependent on the "Cleanups + various fixes due to libxl ABI + more logging on errors." (http://lists.xen.org/archives/html/xen-devel/2015-07/msg00431.html) just poste

[Qemu-devel] [PATCH v1 08/10] xen/pt: Make xen_pt_unregister_device idempotent

2015-07-02 Thread Konrad Rzeszutek Wilk
To deal with xen_host_pci_[set|get]_ functions returning error values and clearing ourselves in the init function we should make the .exit (xen_pt_unregister_device) function be idempotent in case the generic code starts calling .exit (or for fun does it before calling .init!). Signed-off-by: Konr

[Qemu-devel] [PATCH v1] Cleanups + various fixes due to libxl ABI + more logging on errors.

2015-07-02 Thread Konrad Rzeszutek Wilk
Hey! since RFC [https://lists.gnu.org/archive/html/qemu-devel/2015-06/msg07326.html] - Added Acks - Followed 'xen: Print and use errno where applicable.' suggestion by Stefano and added a wrapper. As I am in the process of syncing the 'dev.config' and Xen's internal cache of the PCI config s

[Qemu-devel] [PATCH v1 4/6] xen: use errno instead of rc for xc_domain_add_to_physmap

2015-07-02 Thread Konrad Rzeszutek Wilk
In Xen 4.6 commit cd2f100f0f61b3f333d52d1737dd73f02daee592 "libxc: Fix do_memory_op to return negative value on errors" made the libxc API less odd-ball: On errors, return value is -1 and error code is in errno. On success the return value is either 0 or an positive value. Since we could be runnin

[Qemu-devel] [PATCH v1 6/6] xen/pt: Use XEN_PT_LOG properly to guard against compiler warnings.

2015-07-02 Thread Konrad Rzeszutek Wilk
If XEN_PT_LOGGING_ENABLED is enabled the XEN_PT_LOG macros start using the first argument. Which means if within the function there is only one user of the argument ('d') and XEN_PT_LOGGING_ENABLED is not set, we get compiler warnings. This is not the case now but with the "xen/pt: Use xen_host_pci

[Qemu-devel] [PATCH v1 2/6] xen/pt: Make xen_pt_msi_set_enable static

2015-07-02 Thread Konrad Rzeszutek Wilk
As we do not use it outside our code. Reviewed-by: Stefano Stabellini Signed-off-by: Konrad Rzeszutek Wilk --- hw/xen/xen_pt.h | 1 - hw/xen/xen_pt_msi.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/hw/xen/xen_pt.h b/hw/xen/xen_pt.h index 393f36c..09358b1 100644 ---

[Qemu-devel] [PATCH v1 1/6] xen/pt: Update comments with proper function name.

2015-07-02 Thread Konrad Rzeszutek Wilk
It has changed but the comments still refer to the old names. Reviewed-by: Stefano Stabellini Signed-off-by: Konrad Rzeszutek Wilk --- hw/xen/xen_pt.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/xen/xen_pt.c b/hw/xen/xen_pt.c index ed5fcae..706e3d9 100644 --- a/hw

[Qemu-devel] [PATCH v1 5/6] xen/pt/msi: Add the register value when printing logging and error messages

2015-07-02 Thread Konrad Rzeszutek Wilk
We would like to know what the MSI register value is to help in troubleshooting in the field. As such modify the logging logic to include such details in xen_pt_msgctrl_reg_write. Signed-off-by: Konrad Rzeszutek Wilk --- hw/xen/xen_pt_config_init.c | 6 +++--- 1 file changed, 3 insertions(+), 3

[Qemu-devel] [PATCH v1 3/6] xen/pt: xen_host_pci_config_read returns -errno, not -1 on failure

2015-07-02 Thread Konrad Rzeszutek Wilk
However the init routines assume that on errors the return code is -1 (as the libxc API is) - while those xen_host_* routines follow another paradigm - negative errno on return, 0 on success. Reviewed-by: Stefano Stabellini Signed-off-by: Konrad Rzeszutek Wilk --- hw/xen/xen_pt.c | 2 +- 1 file

Re: [Qemu-devel] [PATCH v2] thread-win32: fix GetThreadContext() permanently fails

2015-07-02 Thread Zavadovsky Yan
I tested this patch on my 4-cores cpu. Debug and release builds both. Win32 and Win64 binaries both. (I used old Fedora 17-18 with SJLJ mingw-w64 to crossbuild for Win64.) With default Qemu BIOS and with myself-builded OVMF(also debug and release) from EDK2. Also I did some synthetic tests with sa

Re: [Qemu-devel] [PATCH] virtio-pci: implement cfg capability

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 21:00, Michael S. Tsirkin wrote: > On Thu, Jul 02, 2015 at 08:48:14PM +0200, Paolo Bonzini wrote: >> >> >> On 02/07/2015 15:00, Michael S. Tsirkin wrote: >>> +cfg = (void *)(proxy->pci_dev.config + proxy->config_cap); >>> +off = le32_to_cpu(cfg->cap.offset); >>> +

Re: [Qemu-devel] [PATCH] virtio-pci: implement cfg capability

2015-07-02 Thread Michael S. Tsirkin
On Thu, Jul 02, 2015 at 08:48:14PM +0200, Paolo Bonzini wrote: > > > On 02/07/2015 15:00, Michael S. Tsirkin wrote: > > +cfg = (void *)(proxy->pci_dev.config + proxy->config_cap); > > +off = le32_to_cpu(cfg->cap.offset); > > +len = le32_to_cpu(cfg->cap.length); > > + > > +

Re: [Qemu-devel] [Xen-devel] [PATCH RFC 1 6/8] xen/pt: Make xen_pt_unregister_device idempotent

2015-07-02 Thread Konrad Rzeszutek Wilk
> > @@ -858,15 +863,20 @@ static void xen_pt_unregister_device(PCIDevice *d) > > machine_irq, errno); > > } > > } > > +s->machine_irq = 0; > > } > > > > /* delete all emulated config registers */ > > xen_pt_config_delete(s);

Re: [Qemu-devel] [PATCH v2] arm_mptimer: Fix timer shutdown

2015-07-02 Thread Dmitry Osipenko
02.07.2015 21:43, Dmitry Osipenko пишет: 02.07.2015 21:09, Peter Maydell пишет: TIMER_CONTROL_IT_ENABLE) to TIMER_CONTROL < it won't start, bug s/it won't start/it won't start periodic/ -- Dmitry

Re: [Qemu-devel] [PATCH] virtio-pci: implement cfg capability

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 15:00, Michael S. Tsirkin wrote: > +cfg = (void *)(proxy->pci_dev.config + proxy->config_cap); > +off = le32_to_cpu(cfg->cap.offset); > +len = le32_to_cpu(cfg->cap.length); > + > +if ((len == 1 || len == 2 || len == 4)) { > +address_space_

Re: [Qemu-devel] [PATCH v2] arm_mptimer: Fix timer shutdown

2015-07-02 Thread Dmitry Osipenko
02.07.2015 21:09, Peter Maydell пишет: On 2 July 2015 at 18:52, Dmitry Osipenko wrote: 02.07.2015 20:34, Peter Maydell пишет: This will now cause us to do the "reload the timer" logic if you write a 1 to the control bit when it was already 1, which we didn't do before. The logic I suggested

Re: [Qemu-devel] [PATCH 00/16] implement vNVDIMM

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 20:01, Xiao Guangrong wrote: > > Thanks for your review, Stefan and Paolo! > > On 07/02/2015 05:52 PM, Paolo Bonzini wrote: >> >> >> On 02/07/2015 11:20, Stefan Hajnoczi wrote: Currently, the NVDIMM driver has been merged into upstream Linux Kernel and this patchset

Re: [Qemu-devel] [PATCH v2] arm_mptimer: Fix timer shutdown

2015-07-02 Thread Peter Maydell
On 2 July 2015 at 18:52, Dmitry Osipenko wrote: > 02.07.2015 20:34, Peter Maydell пишет: >> >> >> This will now cause us to do the "reload the timer" >> logic if you write a 1 to the control bit when it was >> already 1, which we didn't do before. >> >> The logic I suggested in my previous review

Re: [Qemu-devel] [PATCH 14/16] nvdimm: support NFIT_CMD_GET_CONFIG_SIZE function

2015-07-02 Thread Xiao Guangrong
On 07/02/2015 05:23 PM, Stefan Hajnoczi wrote: On Wed, Jul 01, 2015 at 10:50:30PM +0800, Xiao Guangrong wrote: +static uint32_t dsm_cmd_config_size(struct dsm_buffer *in, struct dsm_out *out) +{ +GSList *list = get_nvdimm_built_list(); +PCNVDIMMDevice *nvdimm = get_nvdimm_device_by_han

Re: [Qemu-devel] [PATCH 00/16] implement vNVDIMM

2015-07-02 Thread Xiao Guangrong
Thanks for your review, Stefan and Paolo! On 07/02/2015 05:52 PM, Paolo Bonzini wrote: On 02/07/2015 11:20, Stefan Hajnoczi wrote: Currently, the NVDIMM driver has been merged into upstream Linux Kernel and this patchset tries to enable it in virtualization field From a device model persp

Re: [Qemu-devel] [PATCH 0/5] qapi flattening + some miscellaneous patches

2015-07-02 Thread Markus Armbruster
Gerd Hoffmann writes: > On Di, 2015-06-23 at 15:32 +0200, Kővágó, Zoltán wrote: >> I've cherry-picked the qapi related parts from my previous -audiodev >> patch series, we can hopefully concentrate on one thing at a time. The >> most important changes in this patch series are the flattening of t

Re: [Qemu-devel] [PATCH 5/5] opts: produce valid command line in qemu_opts_print

2015-07-02 Thread Markus Armbruster
"Kővágó, Zoltán" writes: > This will let us print options in a format that the user would actually > write it on the command line (foo=bar,baz=asd,etc=def), without > prepending a spurious comma at the beginning of the list, or quoting > values unnecessarily. This patch provides the following ch

Re: [Qemu-devel] [PATCH v2] arm_mptimer: Fix timer shutdown

2015-07-02 Thread Dmitry Osipenko
02.07.2015 20:34, Peter Maydell пишет: This will now cause us to do the "reload the timer" logic if you write a 1 to the control bit when it was already 1, which we didn't do before. The logic I suggested in my previous review comment gets this right... -- PMM The problem with code you sugg

Re: [Qemu-devel] [PATCH v2] arm_mptimer: Fix timer shutdown

2015-07-02 Thread Dmitry Osipenko
02.07.2015 20:34, Peter Maydell пишет: On 2 July 2015 at 18:20, Dmitry Osipenko wrote: Timer, running in periodic mode, can't be stopped or coming one-shot tick won't be canceled because timer control code just doesn't handle timer disabling. Fix it by deleting timer if enable bit isn't set. S

Re: [Qemu-devel] [PATCH 4/5] qapi: support nested structs in OptsVisitor

2015-07-02 Thread Markus Armbruster
"Kővágó, Zoltán" writes: > The current OptsVisitor flattens the whole structure, if there are same > named fields under different paths the current visitor can't cope with > them (it'll just set the first field, leaving the others unspecified (if > they're optional) or erroring out (if they're re

Re: [Qemu-devel] [PATCH v2] arm_mptimer: Fix timer shutdown

2015-07-02 Thread Peter Maydell
On 2 July 2015 at 18:20, Dmitry Osipenko wrote: > Timer, running in periodic mode, can't be stopped or coming one-shot tick > won't be canceled because timer control code just doesn't handle timer > disabling. Fix it by deleting timer if enable bit isn't set. > > Signed-off-by: Dmitry Osipenko >

Re: [Qemu-devel] [PULL v2 00/27] Migration pull request

2015-07-02 Thread Peter Maydell
t; > > Please, Apply. > > The following changes since commit 5317b0f6d4bb581c5c8f88f31138ee301ad2b7e5: > > Merge remote-tracking branch 'remotes/cohuck/tags/s390x-20150702-v3' into > staging (2015-07-02 15:20:55 +0100) > > are available in the git repository at: > &

Re: [Qemu-devel] [PATCH 2/5] qapi: convert NumaOptions into a flat union

2015-07-02 Thread Markus Armbruster
"Kővágó, Zoltán" writes: > Signed-off-by: Kővágó, Zoltán > --- > numa.c | 2 +- > qapi-schema.json | 47 --- > 2 files changed, 37 insertions(+), 12 deletions(-) > > diff --git a/numa.c b/numa.c > index 91fc6c1..8b0755d 100644 > --- a/numa.

[Qemu-devel] [PATCH v2] arm_mptimer: Fix timer shutdown

2015-07-02 Thread Dmitry Osipenko
Timer, running in periodic mode, can't be stopped or coming one-shot tick won't be canceled because timer control code just doesn't handle timer disabling. Fix it by deleting timer if enable bit isn't set. Signed-off-by: Dmitry Osipenko --- v2: Avoid calling timer_del() if the timer was already

Re: [Qemu-devel] [PATCH 3/5] qapi: change Netdev and NetLegacy into a flat union

2015-07-02 Thread Markus Armbruster
"Kővágó, Zoltán" writes: > Signed-off-by: Kővágó, Zoltán [...] > diff --git a/hw/arm/musicpal.c b/hw/arm/musicpal.c > index a3b1314..72e2f8f 100644 > --- a/hw/arm/musicpal.c > +++ b/hw/arm/musicpal.c > @@ -379,7 +379,7 @@ static void eth_cleanup(NetClientState *nc) > } > > static NetClientIn

[Qemu-devel] [PATCH v4 0/5] migration: Dynamic cpu throttling for auto-converge

2015-07-02 Thread Jason J. Herne
This patch set provides a new method for throttling a vcpu and makes use of said method to dynamically increase cpu throttling during an autoconverge migration until the migration completes. The method used here for throttling vcpus is likely not the best. However, I believe that it is preferable

Re: [Qemu-devel] [PATCH v2] thread-win32: fix GetThreadContext() permanently fails

2015-07-02 Thread Fabien Chouteau
On 07/01/2015 08:00 PM, Stefan Weil wrote: > Am 01.07.2015 um 18:49 schrieb Paolo Bonzini: >> >> On 01/07/2015 17:48, Zavadovsky Yan wrote: >>> Ping. >> Stefan, are you merging this? >> >> Paolo > > I can do so, but as the current code seems to fix the problems > with multi-processor systems, too

Re: [Qemu-devel] [PATCH v4 1/5] cpu: Provide vcpu throttling interface

2015-07-02 Thread Dr. David Alan Gilbert
* Paolo Bonzini (pbonz...@redhat.com) wrote: > > > On 02/07/2015 18:36, Jason J. Herne wrote: > > +static void cpu_throttle_thread(void *opaque) > > +{ > > +double pct = (double)throttle_percentage/100; > > +double throttle_ratio = pct / (1 - pct); > > +long sleeptime_ms = (long)(thro

Re: [Qemu-devel] [PATCH v4 1/5] cpu: Provide vcpu throttling interface

2015-07-02 Thread Andreas Färber
Am 02.07.2015 um 18:36 schrieb Jason J. Herne: > Provide a method to throttle guest cpu execution. CPUState is augmented with > timeout controls and throttle start/stop functions. To throttle the guest cpu > the caller simply has to call the throttle set function and provide a > percentage > of th

Re: [Qemu-devel] [PATCH] virtio-net: Drop net_virtio_info.can_receive

2015-07-02 Thread Michael S. Tsirkin
On Thu, Jul 02, 2015 at 01:46:26PM +0100, Stefan Hajnoczi wrote: > On Tue, Jun 30, 2015 at 04:35:24PM +0800, Jason Wang wrote: > > On 06/30/2015 11:06 AM, Fam Zheng wrote: > > > virtio_net_receive still does the check by calling > > > virtio_net_can_receive, if the device or driver is not ready, th

Re: [Qemu-devel] [PATCH v4 1/5] cpu: Provide vcpu throttling interface

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 18:36, Jason J. Herne wrote: > +static void cpu_throttle_thread(void *opaque) > +{ > +double pct = (double)throttle_percentage/100; > +double throttle_ratio = pct / (1 - pct); > +long sleeptime_ms = (long)(throttle_ratio * CPU_THROTTLE_TIMESLICE); > + > +if (!throttl

[Qemu-devel] [PATCH v4 4/5] qmp/hmp: Add throttle ratio to query-migrate and info migrate

2015-07-02 Thread Jason J. Herne
Report throttle percentage in info migrate and query-migrate responses when cpu throttling is active. Signed-off-by: Jason J. Herne Reviewed-by: Dr. David Alan Gilbert --- hmp.c | 5 + migration/migration.c | 5 + qapi-schema.json | 7 ++- 3 files changed, 16 in

[Qemu-devel] [PATCH v4 0/5] migration: Dynamic cpu throttling for auto-converge

2015-07-02 Thread Jason J. Herne
This patch set provides a new method for throttling a vcpu and makes use of said method to dynamically increase cpu throttling during an autoconverge migration until the migration completes. The method used here for throttling vcpus is likely not the best. However, I believe that it is preferable

[Qemu-devel] [PATCH v4 2/5] migration: Parameters for auto-converge cpu throttling

2015-07-02 Thread Jason J. Herne
Add migration parameters to allow the user to adjust the parameters that control cpu throttling when auto-converge is in effect. The added parameters are as follows: x-cpu-throttle-initial : Initial percantage of time guest cpus are throttled when migration auto-converge is activated. x-cpu-throt

[Qemu-devel] [PATCH v4 5/5] migration: Disambiguate MAX_THROTTLE

2015-07-02 Thread Jason J. Herne
Migration has a define for MAX_THROTTLE. Update comment to clarify that this is used for throttling transfer speed. Hopefully this will prevent it from being confused with a guest cpu throttling entity. Signed-off-by: Jason J. Herne Reviewed-by: Dr. David Alan Gilbert --- migration/migration.c

Re: [Qemu-devel] [PATCH v3 1/5] cpu: Provide vcpu throttling interface

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 18:33, Jason J. Herne wrote: > I've made all of the changes you have suggested except adding atomics. I'm > having > a bit of trouble figuring out what is needed here. Perhaps I should be using > atomic_read() to read throttle_percentage? If so, I don't undertand why. > Rather >

[Qemu-devel] [PATCH v4 1/5] cpu: Provide vcpu throttling interface

2015-07-02 Thread Jason J. Herne
Provide a method to throttle guest cpu execution. CPUState is augmented with timeout controls and throttle start/stop functions. To throttle the guest cpu the caller simply has to call the throttle set function and provide a percentage of throttle time. Signed-off-by: Jason J. Herne Reviewed-by:

[Qemu-devel] [PATCH v4 3/5] migration: Dynamic cpu throttling for auto-converge

2015-07-02 Thread Jason J. Herne
Remove traditional auto-converge static 30ms throttling code and replace it with a dynamic throttling algorithm. Additionally, be more aggressive when deciding when to start throttling. Previously we waited until four unproductive memory passes. Now we begin throttling after only two unproductive

Re: [Qemu-devel] [PATCH v3 1/5] cpu: Provide vcpu throttling interface

2015-07-02 Thread Jason J. Herne
On 07/01/2015 10:03 AM, Paolo Bonzini wrote: On 26/06/2015 20:07, Dr. David Alan Gilbert wrote: * Jason J. Herne (jjhe...@linux.vnet.ibm.com) wrote: Provide a method to throttle guest cpu execution. CPUState is augmented with timeout controls and throttle start/stop functions. To throttle the

[Qemu-devel] [PATCH 2/3] monitor: remove target-specific code from monitor.c

2015-07-02 Thread Denis V. Lunev
From: Pavel Butsykin Move target-specific code out of /monitor.c to /target-*/monitor.c, this will avoid code cluttering and using random ifdeffery. The solution is quite simple, but solves the issue of the separation of target-specific code from monitor Signed-off-by: Pavel Butsykin Signed-of

Re: [Qemu-devel] [PATCH 07/12] kvm/x86: added hyper-v crash data and ctl msr's get/set'ers

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 18:07, Denis V. Lunev wrote: > From: Andrey Smetanin > > Added hyper-v crash msr's(HV_X64_MSR_CRASH*) data and control > geters and setters. Userspace should check that such msr's > available by check of KVM_CAP_HYPERV_MSR_CRASH capability. It should use the existing KVM_GET_SUPP

[Qemu-devel] [PATCH 3/3] monitor: added generation of documentation for hmp-commands-info.hx

2015-07-02 Thread Denis V. Lunev
From: Pavel Butsykin It will be easier if you need to add info-commands to edit only hmp-commands-info.hx, before this had to edit monitor.c and hmp-commands.hx Signed-off-by: Pavel Butsykin Signed-off-by: Denis V. Lunev CC: Luiz Capitulino CC: Paolo Bonzini CC: Peter Maydell --- .gitignor

[Qemu-devel] [PULL 27/27] migration: extend migration_bitmap

2015-07-02 Thread Juan Quintela
From: Li Zhijian Prevously, if we hotplug a device(e.g. device_add e1000) during migration is processing in source side, qemu will add a new ram block but migration_bitmap is not extended. In this case, migration_bitmap will overflow and lead qemu abort unexpectedly. Signed-off-by: Li Zhijian S

[Qemu-devel] [PATCH] block: update bdrv_drain_all()/bdrv_drain() comments

2015-07-02 Thread Stefan Hajnoczi
The doc comments for bdrv_drain_all() and bdrv_drain() are outdated: * The bdrv_drain() comment is a poor man's bdrv_lock()/bdrv_unlock() which Fam Zheng is currently developing. Unfortunately this warning was never really enough because devices keep submitting I/O and op blockers don't

Re: [Qemu-devel] [PATCH 12/12] qemu/kvm/x86: hyper-v crash msrs set/get'ers and migration

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 18:07, Denis V. Lunev wrote: > +if (cpu->hyperv_crash && > +kvm_check_extension(cs->kvm_state, KVM_CAP_HYPERV_MSR_CRASH) > > 0) { > +c->edx |= HV_X64_GUEST_CRASH_MSR_AVAILABLE; > +has_msr_hv_crash = true; > +} > + Please patch kvm

[Qemu-devel] [PULL 24/27] migration: Add migration events on target side

2015-07-02 Thread Juan Quintela
We reuse the migration events from the source side, sending them on the appropiate place. Signed-off-by: Juan Quintela Reviewed-by: Eric Blake Reviewed-by: Dr. David Alan Gilbert --- migration/migration.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/migration/migrati

[Qemu-devel] [PATCH 1/3] hmp-commands-info: move info_cmds content out of monitor.c

2015-07-02 Thread Denis V. Lunev
From: Pavel Butsykin For moving target- and device-specific code from monitor.c, to beginning we move info_cmds content to hmp-commands-info.hx Signed-off-by: Pavel Butsykin Signed-off-by: Denis V. Lunev CC: Luiz Capitulino CC: Paolo Bonzini CC: Peter Maydell --- Makefile.target |

Re: [Qemu-devel] [PATCH 11/12] qemu: add crash_occurred flag into CPUState

2015-07-02 Thread Paolo Bonzini
On 02/07/2015 18:18, Andreas Färber wrote: >> > +uint32_t crash_occurred; >> > volatile sig_atomic_t exit_request; >> > uint32_t interrupt_request; >> > int singlestep_enabled; > If you add this field to CPUState, you'll also need to reset it in > qom/cpu.c. Or is it intentiona

[Qemu-devel] [PULL 20/27] migration: ensure we start in NONE state

2015-07-02 Thread Juan Quintela
Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert --- migration/migration.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/migration/migration.c b/migration/migration.c index 1e34aa5..5c1233f 100644 --- a/migration/migration.c +++ b/migration/migration.c

[Qemu-devel] [PATCH 07/12] kvm/x86: added hyper-v crash data and ctl msr's get/set'ers

2015-07-02 Thread Denis V. Lunev
From: Andrey Smetanin Added hyper-v crash msr's(HV_X64_MSR_CRASH*) data and control geters and setters. Userspace should check that such msr's available by check of KVM_CAP_HYPERV_MSR_CRASH capability. User space allowed to setup Hyper-V crash ctl msr. This msr should be setup to HV_X64_MSR_CRAS

Re: [Qemu-devel] [PATCH 11/12] qemu: add crash_occurred flag into CPUState

2015-07-02 Thread Andreas Färber
Hi, This patch is clearly against QEMU, please name it "cpu: Add crash_...". (You may want to take a second look at the non-CPU patches, too.) Am 02.07.2015 um 18:07 schrieb Denis V. Lunev: > From: Andrey Smetanin > > CPUState->crash_occurred value inside CPUState marks "CPUState::crash_occurr

[Qemu-devel] [PULL 25/27] check_section_footers: Check the correct section_id

2015-07-02 Thread Juan Quintela
From: "Dr. David Alan Gilbert" The section footers check was incorrectly checking the section_id in the SaveStateEntry not the LoadStateEntry. These can validly be different if the two QEMU instances have instantiated their devices in a different order. The test only cares that we're finishing

[Qemu-devel] [PULL 14/27] runstate: migration allows more transitions now

2015-07-02 Thread Juan Quintela
Next commit would allow to move from incoming migration to error happening on source. Should we add more states to this transition? Luiz? Signed-off-by: Juan Quintela Reviewed-by: Dr. David Alan Gilbert --- vl.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/vl.c

Re: [Qemu-devel] [PATCH v4 4/9] Add virt-v3 machine that uses GIC-500

2015-07-02 Thread Daniel P. Berrange
On Thu, Jul 02, 2015 at 05:47:04PM +0300, Pavel Fedin wrote: > Hello! > > I already explained this earlier: > http://lists.nongnu.org/archive/html/qemu-devel/2015-05/msg04842.html, and i > tried to explain this in commit message. Current qemu architecture does not > allow doing this in a clea

  1   2   3   4   >