Received: from eggs.gnu.org ([2001:4830:134:3::10]:47476) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YqfOY-0008Ii-SJ for qemu-devel@nongnu.org; Fri, 08 May 2015 06:20:40 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YqfOV-00010C-Gy for qemu-devel@nongnu.org; Fri, 08 May 2015 06:20:38 -0400 Received: from e06smtp16.uk.ibm.com ([195.75.94.112]:46824) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YqfOV-0000zq-7N for qemu-devel@nongnu.org; Fri, 08 May 2015 06:20:35 -0400 Received: from /spool/local by e06smtp16.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 8 May 2015 11:20:33 +0100 Received: from b06cxnps3074.portsmouth.uk.ibm.com (d06relay09.portsmouth.uk.ibm.com [9.149.109.194]) by d06dlp02.portsmouth.uk.ibm.com (Postfix) with ESMTP id 0D4C92190046 for ; Fri, 8 May 2015 11:20:13 +0100 (BST) Received: from d06av10.portsmouth.uk.ibm.com (d06av10.portsmouth.uk.ibm.com [9.149.37.251]) by b06cxnps3074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id t48AKV3t786902 for ; Fri, 8 May 2015 10:20:31 GMT Received: from d06av10.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av10.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id t48AKV6W028550 for ; Fri, 8 May 2015 04:20:31 -0600 Date: Fri, 8 May 2015 12:20:29 +0200 From: Cornelia Huck Message-ID: <20150508122029.30e0311d.cornelia.huck@de.ibm.com> In-Reply-To: <00aa01d0895a$81d423d0$857c6b70$@samsung.com> References: <016001d088b3$8da9bfa0$a8fd3ee0$@samsung.com> <20150507153942.29afef5f.cornelia.huck@de.ibm.com> <00aa01d0895a$81d423d0$857c6b70$@samsung.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v2 2/3] virtio-mmio: introduce set_guest_notifiers List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Pavel Fedin Cc: qemu-devel@nongnu.org On Fri, 08 May 2015 09:45:00 +0300 Pavel Fedin wrote: > Hello! > > > Hm, weren't there some patches for irqfd on arm? > > Yes, there were. However, they had a design problem by breaking backwards compatibility > with unmodified virtio. Their idea was to set up one more shared memory area between > virtio and vhost-net and use it to pass ISR value, which helps to distinguish, which event > took place (queue update or config change). So, this idea was rejected. > http://lists.gnu.org/archive/html/qemu-devel/2014-10/msg03056.html > > I thought about it, and technically, i think, this can be done in better way. Actually, > as far as i understood, all we need is mechanism for distinguishing between these two > events. On PCI we do this by using multiple IRQs via MSI-X, and one IRQ signals exactly > one type of event. MSI-X code also has "two IRQs" mode as a failsafe, where one IRQ > signals config change and another IRQ signals queues update (and all queues are polled in > turn). I think a similar thing could be done for virtio-mmio. It could allocate two IRQs > instead of one and describe both of them in the device tree. Guest side, upon seeing that, > could make use of those two IRQs and acknowledge to the host side that "yes, i am new > version and use new mode". > But, sorry, i will unlikely implement this, because we already have PCI with MSI-X (i > hope this is going to be published soon), so my project can use PCI emulation. So > implementing irqfds for virtio-mmio is a bit out of my scope. Thanks for the explanation. Yes, I think it makes sense to just pick the low-hanging fruit for virtio-mmio and wait for pci.