From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: Qemu interrupt handling Date: Fri, 17 Aug 2007 15:56:57 +0300 Message-ID: <46C59B19.5050407@qumranet.com> References: <1695.157.27.242.184.1187345108.squirrel@157.27.242.184> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org To: saggin-O91pjutqpDaRIi+8W+d3eg@public.gmane.org Return-path: In-Reply-To: <1695.157.27.242.184.1187345108.squirrel-EqM2KoRJkMdNABFEJvf7Pw@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org saggin-O91pjutqpDaRIi+8W+d3eg@public.gmane.org wrote: > Hi, > I would like to ask a question about how Qemu handle interrupt in user space. > I would like to understand how Qemu catch hardware interrupt generated by > real (host) peripheral. > I look at the Qemu code, (vl.c : main_loop and main_loop_wait) and I can't > identify where Qemu listens and catches the interrupts, for example, from > host NIC in order to pass to the guest NIC emulated. > > Could you help me? > > This is really more suitable for qemu-devel. In general, qemu doesn't trap the real hardware interrupt; it waits for a signal (or select()) indicating that there are packets waiting to be received. Depending on how the emulated nic is configured, there may or may not be a virtual interrupt generated. -- Do not meddle in the internals of kernels, for they are subtle and quick to panic. ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/