[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api
From: |
David Woodhouse |
Subject: |
Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api |
Date: |
Wed, 27 Apr 2016 20:16:57 +0100 |
On Wed, 2016-04-27 at 21:17 +0300, Michael S. Tsirkin wrote:
>
> > Because it's a dirty hack in the *wrong* place.
>
> No one came up with a better one so far :(
Seriously?
Take a look at drivers/iommu/intel-iommu.c. It has quirks for all kinds
of shitty devices that have to be put in passthrough mode or otherwise
excluded.
We don't actually *need* it for the Intel IOMMU; all we need is for
QEMU to stop lying in its DMAR tables.
We *do* want the same kind of quirks in the relevant POWER and ARM
IOMMU code in the kernel. Do that (hell, a simple quirk for all virtio
devices will suffice, but NOT in the virtio driver) at the same moment
you fix the virtio devices to use the DMA API. Job done.
Some time *later* we can work on *refining* that quirk, and a way for
QEMU to tell the guest (via something generic like fwcfg, maybe) that
some devices are and aren't translated.
Actually, I'm about to look at moving dma_ops into struct device and
cleaning up the way we detect which IOMMU is attached, at device
instantiation time. Perhaps I can shove the virtio-exception quirk in
there while I'm at it...
--
dwmw2
smime.p7s
Description: S/MIME cryptographic signature
- Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api, (continued)
- Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api, Andy Lutomirski, 2016/04/27
- Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api, Michael S. Tsirkin, 2016/04/27
- Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api, Joerg Roedel, 2016/04/27
- Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api, Michael S. Tsirkin, 2016/04/27
- Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api, David Woodhouse, 2016/04/27
- Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api, Michael S. Tsirkin, 2016/04/27
- Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api,
David Woodhouse <=
- Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api, Michael S. Tsirkin, 2016/04/28
- Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api, David Woodhouse, 2016/04/28
- Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api, Michael S. Tsirkin, 2016/04/28
- Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api, David Woodhouse, 2016/04/28
Re: [Qemu-devel] [PATCH V2 RFC] fixup! virtio: convert to use DMA api, Stefan Hajnoczi, 2016/04/21