Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757923AbbGQOHT (ORCPT ); Fri, 17 Jul 2015 10:07:19 -0400 Received: from www.linutronix.de ([62.245.132.108]:47599 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757828AbbGQOHO (ORCPT ); Fri, 17 Jul 2015 10:07:14 -0400 Date: Fri, 17 Jul 2015 16:06:54 +0200 (CEST) From: Thomas Gleixner To: Bjorn Helgaas cc: linux-arch@vger.kernel.org, linux-mips@linux-mips.org, linux-am33-list@redhat.com, linux-ia64@vger.kernel.org, linux-c6x-dev@linux-c6x.org, linux-parisc@vger.kernel.org, linux-s390@vger.kernel.org, linux-sh@vger.kernel.org, adi-buildroot-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org, linux-m68k@vger.kernel.org, linux-alpha@vger.kernel.org, x86@kernel.org, linuxppc-dev@lists.ozlabs.org Subject: Re: [PATCH 1/3] x86, irq: Rename VECTOR_UNDEFINED and VECTOR_RETRIGGERED to IRQ_* In-Reply-To: <20150712220154.7166.48327.stgit@bhelgaas-glaptop2.roam.corp.google.com> Message-ID: References: <20150712215559.7166.33068.stgit@bhelgaas-glaptop2.roam.corp.google.com> <20150712220154.7166.48327.stgit@bhelgaas-glaptop2.roam.corp.google.com> User-Agent: Alpine 2.11 (DEB 23 2013-08-11) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Linutronix-Spam-Score: -1.0 X-Linutronix-Spam-Level: - X-Linutronix-Spam-Status: No , -1.0 points, 5.0 required, ALL_TRUSTED=-1,SHORTCIRCUIT=-0.0001 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1312 Lines: 33 On Sun, 12 Jul 2015, Bjorn Helgaas wrote: > The per-cpu vector_irq[] table is indexed by CPU vector numbers, and each > entry contains an IRQ number. > > Rename the special values VECTOR_UNDEFINED and VECTOR_RETRIGGERED to > IRQ_UNDEFINED and IRQ_RETRIGGERED to indicate that they are in the IRQ > number space, not the CPU vector number space. Makes some sense, but OTOH vector_irq actually reflects the vector state not the irq number state. The fact that we store the Linux irq number in vector_irq is just an implementation detail. VECTOR_UNDEFINED is certainly a misnomer; that should be VECTOR_UNUSED VECTOR_RETRIGGERED is pretty accurate. In the case we retrigger an interrupt, we merily use the Linux irq number to figure out which vector to kick. And after we retriggered it, we lose the association to the Linux irq number completely. That said, I'm working on storing the irq descriptor pointer in vector_irq instead of the irq number, which has the advantage that we avoid the lookup of the irq descriptor in the interrupt hotpath. Thanks, tglx -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/