linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jiang Liu <jiang.liu@linux.intel.com>
To: Thomas Gleixner <tglx@linutronix.de>,
	Bjorn Helgaas <bhelgaas@google.com>,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	Ingo Molnar <mingo@redhat.com>, "H. Peter Anvin" <hpa@zytor.com>,
	"Rafael J. Wysocki" <rjw@rjwysocki.net>,
	Randy Dunlap <rdunlap@infradead.org>,
	Yinghai Lu <yinghai@kernel.org>, Borislav Petkov <bp@alien8.de>,
	Geert Uytterhoeven <geert@linux-m68k.org>,
	Joshua Thompson <funaho@jurai.org>,
	Jiang Liu <jiang.liu@linux.intel.com>
Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>,
	Tony Luck <tony.luck@intel.com>,
	x86@kernel.org, linux-kernel@vger.kernel.org,
	linux-pci@vger.kernel.org, linux-acpi@vger.kernel.org,
	linux-m68k@lists.linux-m68k.org
Subject: [RFC v1 18/25] genirq: Kill the first parameter 'irq' of irq_flow_handler_t
Date: Wed, 20 May 2015 18:00:06 +0800	[thread overview]
Message-ID: <1432116013-25902-19-git-send-email-jiang.liu@linux.intel.com> (raw)
In-Reply-To: <1432116013-25902-1-git-send-email-jiang.liu@linux.intel.com>

Now most IRQ flow handlers make no use of the first parameter 'irq'.
And for those who do make use of 'irq', we could easily get the irq
number through irq_desc->irq_data->irq. So kill the first parameter
'irq' of irq_flow_handler_t.

To ease review, I have split the changes into several parts, though
they should be merge as one to support bisecting.

Signed-off-by: Jiang Liu <jiang.liu@linux.intel.com>
---
 arch/m68k/amiga/amiints.c       |    8 ++++----
 arch/m68k/coldfire/intc-5272.c  |    4 ++--
 arch/m68k/include/asm/mac_via.h |    2 +-
 arch/m68k/mac/baboon.c          |    2 +-
 arch/m68k/mac/oss.c             |    4 ++--
 arch/m68k/mac/psc.c             |    3 ++-
 arch/m68k/mac/via.c             |    6 +++---
 7 files changed, 15 insertions(+), 14 deletions(-)

diff --git a/arch/m68k/amiga/amiints.c b/arch/m68k/amiga/amiints.c
index 47b5f90002ab..7ff739e94896 100644
--- a/arch/m68k/amiga/amiints.c
+++ b/arch/m68k/amiga/amiints.c
@@ -46,7 +46,7 @@ static struct irq_chip amiga_irq_chip = {
  * The builtin Amiga hardware interrupt handlers.
  */
 
-static void ami_int1(unsigned int irq, struct irq_desc *desc)
+static void ami_int1(struct irq_desc *desc)
 {
 	unsigned short ints = amiga_custom.intreqr & amiga_custom.intenar;
 
@@ -69,7 +69,7 @@ static void ami_int1(unsigned int irq, struct irq_desc *desc)
 	}
 }
 
-static void ami_int3(unsigned int irq, struct irq_desc *desc)
+static void ami_int3(struct irq_desc *desc)
 {
 	unsigned short ints = amiga_custom.intreqr & amiga_custom.intenar;
 
@@ -92,7 +92,7 @@ static void ami_int3(unsigned int irq, struct irq_desc *desc)
 	}
 }
 
-static void ami_int4(unsigned int irq, struct irq_desc *desc)
+static void ami_int4(struct irq_desc *desc)
 {
 	unsigned short ints = amiga_custom.intreqr & amiga_custom.intenar;
 
@@ -121,7 +121,7 @@ static void ami_int4(unsigned int irq, struct irq_desc *desc)
 	}
 }
 
-static void ami_int5(unsigned int irq, struct irq_desc *desc)
+static void ami_int5(struct irq_desc *desc)
 {
 	unsigned short ints = amiga_custom.intreqr & amiga_custom.intenar;
 
diff --git a/arch/m68k/coldfire/intc-5272.c b/arch/m68k/coldfire/intc-5272.c
index d1e2fbad327c..b0a19e207a63 100644
--- a/arch/m68k/coldfire/intc-5272.c
+++ b/arch/m68k/coldfire/intc-5272.c
@@ -143,10 +143,10 @@ static int intc_irq_set_type(struct irq_data *d, unsigned int type)
  * We need to be careful with the masking/acking due to the side effects
  * of masking an interrupt.
  */
-static void intc_external_irq(unsigned int irq, struct irq_desc *desc)
+static void intc_external_irq(struct irq_desc *desc)
 {
 	irq_desc_get_chip(desc)->irq_ack(&desc->irq_data);
-	handle_simple_irq(irq, desc);
+	handle_simple_irq(desc);
 }
 
 static struct irq_chip intc_irq_chip = {
diff --git a/arch/m68k/include/asm/mac_via.h b/arch/m68k/include/asm/mac_via.h
index fe3fc9ae1b69..53c632c85b03 100644
--- a/arch/m68k/include/asm/mac_via.h
+++ b/arch/m68k/include/asm/mac_via.h
@@ -261,7 +261,7 @@ extern void via_irq_enable(int);
 extern void via_irq_disable(int);
 extern void via_nubus_irq_startup(int irq);
 extern void via_nubus_irq_shutdown(int irq);
-extern void via1_irq(unsigned int irq, struct irq_desc *desc);
+extern void via1_irq(struct irq_desc *desc);
 extern void via1_set_head(int);
 extern int via2_scsi_drq_pending(void);
 
diff --git a/arch/m68k/mac/baboon.c b/arch/m68k/mac/baboon.c
index 3fe0e43d44f6..f6f7d42713ec 100644
--- a/arch/m68k/mac/baboon.c
+++ b/arch/m68k/mac/baboon.c
@@ -45,7 +45,7 @@ void __init baboon_init(void)
  * Baboon interrupt handler. This works a lot like a VIA.
  */
 
-static void baboon_irq(unsigned int irq, struct irq_desc *desc)
+static void baboon_irq(struct irq_desc *desc)
 {
 	int irq_bit, irq_num;
 	unsigned char events;
diff --git a/arch/m68k/mac/oss.c b/arch/m68k/mac/oss.c
index bb11dceed7ed..1fe868166a9c 100644
--- a/arch/m68k/mac/oss.c
+++ b/arch/m68k/mac/oss.c
@@ -63,7 +63,7 @@ void __init oss_nubus_init(void)
  * Handle miscellaneous OSS interrupts.
  */
 
-static void oss_irq(unsigned int irq, struct irq_desc *desc)
+static void oss_irq(struct irq_desc *desc)
 {
 	int events = oss->irq_pending &
 	             (OSS_IP_IOPSCC | OSS_IP_SCSI | OSS_IP_IOPISM);
@@ -97,7 +97,7 @@ static void oss_irq(unsigned int irq, struct irq_desc *desc)
  * Unlike the VIA/RBV this is on its own autovector interrupt level.
  */
 
-static void oss_nubus_irq(unsigned int irq, struct irq_desc *desc)
+static void oss_nubus_irq(struct irq_desc *desc)
 {
 	int events, irq_bit, i;
 
diff --git a/arch/m68k/mac/psc.c b/arch/m68k/mac/psc.c
index 835fa04511c8..23ddaa07fa0e 100644
--- a/arch/m68k/mac/psc.c
+++ b/arch/m68k/mac/psc.c
@@ -113,8 +113,9 @@ void __init psc_init(void)
  * PSC interrupt handler. It's a lot like the VIA interrupt handler.
  */
 
-static void psc_irq(unsigned int irq, struct irq_desc *desc)
+static void psc_irq(struct irq_desc *desc)
 {
+	unsigned int irq = irq_desc_get_irq(desc);
 	unsigned int offset = (unsigned int)irq_desc_get_handler_data(desc);
 	int pIFR	= pIFRbase + offset;
 	int pIER	= pIERbase + offset;
diff --git a/arch/m68k/mac/via.c b/arch/m68k/mac/via.c
index e198dec868e4..979ea8312db8 100644
--- a/arch/m68k/mac/via.c
+++ b/arch/m68k/mac/via.c
@@ -446,7 +446,7 @@ void via_nubus_irq_shutdown(int irq)
  * via6522.c :-), disable/pending masks added.
  */
 
-void via1_irq(unsigned int irq, struct irq_desc *desc)
+void via1_irq(struct irq_desc *desc)
 {
 	int irq_num;
 	unsigned char irq_bit, events;
@@ -467,7 +467,7 @@ void via1_irq(unsigned int irq, struct irq_desc *desc)
 	} while (events >= irq_bit);
 }
 
-static void via2_irq(unsigned int irq, struct irq_desc *desc)
+static void via2_irq(struct irq_desc *desc)
 {
 	int irq_num;
 	unsigned char irq_bit, events;
@@ -493,7 +493,7 @@ static void via2_irq(unsigned int irq, struct irq_desc *desc)
  * VIA2 dispatcher as a fast interrupt handler.
  */
 
-void via_nubus_irq(unsigned int irq, struct irq_desc *desc)
+void via_nubus_irq(struct irq_desc *desc)
 {
 	int slot_irq;
 	unsigned char slot_bit, events;
-- 
1.7.10.4


  parent reply	other threads:[~2015-05-20 10:04 UTC|newest]

Thread overview: 69+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-20  9:59 [RFC v1 00/25] Optimize irq flow handler Jiang Liu
2015-05-20  9:59 ` [RFC v1 01/25] ARM, irq: Use irq_desc_get_xxx() to avoid redundant lookup of irq_desc Jiang Liu
2015-05-20 19:35   ` Russell King - ARM Linux
2015-05-20  9:59 ` [RFC v1 02/25] avr32, " Jiang Liu
2015-05-20 10:15   ` Hans-Christian Egtvedt
2015-05-20  9:59 ` [RFC v1 03/25] MIPS, " Jiang Liu
2015-05-20  9:59 ` [RFC v1 04/25] powerpc, " Jiang Liu
2015-05-20  9:59 ` [RFC v1 05/25] gpio: " Jiang Liu
2015-06-01 12:45   ` Linus Walleij
2015-06-01 13:48     ` Jiang Liu
2015-05-20  9:59 ` [RFC v1 06/25] pinctrl: " Jiang Liu
2015-05-20  9:59 ` [RFC v1 07/25] irqchip: " Jiang Liu
2015-05-20  9:59 ` [RFC v1 08/25] mfd: " Jiang Liu
2015-05-20 10:44   ` Lee Jones
2015-05-20  9:59 ` [RFC v1 09/25] ipu: " Jiang Liu
2015-05-20  9:59 ` [RFC v1 10/25] sh: intc: " Jiang Liu
2015-05-20 15:12   ` Thomas Gleixner
2015-05-20 15:24     ` Jiang Liu
2015-05-20  9:59 ` [RFC v1 11/25] keystone, irq: Use irq_data_get_xxx() to avoid redundant lookup of irq_data Jiang Liu
2015-05-20 10:00 ` [RFC v1 12/25] spmi: Use irq_desc_get_xxx() to avoid redundant lookup of irq_desc Jiang Liu
2015-05-20 10:00 ` [RFC v1 13/25] genirq: Kill the parameter 'irq' of kstat_incr_irqs_this_cpu() Jiang Liu
2015-05-20 15:23   ` Thomas Gleixner
2015-05-20 10:00 ` [RFC v1 14/25] genirq: Kill the first parameter 'irq' of irq_flow_handler_t Jiang Liu
2015-05-20 15:25   ` Thomas Gleixner
2015-05-20 15:28     ` Jiang Liu
2015-05-20 18:35       ` Thomas Gleixner
2015-05-20 20:00         ` Julia Lawall
2015-05-20 20:12           ` Thomas Gleixner
2015-05-20 20:15             ` Julia Lawall
2015-05-20 20:22               ` Thomas Gleixner
2015-06-12 20:29                 ` Julia Lawall
2015-06-12 20:35                   ` Thomas Gleixner
2015-06-12 22:16                     ` Julia Lawall
2015-06-13  8:27         ` Julia Lawall
2015-06-13  9:00         ` Julia Lawall
2015-06-13  9:32           ` Thomas Gleixner
2015-06-13 14:04             ` Julia Lawall
2015-06-13 14:53               ` Julia Lawall
2015-06-13 16:49                 ` Jiang Liu
2015-06-13 20:15                   ` Julia Lawall
2015-06-13 20:32                     ` Thomas Gleixner
2015-06-13 20:42                       ` Julia Lawall
2015-06-24 21:10                         ` Thomas Gleixner
2015-06-24 21:44                           ` Julia Lawall
2015-06-13 21:42                       ` Julia Lawall
2015-05-20 18:36       ` Thomas Gleixner
2015-05-20 10:00 ` [RFC v1 15/25] " Jiang Liu
2015-05-20 15:28   ` Thomas Gleixner
2015-05-20 15:32     ` Jiang Liu
2015-05-20 15:48       ` Thomas Gleixner
2015-05-20 15:38   ` Hans Ulli Kroll
2015-05-20 18:54   ` Robert Jarzmik
2015-05-20 10:00 ` [RFC v1 16/25] " Jiang Liu
2015-05-20 10:00 ` [RFC v1 17/25] " Jiang Liu
2015-05-20 10:00 ` Jiang Liu [this message]
2015-05-20 10:00 ` [RFC v1 19/25] " Jiang Liu
2015-05-20 10:00 ` [RFC v1 20/25] " Jiang Liu
2015-05-20 10:16   ` Hans-Christian Egtvedt
2015-05-20 10:00 ` [RFC v1 21/25] " Jiang Liu
2015-05-20 10:00 ` [RFC v1 22/25] " Jiang Liu
2015-05-20 10:00 ` [RFC v1 23/25] " Jiang Liu
2015-05-20 10:00 ` [RFC v1 24/25] " Jiang Liu
2015-05-20 10:43   ` Lee Jones
2015-05-20 10:00 ` [RFC v1 25/25] " Jiang Liu
2015-05-20 15:40   ` Thomas Gleixner
2015-05-20 15:49     ` Jiang Liu
2015-05-20 18:43       ` Thomas Gleixner
2015-05-20 10:16 ` [RFC v1 00/25] Optimize irq flow handler Ingo Molnar
2015-05-20 10:23   ` Jiang Liu

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1432116013-25902-19-git-send-email-jiang.liu@linux.intel.com \
    --to=jiang.liu@linux.intel.com \
    --cc=benh@kernel.crashing.org \
    --cc=bhelgaas@google.com \
    --cc=bp@alien8.de \
    --cc=funaho@jurai.org \
    --cc=geert@linux-m68k.org \
    --cc=hpa@zytor.com \
    --cc=konrad.wilk@oracle.com \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-m68k@lists.linux-m68k.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=mingo@redhat.com \
    --cc=rdunlap@infradead.org \
    --cc=rjw@rjwysocki.net \
    --cc=tglx@linutronix.de \
    --cc=tony.luck@intel.com \
    --cc=x86@kernel.org \
    --cc=yinghai@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).