[Qemu-devel] [PULL 3/4] xen/pass-through: correctly deal with RW1C bits

2015-12-22 Thread Stefano Stabellini
From: Jan Beulich Introduce yet another mask for them, so that the generic routine can handle them, at once rendering xen_pt_pmcsr_reg_write() superfluous. Signed-off-by: Jan Beulich Signed-off-by: Stefano Stabellini Reviewed-by: Stefano Stabellini --- hw/xen/xen_pt.h |2

[Qemu-devel] [PULL 2/4] xen/MSI-X: really enforce alignment

2015-12-22 Thread Stefano Stabellini
ulich Signed-off-by: Stefano Stabellini Reviewed-by: Stefano Stabellini --- hw/xen/xen_pt_msi.c | 22 -- 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/hw/xen/xen_pt_msi.c b/hw/xen/xen_pt_msi.c index e10cd2a..302a310 100644 --- a/hw/xen/xen_pt_msi.c +++ b/h

[Qemu-devel] [PULL 1/4] xen/MSI-X: latch MSI-X table writes

2015-12-22 Thread Stefano Stabellini
vior. Signed-off-by: Jan Beulich Signed-off-by: Stefano Stabellini Reviewed-by: Stefano Stabellini --- hw/xen/xen_pt.h |4 +-- hw/xen/xen_pt_config_init.c |2 ++ hw/xen/xen_pt_msi.c | 74 --- 3 files changed, 32 inserti

[Qemu-devel] [PULL 0/4] xen-2015-12-22

2015-12-22 Thread Stefano Stabellini
X: latch MSI-X table writes xen/MSI-X: really enforce alignment xen/pass-through: correctly deal with RW1C bits Stefano Stabellini (1): xen_disk: treat "vhd" as "vpc" hw/block/xen_disk.c |3 ++ hw/xen/xen_pt.h |6

Re: [Qemu-devel] [Xen-devel] [PATCH v3 13/13] xen-hvm: Mark inappropriate error handling FIXME

2015-12-22 Thread Stefano Stabellini
On Thu, 17 Dec 2015, Markus Armbruster wrote: > Cc: Stefano Stabellini > Cc: xen-de...@lists.xensource.com > Signed-off-by: Markus Armbruster > --- > xen-hvm.c | 7 +++ > 1 file changed, 7 insertions(+) > > diff --git a/xen-hvm.c b/xen-hvm.c > index 3d78a0c.

Re: [Qemu-devel] [PATCH v2] xen-pvdevice: convert to realize()

2015-12-22 Thread Stefano Stabellini
On Tue, 22 Dec 2015, Cao jin wrote: > Signed-off-by: Cao jin Acked-by: Stefano Stabellini > hw/i386/xen/xen_pvdevice.c | 12 ++-- > 1 file changed, 6 insertions(+), 6 deletions(-) > > diff --git a/hw/i386/xen/xen_pvdevice.c b/hw/i386/xen/xen_pvdevice.c > inde

Re: [Qemu-devel] [PATCH 5/5] xen-pvdevice: convert to realize()

2015-12-21 Thread Stefano Stabellini
On Fri, 18 Dec 2015, Cao jin wrote: > Signed-off-by: Cao jin > --- > hw/i386/xen/xen_pvdevice.c | 12 ++-- > 1 file changed, 6 insertions(+), 6 deletions(-) > > diff --git a/hw/i386/xen/xen_pvdevice.c b/hw/i386/xen/xen_pvdevice.c > index c218947..a6c93d0 100644 > --- a/hw/i386/xen/xen_pv

Re: [Qemu-devel] [PATCH 5/5] xen-pvdevice: convert to realize()

2015-12-21 Thread Stefano Stabellini
On Mon, 21 Dec 2015, Cao jin wrote: > On 12/19/2015 02:00 AM, Paolo Bonzini wrote: > > CCing Stefano, who is the maintainer. > > > > "Stefano" isn`t in the list when I use scripts/get_maintainer.pl... Thanks Cao. I have just sent a patch to update the MAINTAINERS file. http://marc.info/?l=qemu-

[Qemu-devel] [PATCH] MAINTAINERS: update Xen files

2015-12-21 Thread Stefano Stabellini
Add the PV block backend, the Xen mapcache, and hw/i386/xen to the list of Xen related files maintained by me. Signed-off-by: Stefano Stabellini diff --git a/MAINTAINERS b/MAINTAINERS index 55a0fd8..781e695 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -273,9 +273,12 @@ F: */xen* F: hw/char

Re: [Qemu-devel] [Xen-devel] new barrier type for paravirt (was Re: [PATCH] virtio_ring: use smp_store_mb)

2015-12-21 Thread Stefano Stabellini
On Mon, 21 Dec 2015, David Vrabel wrote: > On 20/12/15 09:25, Michael S. Tsirkin wrote: > > > > I noticed that drivers/xen/xenbus/xenbus_comms.c uses > > full memory barriers to communicate with the other side. > > For example: > > > > /* Must write data /after/ reading the consum

[Qemu-devel] [PULL 0/2] xsa155

2015-12-18 Thread Stefano Stabellini
fixes Stefano Stabellini (2): xen/blkif: Avoid double access to src->nr_segments xenfb: avoid reading twice the same fields from the shared page hw/block/xen_blkif.h | 12 hw/display/xenfb.c

[Qemu-devel] [PULL 1/2] xen/blkif: Avoid double access to src->nr_segments

2015-12-18 Thread Stefano Stabellini
of XSA-155. Signed-off-by: Stefano Stabellini --- hw/block/xen_blkif.h | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/hw/block/xen_blkif.h b/hw/block/xen_blkif.h index 711b692..c68487cb 100644 --- a/hw/block/xen_blkif.h +++ b/hw/block/xen_blkif.h @@ -85,8

Re: [Qemu-devel] [PATCH] fix MSI injection on Xen

2015-12-18 Thread Stefano Stabellini
On Wed, 2 Dec 2015, Michael S. Tsirkin wrote: > On Wed, Dec 02, 2015 at 05:16:18PM +0000, Stefano Stabellini wrote: > > On Wed, 2 Dec 2015, Michael S. Tsirkin wrote: > > > On Wed, Dec 02, 2015 at 04:56:21PM +, Stefano Stabellini wrote: > > > > On Xen MSIs can be

[Qemu-devel] [PULL 2/2] xenfb: avoid reading twice the same fields from the shared page

2015-12-18 Thread Stefano Stabellini
Reading twice the same field could give the guest an attack of opportunity. In the case of event->type, gcc could compile the switch statement into a jump table, effectively ending up reading the type field multiple times. This is part of XSA-155. Signed-off-by: Stefano Stabellini ---

Re: [Qemu-devel] [PULL 0/2] xsa155

2015-12-18 Thread Stefano Stabellini
Michael, could you please backport these two patches? They should apply fine. On Fri, 18 Dec 2015, Stefano Stabellini wrote: > The following changes since commit 18f49881cf8359e89396aac12f5d3cf3f8a632ba: > > configure: Fix shell syntax to placate OpenBSD's pdksh (2015-12-18 13:

Re: [Qemu-devel] [PATCH QEMU-XEN v7 5/8] xen: Switch uses of xc_map_foreign_{pages, bulk} to use libxenforeignmemory API.

2015-12-16 Thread Stefano Stabellini
On Wed, 16 Dec 2015, Ian Campbell wrote: > In Xen 4.7 we are refactoring parts libxenctrl into a number of > separate libraries which will provide backward and forward API and ABI > compatiblity. > > One such library will be libxenforeignmemory which provides access to > privileged foreign mapping

Re: [Qemu-devel] [Xen-devel] [PATCH RFC v2 4/4] xen/MSI: re-expose masking capability

2015-12-14 Thread Stefano Stabellini
On Mon, 14 Dec 2015, Jan Beulich wrote: > >>> On 11.12.15 at 17:56, wrote: > > For the original issue here, could the flag be exposed as a > > XEN_SYSCTL_PHYSCAP_ > > Yes, I think it could, albeit calling this a "capability" or "feature" > seems odd (since really the original behavior was bog

Re: [Qemu-devel] [Xen-devel] [PATCH RFC v2 4/4] xen/MSI: re-expose masking capability

2015-12-14 Thread Stefano Stabellini
On Mon, 14 Dec 2015, Jan Beulich wrote: > >>> On 11.12.15 at 17:56, wrote: > > On Fri, 2015-12-11 at 16:44 +, Stefano Stabellini wrote: > >> > >> It is not possible to do this at runtime. I think we should do this at > >> compile time because

Re: [Qemu-devel] [Xen-devel] [PATCH RFC v2 4/4] xen/MSI: re-expose masking capability

2015-12-14 Thread Stefano Stabellini
On Fri, 11 Dec 2015, Ian Campbell wrote: > On Fri, 2015-12-11 at 16:44 +0000, Stefano Stabellini wrote: > >   > > It is not possible to do this at runtime. I think we should do this at > > compile time because in any case it is not supported to run a QEMU built > > f

Re: [Qemu-devel] [PULL 0/1] tags/xen-2015-12-11

2015-12-11 Thread Stefano Stabellini
On Fri, 11 Dec 2015, Peter Maydell wrote: > On 11 December 2015 at 16:52, Stefano Stabellini > wrote: > > The following changes since commit 6e0abc251dd4f8eba1f53656dfede12e5840e83b: > > > > blockdev: Mark {insert, remove}-medium experimental (2015-12-11 15:39:29

[Qemu-devel] [PULL 0/1] tags/xen-2015-12-11

2015-12-11 Thread Stefano Stabellini
changes up to 73e72322d336e1a5c5fb32e8cc2310c2ad62d79b: xen_disk: treat "vhd" as "vpc" (2015-12-11 16:49:42 +) Xen 2015/12/11 -------- S

[Qemu-devel] [PULL 1/1] xen_disk: treat "vhd" as "vpc"

2015-12-11 Thread Stefano Stabellini
The Xen toolstack uses "vhd" to specify a disk in VHD format, however the name of the driver in QEMU is "vpc". Replace "vhd" with "vpc", so that QEMU can find the right driver to use for it. Signed-off-by: Stefano Stabellini --- hw/block/xen_disk.c

Re: [Qemu-devel] [PATCH RFC v2 4/4] xen/MSI: re-expose masking capability

2015-12-11 Thread Stefano Stabellini
On Fri, 11 Dec 2015, Jan Beulich wrote: > >>> On 11.12.15 at 15:33, wrote: > > On Mon, 7 Dec 2015, Jan Beulich wrote: > >> >>> On 07.12.15 at 15:56, wrote: > >> > On Mon, 7 Dec 2015, Jan Beulich wrote: > >> >> >>> On 07.12.15 at 13:45, wrote: > >> >> > On Tue, 24 Nov 2015, Jan Beulich wrote: > >

Re: [Qemu-devel] [PATCH QEMU-XEN v6 4/8] xen: Switch uses of xc_map_foreign_range into xc_map_foreign_pages

2015-12-11 Thread Stefano Stabellini
On Fri, 11 Dec 2015, Ian Campbell wrote: > On Fri, 2015-12-11 at 14:26 +0000, Stefano Stabellini wrote: > > On Wed, 9 Dec 2015, Ian Campbell wrote: > > > On Thu, 2015-12-03 at 11:23 +, Ian Campbell wrote: > > > > diff --git a/hw/display/xenfb.c b/hw/display

Re: [Qemu-devel] [PATCH RFC v2 4/4] xen/MSI: re-expose masking capability

2015-12-11 Thread Stefano Stabellini
On Mon, 7 Dec 2015, Jan Beulich wrote: > >>> On 07.12.15 at 15:56, wrote: > > On Mon, 7 Dec 2015, Jan Beulich wrote: > >> >>> On 07.12.15 at 13:45, wrote: > >> > On Tue, 24 Nov 2015, Jan Beulich wrote: > >> >> Now that the hypervisor intercepts all config space writes and monitors > >> >> changes

Re: [Qemu-devel] [PATCH QEMU-XEN v6 4/8] xen: Switch uses of xc_map_foreign_range into xc_map_foreign_pages

2015-12-11 Thread Stefano Stabellini
On Wed, 9 Dec 2015, Ian Campbell wrote: > On Thu, 2015-12-03 at 11:23 +, Ian Campbell wrote: > > diff --git a/hw/display/xenfb.c b/hw/display/xenfb.c > > index 5e324ef..c96d974 100644 > > --- a/hw/display/xenfb.c > > +++ b/hw/display/xenfb.c > > @@ -104,9 +104,8 @@ static int common_bind(struct

Re: [Qemu-devel] [PATCH 2/7] pc: move igd support code to igd.c

2015-12-11 Thread Stefano Stabellini
On Tue, 8 Dec 2015, Gerd Hoffmann wrote: > Pure code motion, except for dropping instance_size for > TYPE_IGD_PASSTHROUGH_I440FX_PCI_DEVICE (no need to set, > we can inherit it from TYPE_I440FX_PCI_DEVICE). > > Signed-off-by: Gerd Hoffmann Acked-by: Stefano Stabellini

Re: [Qemu-devel] [PATCH 1/7] pc: wire up TYPE_IGD_PASSTHROUGH_I440FX_PCI_DEVICE for !xen

2015-12-11 Thread Stefano Stabellini
he pc_init1() arguments in pc_i440fx_init_pci() > will be the same as the call being replaced above, keeping > exactly the same behavior. > > This change breaks compatibility in the unlikely case somebody is > already using igd-passthru=on in non-xenfv machines. I don't > think it would make sense to keep a broken igd-passthru option in > pc-2.5 and older for compatibility if nobody ever used that > option, but it would be nice to mention that in the commit > message. > > Reviewed-by: Eduardo Habkost I agree Reviewed-by: Stefano Stabellini

Re: [Qemu-devel] [PATCH 0/7] igd passthrough chipset tweaks

2015-12-11 Thread Stefano Stabellini
Actually CC'ing xen-devel On Fri, 11 Dec 2015, Stefano Stabellini wrote: > On Tue, 8 Dec 2015, Gerd Hoffmann wrote: > > Hi, > > > > We have some code in our tree to support pci passthrough of intel > > graphics devices (igd) on xen, which requires some chi

Re: [Qemu-devel] [PATCH 0/7] igd passthrough chipset tweaks

2015-12-11 Thread Stefano Stabellini
On Tue, 8 Dec 2015, Gerd Hoffmann wrote: > Hi, > > We have some code in our tree to support pci passthrough of intel > graphics devices (igd) on xen, which requires some chipset tweaks > for (a) the host bridge and (b) the lpc/isa-bridge to meat the > expectations of the guest driver. For kvm w

Re: [Qemu-devel] [PATCH 11/16] pc: Simplify signature of xen_load_linux()

2015-12-11 Thread Stefano Stabellini
On Tue, 1 Dec 2015, Eduardo Habkost wrote: > We don't need the FWCfgState return value and the PcGuestInfo > parameter. > > Signed-off-by: Eduardo Habkost Reviewed-by: Stefano Stabellini > hw/i386/pc.c | 5 + > hw/i386/pc_piix.c| 2 +- > include

Re: [Qemu-devel] [Xen-devel] [PATCH v3 1/4] xen/MSI-X: latch MSI-X table writes

2015-12-09 Thread Stefano Stabellini
On Tue, 8 Dec 2015, Jan Beulich wrote: > The remaining log message in pci_msix_write() is wrong, as there guest > behavior may only appear to be wrong: For one, the old logic didn't > take the mask-all bit into account. And then this shouldn't depend on > host device state (i.e. the host may have m

Re: [Qemu-devel] [PATCH v2] xen_pt: fix failure of attaching & detaching a PCI device to VM repeatedly

2015-12-09 Thread Stefano Stabellini
On Wed, 9 Dec 2015, Jianzhong,Chang wrote: > Add pci = [ '$VF_BDF1', '$VF_BDF2', '$VF_BDF3'] in > hvm guest configuration file. After the guest boot up, > detach the VFs in sequence by > "xl pci-detach $DOMID $VF_BDF1" > "xl pci-detach $DOMID $VF_BDF2" > "xl pci-detach $DOMID $VF_BDF3" > and rea

Re: [Qemu-devel] [PATCH v2 1/4] xen/MSI-X: latch MSI-X table writes

2015-12-08 Thread Stefano Stabellini
On Mon, 7 Dec 2015, Jan Beulich wrote: > >>> On 07.12.15 at 13:41, wrote: > > I know that in your opinion is superfluous, nonetheless could you please > > add 2-3 lines of in-code comment right here, to explain what you are > > doing with the check? Something like: > > > > /* > > * Update the e

Re: [Qemu-devel] [PATCH RFC v2 4/4] xen/MSI: re-expose masking capability

2015-12-07 Thread Stefano Stabellini
On Mon, 7 Dec 2015, Jan Beulich wrote: > >>> On 07.12.15 at 13:45, wrote: > > On Tue, 24 Nov 2015, Jan Beulich wrote: > >> Now that the hypervisor intercepts all config space writes and monitors > >> changes to the masking flags, this undoes the main effect of the > >> XSA-129 fix, exposing the ma

Re: [Qemu-devel] [PATCH RFC v2 4/4] xen/MSI: re-expose masking capability

2015-12-07 Thread Stefano Stabellini
On Tue, 24 Nov 2015, Jan Beulich wrote: > Now that the hypervisor intercepts all config space writes and monitors > changes to the masking flags, this undoes the main effect of the > XSA-129 fix, exposing the masking capability again to guests. > > Signed-off-by: Jan Beulich > --- > TBD: We proba

Re: [Qemu-devel] [PATCH v2 3/4] xen/pass-through: correctly deal with RW1C bits

2015-12-07 Thread Stefano Stabellini
On Tue, 24 Nov 2015, Jan Beulich wrote: > Introduce yet another mask for them, so that the generic routine can > handle them, at once rendering xen_pt_pmcsr_reg_write() superfluous. > > Signed-off-by: Jan Beulich Reviewed-by: Stefano Stabellini > --- a/hw/xen/xen_pt.h > +++

Re: [Qemu-devel] [PATCH v2 1/4] xen/MSI-X: latch MSI-X table writes

2015-12-07 Thread Stefano Stabellini
On Tue, 24 Nov 2015, Jan Beulich wrote: > The remaining log message in pci_msix_write() is wrong, as there guest > behavior may only appear to be wrong: For one, the old logic didn't > take the mask-all bit into account. And then this shouldn't depend on > host device state (i.e. the host may have

Re: [Qemu-devel] [PATCH] xen_pt: fix failure of attaching & detaching a PCI device to VM repeatedly

2015-12-04 Thread Stefano Stabellini
On Thu, 3 Dec 2015, Jianzhong,Chang wrote: > From: jianzhong,Chang > > Add pci = [ '$VF_BDF', '$VF_BDF', '$VF_BDF'] in This is a bit confusing: it is not actually correct to assign the same device, even an SR_IOV VF, multiple times, so these must be all different. More like: pci = [ '$VF_BDF1',

Re: [Qemu-devel] [PATCH QEMU-XEN v6 6/8] xen: Use stable library interfaces when they are available.

2015-12-04 Thread Stefano Stabellini
6 (inclusive) and the patches targetting > 4.7 which adds these libraries. > > Signed-off-by: Ian Campbell Reviewed-by: Stefano Stabellini > v6: Two minor formatting things. > Rebase onto "xen: fix usage of xc_domain_create in domain > builder", require

Re: [Qemu-devel] [PATCH QEMU-XEN v6 4/8] xen: Switch uses of xc_map_foreign_range into xc_map_foreign_pages

2015-12-04 Thread Stefano Stabellini
nsure under what circumstances > xendev->dev can be NULL or if anything elsewhere ensures the value > fits into an int. For now I just use a temporary xen_pfn_t to in > effect upcast the pointer from int* to xen_pfn_t*. > > Signed-off-by: Ian Campbell Reviewed-by: Stefano Stabellini

Re: [Qemu-devel] [PATCH QEMU-XEN v6 5/8] xen: Switch uses of xc_map_foreign_{pages, bulk} to use libxenforeignmemory API.

2015-12-04 Thread Stefano Stabellini
On Thu, 3 Dec 2015, Ian Campbell wrote: > diff --git a/include/hw/xen/xen_common.h b/include/hw/xen/xen_common.h > index 2cadd4f..8fbaf07 100644 > --- a/include/hw/xen/xen_common.h > +++ b/include/hw/xen/xen_common.h > @@ -41,6 +41,7 @@ static inline void *xc_map_foreign_bulk(int xc_handle, > uint

[Qemu-devel] [PATCH] xen_disk: treat "vhd" as "vpc"

2015-12-04 Thread Stefano Stabellini
The Xen toolstack uses "vhd" to specify a disk in VHD format, however the name of the driver in QEMU is "vpc". Replace "vhd" with "vpc", so that QEMU can find the right driver to use for it. Signed-off-by: Stefano Stabellini diff --git a/hw/block/xen_di

Re: [Qemu-devel] Highlighting changes in QEMU 2.5

2015-12-03 Thread Stefano Stabellini
On Wed, 2 Dec 2015, Eduardo Habkost wrote: > On Tue, Dec 01, 2015 at 05:46:05PM +0530, Amit Shah wrote: > > Ping. > > > > I haven't received any responses so far, please let me know if you're > > planning on doing this. > > Sorry for taking so long to reply. I don't feel comfortable > recording a

Re: [Qemu-devel] [PATCH] fix MSI injection on Xen

2015-12-02 Thread Stefano Stabellini
On Wed, 2 Dec 2015, Michael S. Tsirkin wrote: > On Wed, Dec 02, 2015 at 04:56:21PM +0000, Stefano Stabellini wrote: > > On Xen MSIs can be remapped into pirqs, which are a type of event > > channels. It's mostly for the benefit of PCI passthrough devices, to > > avoid t

[Qemu-devel] [PATCH] fix MSI injection on Xen

2015-12-02 Thread Stefano Stabellini
t for MSI and MSI-X which have been remapped into pirqs. Signed-off-by: Stefano Stabellini diff --git a/hw/pci/msi.c b/hw/pci/msi.c index f9c0484..3998725 100644 --- a/hw/pci/msi.c +++ b/hw/pci/msi.c @@ -19,6 +19,7 @@ */ #include "hw/pci/msi.h" +#include &qu

[Qemu-devel] [PULL for-2.5 0/2] xen-20151125

2015-11-25 Thread Stefano Stabellini
The following changes since commit 8337c6cbc37c6b2184f41bab3eaff47d5e68012a: Update version for v2.5.0-rc0 release (2015-11-13 17:10:36 +) are available in the git repository at: git://xenbits.xen.org/people/sstabellini/qemu-dm.git tags/xen-20151125 for you to fetch changes up to 22037d

[Qemu-devel] [PULL for-4.5 2/2] xen_disk: Remove ioreq.postsync

2015-11-25 Thread Stefano Stabellini
From: Alberto Garcia This code has been dead for three years (since commit 7e7b7cba1). Signed-off-by: Alberto Garcia Signed-off-by: Stefano Stabellini Reviewed-by: Stefano Stabellini --- hw/block/xen_disk.c |8 1 file changed, 8 deletions(-) diff --git a/hw/block/xen_disk.c b

[Qemu-devel] [PULL for-4.5 1/2] xen: fix usage of xc_domain_create in domain builder

2015-11-25 Thread Stefano Stabellini
encapsulates the correct call to xc_domain_create depending on the libxc version detected. Signed-off-by: Roger Pau Monné Acked-by: Stefano Stabellini Signed-off-by: Stefano Stabellini --- configure | 17 + hw/xenpv/xen_domainbuild.c |2 +- include/hw/xen

Re: [Qemu-devel] [PATCH for-2.5] xen_disk: Remove ioreq.postsync

2015-11-25 Thread Stefano Stabellini
On Wed, 25 Nov 2015, Alberto Garcia wrote: > This code has been dead for three years (since commit 7e7b7cba1). > > Signed-off-by: Alberto Garcia Reviewed-by: Stefano Stabellini Kevin, I'll send it out together with another fix today. > hw/block/xen_disk.c | 8

Re: [Qemu-devel] [Intel-gfx] [Announcement] 2015-Q3 release of XenGT - a Mediated Graphics Passthrough Solution from Intel

2015-11-19 Thread Stefano Stabellini
On Thu, 19 Nov 2015, Paolo Bonzini wrote: > On 19/11/2015 16:32, Stefano Stabellini wrote: > > > In addition to Kevin's replies, I have a high-level question: can VFIO > > > be used by QEMU for both KVM and Xen? > > > > No. VFIO cannot be used with Xen today.

Re: [Qemu-devel] [Intel-gfx] [Announcement] 2015-Q3 release of XenGT - a Mediated Graphics Passthrough Solution from Intel

2015-11-19 Thread Stefano Stabellini
On Thu, 19 Nov 2015, Jike Song wrote: > Hi Alex, thanks for the discussion. > > In addition to Kevin's replies, I have a high-level question: can VFIO > be used by QEMU for both KVM and Xen? No. VFIO cannot be used with Xen today. When running on Xen, the IOMMU is owned by Xen.

Re: [Qemu-devel] [PATCH QEMU v3 2/2] xen: fix usage of xc_domain_create in domain builder

2015-11-13 Thread Stefano Stabellini
all stub called xen_domain_create that encapsulates the correct call > to xc_domain_create depending on the libxc version detected. > > Signed-off-by: Roger Pau Monné Acked-by: Stefano Stabellini I'll apply it to my tree > Cc: Stefano Stabellini > Cc: qemu-devel@nongnu.org

Re: [Qemu-devel] [PATCH QEMU v2 2/2] xen: fix usage of xc_domain_create in domain builder

2015-11-13 Thread Stefano Stabellini
he corresponding libxc change already in Xen? > Cc: Stefano Stabellini > Cc: qemu-devel@nongnu.org > --- > Changes since v1: > - Add a compat layer to support previous libxc versions. > - Add machinery to detect current Xen unstable (4.7). > --- > configure

Re: [Qemu-devel] [PATCH QEMU 2/2] xen: fix usage of xc_domain_create in domain builder

2015-11-13 Thread Stefano Stabellini
f-by: Roger Pau Monné Give a look at include/hw/xen/xen_common.h and add a compatibility shim there. Keep in mind that QEMU needs to build against any version of Xen from 4.0 onward. > Cc: Stefano Stabellini > Cc: qemu-devel@nongnu.org > --- > hw/xenpv/xen_domainbuild.c | 2 +- >

Re: [Qemu-devel] [PATCH QEMU-XEN v5 3/9] xen: Switch to libxengnttab interface for compat shims.

2015-11-10 Thread Stefano Stabellini
upport for actually using > libxengnttab, it just adjusts the existing shims. > > Signed-off-by: Ian Campbell Reviewed-by: Stefano Stabellini > v4: Ran checkpatch, fixed all errors > Allocate correct size for handle (i.e. not size of the ptr) > Rebase onto "xen_con

Re: [Qemu-devel] [PATCH QEMU-XEN v5 7/9] xen: Use stable library interfaces when they are available.

2015-11-10 Thread Stefano Stabellini
6 (inclusive) and the patches targetting > 4.7 which adds these libraries. > > Signed-off-by: Ian Campbell Reviewed-by: Stefano Stabellini Two formatting issues below: > v5: Remove ifdef check when undeffing the compat stuff. > s/now way/no way/ > > v4: xenforeignme

Re: [Qemu-devel] [PATCH QEMU-XEN v5 9/9] xen: make it possible to build without the Xen PV domain builder

2015-11-10 Thread Stefano Stabellini
t; This is another step towards only using Xen libraries which provide a > stable inteface. > > Signed-off-by: Ian Campbell Reviewed-by: Stefano Stabellini > v5: XEN_CREATE entirely wihtin CONFIG_XEN_PV_DOMAIN_BUILD ifdef. > Simplify configure'ry. > > v4: Fixed a

[Qemu-devel] [PULL 3/3] xen-platform: Replace assert() with appropriate error reporting

2015-10-26 Thread Stefano Stabellini
form.c:391: xen_platform_initfn: Assertion `xen_enabled()' failed. Aborted (core dumped) $ After: $ qemu-system-x86_64 -device xen-platform qemu-system-x86_64: -device xen-platform: xen-platform device requires the Xen accelerator $ Signed-off-by: Eduardo Habkost Reviewed-by: Ste

[Qemu-devel] [PULL 1/3] Qemu/Xen: Fix early freeing MSIX MMIO memory region

2015-10-26 Thread Stefano Stabellini
will access msix->mmio's obj. But the whole msix struct has already been freed by xen_pt_msix_delete. This will cause segment fault when msix->mmio has been overwritten. This patch is to fix the issue. Signed-off-by: Lan Tianyu Reviewed-by: Stefano Stabellini Signed-off-by: Stefano Stabe

[Qemu-devel] [PULL 2/3] xen_platform: switch to realize

2015-10-26 Thread Stefano Stabellini
Use realize to initialize the xen_platform device Signed-off-by: Stefano Stabellini Signed-off-by: Eduardo Habkost --- hw/i386/xen/xen_platform.c |6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/hw/i386/xen/xen_platform.c b/hw/i386/xen/xen_platform.c index 8682c42

[Qemu-devel] [PULL 0/3] xen-2015-10-26

2015-10-26 Thread Stefano Stabellini
2015-10-26 Eduardo Habkost (1): xen-platform: Replace assert() with appropriate error reporting Lan Tianyu (1): Qemu/Xen: Fix early freeing MSIX MMIO memory region Stefano Stabellini (1): xen_platform: switch to realize hw/i386/xen/xen_platform

Re: [Qemu-devel] [PATCH v2 2/2] xen-platform: Replace assert() with appropriate error reporting

2015-10-26 Thread Stefano Stabellini
On Wed, 21 Oct 2015, Eduardo Habkost wrote: > Commit dbb7405d8caad0814ceddd568cb49f163a847561 made it possible to > trigger an assert using "-device xen-platform". Replace it with > appropriate error reporting. > > Before: > > $ qemu-system-x86_64 -device xen-platform > qemu-system-x86_64: hw

Re: [Qemu-devel] [PATCH v2 1/2] xen_platform: switch to realize

2015-10-26 Thread Stefano Stabellini
On Wed, 21 Oct 2015, Eduardo Habkost wrote: > From: Stefano Stabellini > > Use realize to initialize the xen_platform device > > Signed-off-by: Stefano Stabellini > Signed-off-by: Eduardo Habkost Applied to my tree > Changes v1 -> v2: > * Remove useless retur

Re: [Qemu-devel] [PATCH QEMU-XEN v4 9/9] xen: make it possible to build without the Xen PV domain builder

2015-10-23 Thread Stefano Stabellini
On Fri, 23 Oct 2015, Ian Campbell wrote: > On Fri, 2015-10-23 at 12:12 +0100, Stefano Stabellini wrote: > > @@ -2113,6 +2117,15 @@ if test "$xen_pci_passthrough" != "no"; then > > >fi > > > fi > > > > > > +if test "$xen

Re: [Qemu-devel] [PATCH QEMU-XEN v4 7/9] xen: Use stable library interfaces when they are available.

2015-10-23 Thread Stefano Stabellini
On Wed, 21 Oct 2015, Ian Campbell wrote: > In Xen 4.7 we are refactoring parts libxenctrl into a number of > separate libraries which will provide backward and forward API and ABI > compatiblity. > > Specifically libxenevtchn, libxengnttab and libxenforeignmemory. > > Previous patches have alread

Re: [Qemu-devel] [PATCH QEMU-XEN v4 9/9] xen: make it possible to build without the Xen PV domain builder

2015-10-23 Thread Stefano Stabellini
On Wed, 21 Oct 2015, Ian Campbell wrote: > Until the previous patch this relied on xc_fd(), which was only > implemented for Xen 4.0 and earlier. > > Given this wasn't working since Xen 4.0 I have marked this as disabled > by default. > > Removing this support drops the use of a bunch of symbols

Re: [Qemu-devel] [PATCH QEMU-XEN v4 4/9] xen: Switch uses of xc_map_foreign_range into xc_map_foreign_bulk

2015-10-23 Thread Stefano Stabellini
use a temporary xen_pfn_t to in > effect upcast the pointer from int* to xen_pfn_t*. > > Build tested with 4.0 and 4.5. > > Signed-off-by: Ian Campbell Reviewed-by: Stefano Stabellini > v4: Ran checkpatch, fixed all errors > Mention the const-ness of the

Re: [Qemu-devel] [PATCH QEMU-XEN v4 6/9] xen: Switch uses of xc_map_foreign_bulk to use libxenforeignmemory API.

2015-10-23 Thread Stefano Stabellini
dding an extra API to > the libxenforeignmemory interface to replace a foreign mapping with > anonymous shared memory, but I'd prefer not to. > > Build tested with 4.0 and 4.5. > > Signed-off-by: Ian Campbell Reviewed-by: Stefano Stabellini > I noticed in

Re: [Qemu-devel] [PATCH QEMU-XEN v4 3/9] xen: Switch to libxengnttab interface for compat shims.

2015-10-23 Thread Stefano Stabellini
On Wed, 21 Oct 2015, Ian Campbell wrote: > In Xen 4.7 we are refactoring parts libxenctrl into a number of > separate libraries which will provide backward and forward API and ABI > compatiblity. > > One such library will be libxengnttab which provides access to grant > tables. > > In preparation

Re: [Qemu-devel] [PATCH QEMU-XEN v4 2/9] xen: Switch to libxenevtchn interface for compat shims.

2015-10-23 Thread Stefano Stabellini
> Note that this patch does not add any support for actually using > libxenevtchn, it just adjusts the existing shims. > > Note that xc_evtchn_alloc_unbound functionality remains in libxenctrl, > since that functionality is not exposed by /dev/xen/evtchn. > > Signed-off-by:

Re: [Qemu-devel] [PATCH QEMU-XEN v4 1/9] xen_console: correctly cleanup primary console on teardown.

2015-10-22 Thread Stefano Stabellini
> Signed-off-by: Ian Campbell Reviewed-by: Stefano Stabellini > v4: New patch based on feedback to "xen: Switch uses of > xc_map_foreign_bulk to use libxenforeignmemory API." > --- > hw/char/xen_console.c | 7 ++- > 1 file changed, 2 insertions(+), 5 deletions(-

Re: [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-20 Thread Stefano Stabellini
On Tue, 20 Oct 2015, Laszlo Ersek wrote: > On 10/20/15 13:59, Stefano Stabellini wrote: > > On Mon, 19 Oct 2015, Laszlo Ersek wrote: > >> Could that be related to the issue you are experiencing with OVMF? > >> Because, OVMF implies HVM (or PV-on-HVM), and your report (

Re: [Qemu-devel] [PATCH] xen: fix invalid assertion

2015-10-20 Thread Stefano Stabellini
On Mon, 19 Oct 2015, Paolo Bonzini wrote: > Asserting "true" is not that useful. > > Reported by Coverity. > > Signed-off-by: Paolo Bonzini Acked-by: Stefano Stabellini > hw/xen/xen_pt_config_init.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deleti

Re: [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-20 Thread Stefano Stabellini
On Mon, 19 Oct 2015, Laszlo Ersek wrote: > On 10/16/15 21:09, Laszlo Ersek wrote: > > On 10/16/15 13:34, Fabio Fantoni wrote: > >> Il 16/10/2015 12:47, Stefano Stabellini ha scritto: > >>> On Fri, 16 Oct 2015, Fabio Fantoni wrote: > >>>> Il 16/10/2015

Re: [Qemu-devel] [PATCH] xen-platform: Replace assert() with appropriate error reporting

2015-10-20 Thread Stefano Stabellini
On Mon, 19 Oct 2015, Paolo Bonzini wrote: > On 19/10/2015 20:39, Eduardo Habkost wrote: > > Commit dbb7405d8caad0814ceddd568cb49f163a847561 made it possible to > > trigger an assert using "-device xen-platform". Replace it with > > appropriate error reporting. > > > > Before: > > > > $ qemu-sys

[Qemu-devel] [PATCH] xen_platform: switch to realize

2015-10-19 Thread Stefano Stabellini
Use realize to initialize the xen_platform device Signed-off-by: Stefano Stabellini diff --git a/hw/i386/xen/xen_platform.c b/hw/i386/xen/xen_platform.c index 8682c42..5bb701f 100644 --- a/hw/i386/xen/xen_platform.c +++ b/hw/i386/xen/xen_platform.c @@ -382,7 +382,7 @@ static const

Re: [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-19 Thread Stefano Stabellini
On Mon, 19 Oct 2015, John Snow wrote: > On 10/19/2015 07:44 AM, Stefano Stabellini wrote: > > On Mon, 19 Oct 2015, Gerd Hoffmann wrote: > >> Hi, > >> > >>>> I'm trying to follow this discussion as best as I am able, but my lack > >>>>

Re: [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-19 Thread Stefano Stabellini
On Mon, 19 Oct 2015, Fabio Fantoni wrote: > Il 19/10/2015 12:18, Stefano Stabellini ha scritto: > > On Fri, 16 Oct 2015, John Snow wrote: > > > On 10/13/2015 01:10 PM, Stefano Stabellini wrote: > > > > On Tue, 13 Oct 2015, John Snow wrote: > > > > >

Re: [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-19 Thread Stefano Stabellini
On Mon, 19 Oct 2015, Gerd Hoffmann wrote: > Hi, > > > > I'm trying to follow this discussion as best as I am able, but my lack > > > of experience with Xen prevents me from really participating in a > > > meaningful way. > > > > > > (I see that Laszlo is still discussing some CD-ROM issues with

[Qemu-devel] [PULL 1/2] pc: Require xen when initializing xenfv machine

2015-10-19 Thread Stefano Stabellini
From: Eduardo Habkost Without this check, the xen-platform device will crash on reset if using the accel option with anything other than xen (e.g. "-machine xenfv,accel=kvm"). Signed-off-by: Eduardo Habkost Reviewed-by: Stefano Stabellini Signed-off-by: Stefano Stabellini --

[Qemu-devel] [PULL 2/2] xen-platform: Ensure xen is enabled when initializing

2015-10-19 Thread Stefano Stabellini
tpluggable, and the only code creating it (at pc_xen_hvm_init()) already checks xen_enabled(). Signed-off-by: Eduardo Habkost Reviewed-by: Stefano Stabellini Signed-off-by: Stefano Stabellini --- hw/i386/xen/xen_platform.c |3 +++ 1 file changed, 3 insertions(+) diff --git a/h

[Qemu-devel] [PULL 0/2] Xen 2015-10-19-tag

2015-10-19 Thread Stefano Stabellini
The following changes since commit aedc8806172dd1ae904f04169ee3b19fce1d7893: Merge remote-tracking branch 'remotes/kraxel/tags/pull-audio-20151019-1' into staging (2015-10-19 10:06:56 +0100) are available in the git repository at: git://xenbits.xen.org/people/sstabellini/qemu-dm.git tags/2

Re: [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-19 Thread Stefano Stabellini
On Fri, 16 Oct 2015, John Snow wrote: > On 10/13/2015 01:10 PM, Stefano Stabellini wrote: > > On Tue, 13 Oct 2015, John Snow wrote: > >> On 10/13/2015 11:55 AM, Fabio Fantoni wrote: > >>> I added ahci disk support in libxl and using it for week seems that was >

Re: [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-16 Thread Stefano Stabellini
io Fantoni wrote: > > > > > Il 14/10/2015 13:06, Stefano Stabellini ha scritto: > > > > > > I would suggest Fabio to avoid AHCI disks altogether and just use > > > > > > OVMF > > > > > > with PV disks only and Anthony's

Re: [Qemu-devel] [Xen-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-16 Thread Stefano Stabellini
On Fri, 16 Oct 2015, Laszlo Ersek wrote: > On 10/16/15 11:06, Stefano Stabellini wrote: > > On Thu, 15 Oct 2015, Kevin O'Connor wrote: > >> On Fri, Oct 16, 2015 at 01:10:54AM +0200, Laszlo Ersek wrote: > >>> On 10/14/15 13:27, Ian Campbell wrote: > >>&

Re: [Qemu-devel] [Xen-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-16 Thread Stefano Stabellini
On Thu, 15 Oct 2015, Kevin O'Connor wrote: > On Fri, Oct 16, 2015 at 01:10:54AM +0200, Laszlo Ersek wrote: > > On 10/14/15 13:27, Ian Campbell wrote: > > > On Wed, 2015-10-14 at 12:06 +0100, Stefano Stabellini wrote: > > >>> Can't you just teach SeaB

Re: [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-14 Thread Stefano Stabellini
On Wed, 14 Oct 2015, Kevin Wolf wrote: > Am 14.10.2015 um 13:06 hat Stefano Stabellini geschrieben: > > On Wed, 14 Oct 2015, Kevin Wolf wrote: > > > [ CC qemu-block ] > > > > > > Am 13.10.2015 um 19:10 hat Stefano Stabellini geschrieben: > > > > On

Re: [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-14 Thread Stefano Stabellini
On Wed, 14 Oct 2015, Kevin Wolf wrote: > [ CC qemu-block ] > > Am 13.10.2015 um 19:10 hat Stefano Stabellini geschrieben: > > On Tue, 13 Oct 2015, John Snow wrote: > > > On 10/13/2015 11:55 AM, Fabio Fantoni wrote: > > > > I added ahci disk support in libxl

Re: [Qemu-devel] Question about xen disk unplug support for ahci missed in qemu

2015-10-13 Thread Stefano Stabellini
On Tue, 13 Oct 2015, John Snow wrote: > On 10/13/2015 11:55 AM, Fabio Fantoni wrote: > > I added ahci disk support in libxl and using it for week seems that was > > ok, after a reply of Stefano Stabellini seems that xen disk unplug > > support only ide disks: > > http:/

Re: [Qemu-devel] [PATCH] Qemu/Xen: Fix early freeing MSIX MMIO memory region

2015-10-12 Thread Stefano Stabellini
On Mon, 12 Oct 2015, Paolo Bonzini wrote: > On 12/10/2015 13:09, Stefano Stabellini wrote: > > On Sun, 11 Oct 2015, Lan Tianyu wrote: > >> From: > > >> > >> msix->mmio is added to XenPCIPassthroughState's object as property. &g

Re: [Qemu-devel] [PATCH] Qemu/Xen: Fix early freeing MSIX MMIO memory region

2015-10-12 Thread Stefano Stabellini
On Sun, 11 Oct 2015, Lan Tianyu wrote: > From: > > > msix->mmio is added to XenPCIPassthroughState's object as property. > object_finalize_child_property is called for XenPCIPassthroughState's > object, which calls object_property_del_all, which is going to try to > delete msix->mmio. object_final

Re: [Qemu-devel] [v4][PATCH 2/2] libxl: introduce gfx_passthru_kind

2015-10-06 Thread Stefano Stabellini
On Fri, 25 Sep 2015, Ian Campbell wrote: > On Fri, 2015-09-18 at 16:30 +0800, Tiejun Chen wrote: > > Although we already have 'gfx_passthru' in b_info, this doesn't suffice > > after we want to handle IGD specifically. Now we define a new field of > > type, gfx_passthru_kind, to indicate we're tryi

Re: [Qemu-devel] [Fix PATCH] Qemu/Xen: Fix early freeing MSIX MMIO memory region

2015-10-06 Thread Stefano Stabellini
On Tue, 6 Oct 2015, Paolo Bonzini wrote: > On 05/10/2015 18:53, Stefano Stabellini wrote: > >> This patch is to fix the issue via moving MSIX MMIO memory region into > >> struct XenPCIPassthroughState and free it together with pt device's obj. > > > > Given

Re: [Qemu-devel] [Fix PATCH] Qemu/Xen: Fix early freeing MSIX MMIO memory region

2015-10-05 Thread Stefano Stabellini
Hi Lan, thanks for the patch. On Wed, 30 Sep 2015, Lan Tianyu wrote: > MSIX MMIO memory region is added to pt device's obj as property. msix->mmio is added to XenPCIPassthroughState's object as property > When pt device is unplugged, all properties will be deleted and > memory region's obj is n

Re: [Qemu-devel] qemu-system-arm: xen-domid not supported for this target

2015-10-02 Thread Stefano Stabellini
On Fri, 2 Oct 2015, Peter Maydell wrote: > On 2 October 2015 at 07:27, Alexander B. Ustinov > wrote: > > Hello, list. Hi! > > I'm trying to get arm guest running on amd64 dom0 system. Unfortunately it is not possible to run ARM guests on an x86 system with Xen. > > Problem i stumbled upon is

Re: [Qemu-devel] [PATCH 1/2] pc: Require xen when initializing xenfv machine

2015-09-30 Thread Stefano Stabellini
On Mon, 28 Sep 2015, Eduardo Habkost wrote: > Without this check, the xen-platform device will crash on reset > if using the accel option with anything other than xen (e.g. > "-machine xenfv,accel=kvm"). > > Signed-off-by: Eduardo Habkost Reviewed-by: Stefano Stabelli

Re: [Qemu-devel] [PATCH 2/2] xen-platform: Ensure xen is enabled when initializing

2015-09-30 Thread Stefano Stabellini
gered by the user because the device is not > hotpluggable, and the only code creating it (at pc_xen_hvm_init()) > already checks xen_enabled(). > > Signed-off-by: Eduardo Habkost Reviewed-by: Stefano Stabellini > hw/i386/xen/xen_platform.c | 3 +++ > 1 file changed, 3

Re: [Qemu-devel] [PATCH 0/2] xen: Fix crash of "-machine xenfv, accel=kvm"

2015-09-30 Thread Stefano Stabellini
On Mon, 28 Sep 2015, Eduardo Habkost wrote: > This series fixes the following crash: > > $ ./x86_64-softmmu/qemu-system-x86_64 -machine xenfv,accel=kvm > Segmentation fault (core dumped) > > The crash happens because xen-platform calls xc_hvm_set_mem_type() with a NULL > xen_xc on reset, at p

Re: [Qemu-devel] [Xen-devel] [PULL 0/19] xen-2015-09-08-tag

2015-09-29 Thread Stefano Stabellini
On Mon, 28 Sep 2015, Pasi Kärkkäinen wrote: > Hi, > > On Mon, Sep 28, 2015 at 11:01:11AM +0100, Stefano Stabellini wrote: > > No, unfortunately it is not possible at this stage of the release cycle. > > But users can still use QEMU 2.5 (as soon as it is released, which >

<    5   6   7   8   9   10   11   12   13   14   >