public inbox for linux-arm-kernel@lists.infradead.org 
 help / color / mirror / Atom feed
From: heiko@sntech•de (Heiko Stübner)
To: linux-arm-kernel@lists•infradead.org
Subject: [PATCH v2 11/11] ARM: S3C24XX: remove maskack irq ack funtions
Date: Tue, 1 Jan 2013 22:59:58 +0100	[thread overview]
Message-ID: <201301012259.58754.heiko@sntech.de> (raw)
In-Reply-To: <201301012251.15899.heiko@sntech.de>

In the past level irqs provided a special ack handler that also masked
the interrupt. But handle_level_irq also does mask-ack the interrupt
itself, so there is no need to keep this special ack function around.

We therefore can simplyfy the number of irq-chips again.

Signed-off-by: Heiko Stuebner <heiko@sntech•de>
---
 arch/arm/plat-s3c24xx/irq.c |   41 +++++++++--------------------------------
 1 files changed, 9 insertions(+), 32 deletions(-)

diff --git a/arch/arm/plat-s3c24xx/irq.c b/arch/arm/plat-s3c24xx/irq.c
index 8cba552..0516cbc 100644
--- a/arch/arm/plat-s3c24xx/irq.c
+++ b/arch/arm/plat-s3c24xx/irq.c
@@ -128,12 +128,6 @@ static inline void s3c_irq_ack(struct irq_data *data)
 		__raw_writel(bitval, intc->reg_intpnd);
 }
 
-static inline void s3c_irq_maskack(struct irq_data *data)
-{
-	s3c_irq_mask(data);
-	s3c_irq_ack(data);
-}
-
 #ifdef CONFIG_PM
 /* state for IRQs over sleep
  *
@@ -164,22 +158,6 @@ int s3c_irq_wake(struct irq_data *data, unsigned int state)
 }
 #endif
 
-struct irq_chip s3c_irq_level_chip = {
-	.name		= "s3c-level",
-	.irq_ack	= s3c_irq_maskack,
-	.irq_mask	= s3c_irq_mask,
-	.irq_unmask	= s3c_irq_unmask,
-	.irq_set_wake	= s3c_irq_wake
-};
-
-struct irq_chip s3c_irq_chip = {
-	.name		= "s3c",
-	.irq_ack	= s3c_irq_ack,
-	.irq_mask	= s3c_irq_mask,
-	.irq_unmask	= s3c_irq_unmask,
-	.irq_set_wake	= s3c_irq_wake
-};
-
 static int s3c_irqext_type_set(void __iomem *gpcon_reg,
 			       void __iomem *extint_reg,
 			       unsigned long gpcon_offset,
@@ -299,17 +277,16 @@ static struct irq_chip s3c_irq_eint0t4 = {
 	.irq_set_type	= s3c_irqext0_type,
 };
 
-/* used for UARTs */
-static struct irq_chip s3c_irq_sublevel_chip = {
-	.name		= "s3c-sublevel",
+struct irq_chip s3c_irq_chip = {
+	.name		= "s3c",
+	.irq_ack	= s3c_irq_ack,
 	.irq_mask	= s3c_irq_mask,
 	.irq_unmask	= s3c_irq_unmask,
-	.irq_ack	= s3c_irq_maskack,
+	.irq_set_wake	= s3c_irq_wake
 };
 
-/* used for ADC and Touchscreen */
-static struct irq_chip s3c_irq_subedge_chip = {
-	.name		= "s3c-subedge",
+static struct irq_chip s3c_irq_general_chip = {
+	.name		= "s3c-general",
 	.irq_mask	= s3c_irq_mask,
 	.irq_unmask	= s3c_irq_unmask,
 	.irq_ack	= s3c_irq_ack,
@@ -412,7 +389,7 @@ static int s3c24xx_irq_map(struct irq_domain *h, unsigned int virq,
 	case S3C_IRQTYPE_EDGE:
 		if (irq_data->parent_irq ||
 		    intc->reg_pending == S3C2416_SRCPND2)
-			irq_set_chip_and_handler(virq, &s3c_irq_subedge_chip,
+			irq_set_chip_and_handler(virq, &s3c_irq_general_chip,
 						 handle_edge_irq);
 		else
 			irq_set_chip_and_handler(virq, &s3c_irq_chip,
@@ -420,10 +397,10 @@ static int s3c24xx_irq_map(struct irq_domain *h, unsigned int virq,
 		break;
 	case S3C_IRQTYPE_LEVEL:
 		if (irq_data->parent_irq)
-			irq_set_chip_and_handler(virq, &s3c_irq_sublevel_chip,
+			irq_set_chip_and_handler(virq, &s3c_irq_general_chip,
 						 handle_level_irq);
 		else
-			irq_set_chip_and_handler(virq, &s3c_irq_level_chip,
+			irq_set_chip_and_handler(virq, &s3c_irq_chip,
 						 handle_level_irq);
 		break;
 	default:
-- 
1.7.2.3

  parent reply	other threads:[~2013-01-01 21:59 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-01 21:51 [PATCH v2 00/11] ARM: S3C24XX: rework irq handling for a later dt usage Heiko Stübner
2013-01-01 21:52 ` [PATCH v2 01/11] ARM: S3C24XX: transform irq handling into a declarative form Heiko Stübner
2013-01-01 21:53 ` [PATCH v2 02/11] ARM: S3C24XX: move irq-pm code into main irq file Heiko Stübner
2013-01-01 21:54 ` [PATCH v2 03/11] ARM: S3C24XX: cleanup irq-pm integration Heiko Stübner
2013-01-01 21:55 ` [PATCH v2 04/11] ARM: S3C24XX: move s3c2416 irq init to common irq code Heiko Stübner
2013-01-01 21:55 ` [PATCH v2 05/11] ARM: S3C24XX: modify s3c2416 irq init to initialize all irqs Heiko Stübner
2013-01-01 21:56 ` [PATCH v2 06/11] ARM: S3C24XX: assimilate s3c2416 subirqs into new structure Heiko Stübner
2013-01-01 21:57 ` [PATCH v2 07/11] ARM: S3C24XX: assimilate second s3c2416 interrupt " Heiko Stübner
2013-01-01 21:58 ` [PATCH v2 08/11] ARM: S3C24XX: move s3c2443 irq code to irq.c Heiko Stübner
2013-01-01 21:58 ` [PATCH v2 09/11] ARM: S3C24XX: modify s3c2443 irq init to initialize all irqs Heiko Stübner
2013-01-01 21:59 ` [PATCH v2 10/11] ARM: S3C24XX: assimilate s3c2443 subirqs into new structure Heiko Stübner
2013-01-01 21:59 ` Heiko Stübner [this message]
2013-01-02 23:34 ` [PATCH v2 00/11] ARM: S3C24XX: rework irq handling for a later dt usage Kukjin Kim
2013-01-03  0:48   ` Heiko Stübner

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=201301012259.58754.heiko@sntech.de \
    --to=heiko@sntech$(echo .)de \
    --cc=linux-arm-kernel@lists$(echo .)infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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