From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wi0-x22c.google.com (mail-wi0-x22c.google.com [IPv6:2a00:1450:400c:c05::22c]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 1A4F51A01E3 for ; Sat, 18 Jul 2015 03:50:29 +1000 (AEST) Received: by widjy10 with SMTP id jy10so47064845wid.1 for ; Fri, 17 Jul 2015 10:50:25 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: References: <20150712215559.7166.33068.stgit@bhelgaas-glaptop2.roam.corp.google.com> <20150712220154.7166.48327.stgit@bhelgaas-glaptop2.roam.corp.google.com> From: Bjorn Helgaas Date: Fri, 17 Jul 2015 12:50:05 -0500 Message-ID: Subject: Re: [PATCH 1/3] x86, irq: Rename VECTOR_UNDEFINED and VECTOR_RETRIGGERED to IRQ_* To: Thomas Gleixner Cc: Linux-Arch , "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@lists.linux-m68k.org, linux-alpha@vger.kernel.org, "x86@kernel.org" , linuxppc-dev Content-Type: text/plain; charset=UTF-8 List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , On Fri, Jul 17, 2015 at 9:06 AM, Thomas Gleixner wrote: > 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. OK, I'll abandon this. Thanks for taking a look! Bjorn