From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755124AbYIJToZ (ORCPT ); Wed, 10 Sep 2008 15:44:25 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752173AbYIJToQ (ORCPT ); Wed, 10 Sep 2008 15:44:16 -0400 Received: from gw.goop.org ([64.81.55.164]:58415 "EHLO mail.goop.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752168AbYIJToQ (ORCPT ); Wed, 10 Sep 2008 15:44:16 -0400 Message-ID: <48C8238D.4080803@goop.org> Date: Wed, 10 Sep 2008 12:44:13 -0700 From: Jeremy Fitzhardinge User-Agent: Thunderbird 2.0.0.16 (X11/20080723) MIME-Version: 1.0 To: "Eric W. Biederman" CC: Yinghai Lu , Ingo Molnar , Linux Kernel Mailing List Subject: Re: TARGET_CPUS in assign_irq_vector References: <48C6F913.1010509@goop.org> <86802c440809091554y349366fdu8e4ca59797ab4205@mail.gmail.com> <48C70ADC.8060004@goop.org> <86802c440809091726y4db8f85eg2d478b482862c5f9@mail.gmail.com> <48C719C0.6060201@goop.org> In-Reply-To: X-Enigmail-Version: 0.95.7 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Eric W. Biederman wrote: > Jeremy Fitzhardinge writes: > > >> 3) give up because the idea is fundamentally ill-conceived, or 4) >> something else? >> > > Yes. > > When working with event channels you should not have any > truck with vectors and you should not call the architecture > specific do_IRQ(). Hm. That would work OK for fully paravirtualized domains, which have no direct access to real hardware in any form (well, there's pci passthough, but interrupts are all thoroughly massaged into event channels). But for dom0, the kernel handles interrupts weird hybrid mode. The interrupts themselves are delivered via event channels rather than via a local apic, but the IO APIC is still under the kernel's control, and is responsible for poking (Xen-allocated) vectors into it. This only applies to physical irq event channels; there's no need to have vectors for purely software event channels like interdomain, IPI and timers. This is further complicated by the fact that the dom0 kernel parses the ACPI and MPTABLES to find out about IO APICs, so the existing APIC subsystem is already involved. I need to work out how'd I'd hook all this together with a minimum of mess. J