[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] virtio-scsi-pci iothread spins at 100%
From: |
Fam Zheng |
Subject: |
Re: [Qemu-devel] virtio-scsi-pci iothread spins at 100% |
Date: |
Thu, 9 Feb 2017 09:47:28 +0800 |
User-agent: |
Mutt/1.7.1 (2016-10-04) |
On Wed, 02/08 08:33, Ed Swierk wrote:
> Recently I noticed that when I configure a virtio-scsi-pci device
> using an iothread, as soon as the guest virtio-scsi driver loads, the
> iothread spins at 100%:
>
> -object iothread,id=iothread1 -device virtio-scsi-pci,iothread=iothread1
>
> This occurs whether or not a disk is attached, with either
> poll-max-ns=0 or poll-max-ns=32768, and with Linux 3.13, 4.1 and 4.4
> guests. The iothread stops spinning as soon as the guest driver is
> unloaded.
>
> I bisected the issue to commit 684e508c23d28af8d6ed2c62738a0f60447c8274:
>
> aio: add .io_poll_begin/end() callbacks
>
> It doesn't seem to affect performance, but obviously consuming CPU
> cycles when there's no disk attached is undesirable. Is this an
> expected side effect of implementing iothread polling?
No, something is wrong. The polling shouldn't keep running when there is no I/O
activity.
Can you try "perf top" to see what poll handlers are spinning?
Fam