From: Alexey Kardashevskiy <aik@ozlabs.ru>
To: Michael Roth <mdroth@linux.vnet.ibm.com>, qemu-devel@nongnu.org
Cc: "Michael S. Tsirkin" <mst@redhat.com>,
David Gibson <david@gibson.dropbear.id.au>
Subject: Re: virtio,iommu_platform=on
Date: Wed, 13 Nov 2019 17:35:47 +1100 [thread overview]
Message-ID: <839811b0-bb20-1026-208f-adaf38e5ac03@ozlabs.ru> (raw)
In-Reply-To: <e3d881ad-07e7-941a-7627-c8d9491d7029@ozlabs.ru>
On 13/11/2019 17:23, Alexey Kardashevskiy wrote:
>
>
> On 13/11/2019 16:54, Michael Roth wrote:
>> Quoting Alexey Kardashevskiy (2019-11-11 21:53:49)
>>> Hi!
>>>
>>> I am enabling IOMMU for virtio in the pseries firmware (SLOF) and seeing
>>> problems, one of them is SLOF does SCSI bus scan, then it stops the
>>> virtio-scsi by clearing MMIO|IO|BUSMASTER from PCI_COMMAND (as SLOF
>>> stopped using the devices) and when this happens, I see unassigned
>>> memory access (see below) which happens because disabling busmaster
>>> disables IOMMU and QEMU cannot access the rings to do some shutdown. And
>>> when this happens, the device does not come back even if SLOF re-enables it.
>>>
>>> Hacking SLOF to not clear BUSMASTER makes virtio-scsi work but it is
>>> hardly a right fix.
>>
>> I hit the same issue enabling IOMMU for virtio-blk using this branch:
>>
>> https://github.com/mdroth/SLOF/commits/virtio-iommu
>>
>> I just sent a tentative fix for QEMU as:
>>
>> "virtio-pci: disable vring processing when bus-mastering is disabled"
>>
>> It's an RFC since piggy-backing off dev->broken seems a bit hacky, but
>> it seems to fix the issue at least.
btw this fixes my issue with disabling bus master as well.
>>
>> BTW, the SLOF branch above needs cleanup, but it's booting guests okay
>> and I was planning to post this week. Where are you at on yours? Maybe
>> we should sync up...
>
>
> Mine is here: github.com:aik/SLOF.git virtio-iommu
>
> Still have to debug a lot, right now virtio-net does not work :-/
>
> Want to take over? :)
>
>
--
Alexey
prev parent reply other threads:[~2019-11-13 6:36 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-12 3:53 virtio,iommu_platform=on Alexey Kardashevskiy
2019-11-12 7:08 ` virtio,iommu_platform=on Michael S. Tsirkin
2019-11-13 4:44 ` virtio,iommu_platform=on Alexey Kardashevskiy
2019-11-13 10:00 ` virtio,iommu_platform=on Michael S. Tsirkin
2019-11-13 22:58 ` virtio,iommu_platform=on Alexey Kardashevskiy
2019-11-14 8:42 ` virtio,iommu_platform=on Michael S. Tsirkin
2019-11-15 1:43 ` virtio,iommu_platform=on Alexey Kardashevskiy
2019-11-12 9:06 ` virtio,iommu_platform=on Laszlo Ersek
2019-11-13 4:54 ` virtio,iommu_platform=on Alexey Kardashevskiy
2019-11-13 5:54 ` virtio,iommu_platform=on Michael Roth
2019-11-13 6:23 ` virtio,iommu_platform=on Alexey Kardashevskiy
2019-11-13 6:35 ` Alexey Kardashevskiy [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=839811b0-bb20-1026-208f-adaf38e5ac03@ozlabs.ru \
--to=aik@ozlabs.ru \
--cc=david@gibson.dropbear.id.au \
--cc=mdroth@linux.vnet.ibm.com \
--cc=mst@redhat.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).