From: Stefan Hajnoczi <stefanha@gmail.com>
To: Naredula Janardhana Reddy <naredula.jana@gmail.com>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] using MSIX for virtio-blk
Date: Thu, 9 Jul 2015 12:01:55 +0100 [thread overview]
Message-ID: <20150709110155.GF28530@stefanha-thinkpad.redhat.com> (raw)
In-Reply-To: <CABSNWZyoEqCAWJ8sTDnJo98+M4jCeRUM9BxS4Oxs6+0WFWs_wg@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1235 bytes --]
On Tue, Jul 07, 2015 at 10:50:59PM +0530, Naredula Janardhana Reddy wrote:
> How to enable MSIX for virtio-blk, this is to avoid extra use of
> VIRTIO_PCI_ISR port reads.
> This is for qemu 2.3.0 with virtio-blk-pci with x-data-plane is on.
I tried the following with QEMU 2.3.0:
qemu-system-x86_64 -enable-kvm -m 1024 \
-drive if=none,id=drive0,file=test.img,format=raw,aio=native,cache=none \
-object iothread,id=iothread0 \
-device virtio-blk-pci,drive=drive0,iothread=iothread0
Inside the guest I checked /proc/interrupts and found that the
virtio-pci/virtio-blk driver is using MSI.
I also checked /proc/ioports and found the virtio-pci registers at
0xc040.
Then I used "perf record -a -e kvm:kvm_pio" on the host to record all
PIO accesses.
Inside the guest I ran "dd if=/dev/vda of=/dev/null iflag=direct bs=4k"
for about 30 seconds. Afterwards I ran "perf script" on the host and
subtracted the 0xc040 base address from the PIO accesses to identify the
virtio-pci registers.
I didn't see any accesses to the ISR register, only writes to the
QUEUE_NOTIFY register.
Either your guest operating system is not enabling MSI or you are using
QEMU command-line options that prevent MSI.
[-- Attachment #2: Type: application/pgp-signature, Size: 473 bytes --]
next prev parent reply other threads:[~2015-07-09 11:02 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-07-07 17:20 [Qemu-devel] using MSIX for virtio-blk Naredula Janardhana Reddy
2015-07-09 11:01 ` Stefan Hajnoczi [this message]
2015-07-10 17:47 ` Naredula Janardhana Reddy
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=20150709110155.GF28530@stefanha-thinkpad.redhat.com \
--to=stefanha@gmail.com \
--cc=naredula.jana@gmail.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).