Re: [PATCH] virtio_mmio: add ACPI probing

2015-07-28 Thread Peter Maydell
On 28 July 2015 at 11:08, Michael S. Tsirkin m...@redhat.com wrote: On Tue, Jul 28, 2015 at 10:44:02AM +0100, Graeme Gregory wrote: Added the match table and pointers for ACPI probing to the driver. This uses the same identifier for virt devices as being used for qemu ARM64 ACPI support.

[PULL] vhost: cleanups and fixes

2015-07-28 Thread Michael S. Tsirkin
The following changes since commit cbfe8fa6cd672011c755c3cd85c9ffd4e2d10a6f: Linux 4.2-rc4 (2015-07-26 12:26:21 -0700) are available in the git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost.git tags/for_linus for you to fetch changes up to

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Christian Borntraeger
Am 28.07.2015 um 03:08 schrieb Andy Lutomirski: On Mon, Sep 1, 2014 at 10:39 AM, Andy Lutomirski l...@amacapital.net wrote: This fixes virtio on Xen guests as well as on any other platform that uses virtio_pci on which physical addresses don't match bus addresses. This can be tested with:

Re: [PATCH] virtio_mmio: add ACPI probing

2015-07-28 Thread Michael S. Tsirkin
On Tue, Jul 28, 2015 at 10:44:02AM +0100, Graeme Gregory wrote: Added the match table and pointers for ACPI probing to the driver. This uses the same identifier for virt devices as being used for qemu ARM64 ACPI support.

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Paolo Bonzini
On 28/07/2015 03:08, Andy Lutomirski wrote: On Mon, Sep 1, 2014 at 10:39 AM, Andy Lutomirski l...@amacapital.net wrote: This fixes virtio on Xen guests as well as on any other platform that uses virtio_pci on which physical addresses don't match bus addresses. This can be tested with:

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Andy Lutomirski
On Tue, Jul 28, 2015 at 4:21 PM, Benjamin Herrenschmidt b...@kernel.crashing.org wrote: On Tue, 2015-07-28 at 15:43 -0700, Andy Lutomirski wrote: Let me try to summarize a proposal: Add a feature flag that indicates IOMMU support. New kernels acknowledge that flag on any device that

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Benjamin Herrenschmidt
On Tue, 2015-07-28 at 17:47 -0700, Andy Lutomirski wrote: Yes, virtio flag. I dislike having a virtio flag at all, but so far no one has come up with any better ideas. If there was a reliable, cross-platform mechanism for per-device PCI bus properties, I'd be all for using that instead.

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Benjamin Herrenschmidt
On Tue, 2015-07-28 at 15:43 -0700, Andy Lutomirski wrote: Let me try to summarize a proposal: Add a feature flag that indicates IOMMU support. New kernels acknowledge that flag on any device that advertises it. New kernels always respect the IOMMU (except on PowerPC). Why ? I disagree,

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Benjamin Herrenschmidt
On Tue, 2015-07-28 at 16:33 -0700, Andy Lutomirski wrote: On Tue, Jul 28, 2015 at 4:21 PM, Benjamin Herrenschmidt b...@kernel.crashing.org wrote: On Tue, 2015-07-28 at 15:43 -0700, Andy Lutomirski wrote: Let me try to summarize a proposal: Add a feature flag that indicates IOMMU support.

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Andy Lutomirski
Let me try to summarize a proposal: Add a feature flag that indicates IOMMU support. New kernels acknowledge that flag on any device that advertises it. New kernels always respect the IOMMU (except on PowerPC). New kernels optionally refuse to talk to devices that don't have that feature flag

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Andy Lutomirski
On Tue, Jul 28, 2015 at 5:36 PM, Benjamin Herrenschmidt b...@kernel.crashing.org wrote: On Tue, 2015-07-28 at 16:33 -0700, Andy Lutomirski wrote: On Tue, Jul 28, 2015 at 4:21 PM, Benjamin Herrenschmidt b...@kernel.crashing.org wrote: On Tue, 2015-07-28 at 15:43 -0700, Andy Lutomirski wrote:

Re: [PATCH] virtio_mmio: add ACPI probing

2015-07-28 Thread Michael S. Tsirkin
On Tue, Jul 28, 2015 at 11:12:33AM +0100, Peter Maydell wrote: On 28 July 2015 at 11:08, Michael S. Tsirkin m...@redhat.com wrote: On Tue, Jul 28, 2015 at 10:44:02AM +0100, Graeme Gregory wrote: Added the match table and pointers for ACPI probing to the driver. This uses the same

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Jan Kiszka
On 2015-07-28 15:06, Michael S. Tsirkin wrote: On Tue, Jul 28, 2015 at 02:46:20PM +0200, Paolo Bonzini wrote: On 28/07/2015 12:12, Benjamin Herrenschmidt wrote: That is an experimental feature (it's x-iommu), so it can change. The plan was: - for PPC, virtio never honors IOMMU - for

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Michael S. Tsirkin
On Tue, Jul 28, 2015 at 02:46:20PM +0200, Paolo Bonzini wrote: On 28/07/2015 12:12, Benjamin Herrenschmidt wrote: That is an experimental feature (it's x-iommu), so it can change. The plan was: - for PPC, virtio never honors IOMMU - for non-PPC, either have virtio

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Andy Lutomirski
On Jul 28, 2015 6:11 AM, Jan Kiszka jan.kis...@siemens.com wrote: On 2015-07-28 15:06, Michael S. Tsirkin wrote: On Tue, Jul 28, 2015 at 02:46:20PM +0200, Paolo Bonzini wrote: On 28/07/2015 12:12, Benjamin Herrenschmidt wrote: That is an experimental feature (it's x-iommu), so it can

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Benjamin Herrenschmidt
On Tue, 2015-07-28 at 10:16 +0200, Paolo Bonzini wrote: On 28/07/2015 03:08, Andy Lutomirski wrote: On Mon, Sep 1, 2014 at 10:39 AM, Andy Lutomirski l...@amacapital.net wrote: This fixes virtio on Xen guests as well as on any other platform that uses virtio_pci on which physical

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Paolo Bonzini
On 28/07/2015 12:12, Benjamin Herrenschmidt wrote: That is an experimental feature (it's x-iommu), so it can change. The plan was: - for PPC, virtio never honors IOMMU - for non-PPC, either have virtio always honor IOMMU, or enforce that virtio is not under IOMMU. I

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Paolo Bonzini
On 28/07/2015 15:11, Jan Kiszka wrote: This doesn't matter much, since the only guests that implement an IOMMU in QEMU are (afaik) PPC and x86, and x86 does not yet promise any kind of stability. Hmm I think Jan (cc) said it was already used out there. Yes, no known issues with

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Andy Lutomirski
On Tue, Jul 28, 2015 at 9:44 AM, Jan Kiszka jan.kis...@siemens.com wrote: The ability to have virtio on systems with IOMMU in place makes testing much more efficient for us. Ideally, we would have it in non-identity mapping scenarios as well, e.g. to start secondary Linux instances in the test

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Paolo Bonzini
On 28/07/2015 18:42, Jan Kiszka wrote: On the other hand interrupt remapping is absolutely necessary for production use, hence my point that x86 does not promise API stability. Well, we currently implement the features that the Q35 used to expose. Adding interrupt remapping will require

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Paolo Bonzini
On 28/07/2015 19:19, Jan Kiszka wrote: On 2015-07-28 19:15, Paolo Bonzini wrote: On 28/07/2015 18:42, Jan Kiszka wrote: On the other hand interrupt remapping is absolutely necessary for production use, hence my point that x86 does not promise API stability. Well, we currently implement

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Jan Kiszka
On 2015-07-28 19:15, Paolo Bonzini wrote: On 28/07/2015 18:42, Jan Kiszka wrote: On the other hand interrupt remapping is absolutely necessary for production use, hence my point that x86 does not promise API stability. Well, we currently implement the features that the Q35 used to expose.

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Jan Kiszka
On 2015-07-28 18:36, Paolo Bonzini wrote: On 28/07/2015 15:11, Jan Kiszka wrote: This doesn't matter much, since the only guests that implement an IOMMU in QEMU are (afaik) PPC and x86, and x86 does not yet promise any kind of stability. Hmm I think Jan (cc) said it was already used out

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Jan Kiszka
On 2015-07-28 19:10, Andy Lutomirski wrote: On Tue, Jul 28, 2015 at 9:44 AM, Jan Kiszka jan.kis...@siemens.com wrote: The ability to have virtio on systems with IOMMU in place makes testing much more efficient for us. Ideally, we would have it in non-identity mapping scenarios as well, e.g. to

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Jan Kiszka
On 2015-07-28 18:11, Andy Lutomirski wrote: On Jul 28, 2015 6:11 AM, Jan Kiszka jan.kis...@siemens.com wrote: On 2015-07-28 15:06, Michael S. Tsirkin wrote: On Tue, Jul 28, 2015 at 02:46:20PM +0200, Paolo Bonzini wrote: On 28/07/2015 12:12, Benjamin Herrenschmidt wrote: That is an

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Jan Kiszka
On 2015-07-28 20:22, Andy Lutomirski wrote: On Tue, Jul 28, 2015 at 10:17 AM, Jan Kiszka jan.kis...@siemens.com wrote: On 2015-07-28 19:10, Andy Lutomirski wrote: The trouble is that this is really a property of the bus and not of the device. If you build a virtio device that physically plugs

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Andy Lutomirski
On Tue, Jul 28, 2015 at 10:17 AM, Jan Kiszka jan.kis...@siemens.com wrote: On 2015-07-28 19:10, Andy Lutomirski wrote: The trouble is that this is really a property of the bus and not of the device. If you build a virtio device that physically plugs into a PCIe slot, the device has no concept

Re: [PATCH] virtio_mmio: add ACPI probing

2015-07-28 Thread Peter Maydell
On 28 July 2015 at 11:27, Michael S. Tsirkin m...@redhat.com wrote: On Tue, Jul 28, 2015 at 11:12:33AM +0100, Peter Maydell wrote: On 28 July 2015 at 11:08, Michael S. Tsirkin m...@redhat.com wrote: On Tue, Jul 28, 2015 at 10:44:02AM +0100, Graeme Gregory wrote: Added the match table and

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Andy Lutomirski
On Tue, Jul 28, 2015 at 12:06 PM, Jan Kiszka jan.kis...@siemens.com wrote: On 2015-07-28 20:22, Andy Lutomirski wrote: On Tue, Jul 28, 2015 at 10:17 AM, Jan Kiszka jan.kis...@siemens.com wrote: On 2015-07-28 19:10, Andy Lutomirski wrote: The trouble is that this is really a property of the bus

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Jan Kiszka
On 2015-07-28 21:24, Andy Lutomirski wrote: On Tue, Jul 28, 2015 at 12:06 PM, Jan Kiszka jan.kis...@siemens.com wrote: On 2015-07-28 20:22, Andy Lutomirski wrote: On Tue, Jul 28, 2015 at 10:17 AM, Jan Kiszka jan.kis...@siemens.com wrote: On 2015-07-28 19:10, Andy Lutomirski wrote: The trouble

Re: [PATCH] virtio_mmio: add ACPI probing

2015-07-28 Thread Peter Maydell
On 28 July 2015 at 21:28, G Gregory graeme.greg...@linaro.org wrote: On 28 July 2015 at 21:12, Peter Maydell peter.mayd...@linaro.org wrote: Mmm. I'm not terribly happy about stuff being in QEMU before the ACPI spec for it has been finalised. We should not be picking stuff randomly on the

Re: [PATCH v4 0/4] virtio: Clean up scatterlists and use the DMA API

2015-07-28 Thread Andy Lutomirski
On Tue, Jul 28, 2015 at 12:33 PM, Jan Kiszka jan.kis...@siemens.com wrote: On 2015-07-28 21:24, Andy Lutomirski wrote: On Tue, Jul 28, 2015 at 12:06 PM, Jan Kiszka jan.kis...@siemens.com wrote: On 2015-07-28 20:22, Andy Lutomirski wrote: On Tue, Jul 28, 2015 at 10:17 AM, Jan Kiszka