From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [PATCH v2] Shared memory device with interrupt support Date: Mon, 18 May 2009 20:19:18 +0300 Message-ID: <4A119896.80904@redhat.com> References: <3D9CB4061D1EB3408D4A0B910433453C030BCA8892@inbmail01.lsi.com> <5A459472-C496-49ED-93D8-0C4CC391F50A@cs.ualberta.ca> <4A1086E6.30405@redhat.com> <4A1191D6.6090105@cs.ualberta.ca> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: "kvm@vger.kernel.org list" , Gregory Haskins To: Cam Macdonell Return-path: Received: from mx2.redhat.com ([66.187.237.31]:36008 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751854AbZERRTW (ORCPT ); Mon, 18 May 2009 13:19:22 -0400 In-Reply-To: <4A1191D6.6090105@cs.ualberta.ca> Sender: kvm-owner@vger.kernel.org List-ID: Cam Macdonell wrote: > > My usual noob questions: Do I need to run Greg's tree on the host for > the necessary irqfd/eventfd suppport? Yes (though irqfd will be merged real soon, and iosignalfd somewhat afterwards). > Are there any examples to work from aside from Greg's unit tests? No. You don't really need to irqfd and iosignalfd to implement all of this, they're just optimizations. You can still pass the eventfds around. If you don't have irqfd, have qemu poll the eventfd, and when something happens, inject and interrupt. Likewise, if you don't have iosignalfd, register a pio/mmio handler for the command register, and when they fire touch all of the relevant irqfds. You'll need that anyway for backwards compatibility and for level-triggered pci interrupts, which irqfd doesn't support. -- Do not meddle in the internals of kernels, for they are subtle and quick to panic.