From: Milo Kim <milo.kim@ti.com>
To: <tglx@linutronix.de>
Cc: <jason@lakedaemon.net>, <marc.zyngier@arm.com>,
<alexandre.belloni@free-electrons.com>,
<boris.brezillon@free-electrons.com>,
<ludovic.desroches@atmel.com>, <nicolas.ferre@atmel.com>,
<linux-kernel@vger.kernel.org>, Milo Kim <milo.kim@ti.com>
Subject: [PATCH 18/19] irqchip: atmel-aic: use unified AIC driver
Date: Mon, 4 Jan 2016 13:28:42 +0900 [thread overview]
Message-ID: <1451881723-2478-19-git-send-email-milo.kim@ti.com> (raw)
In-Reply-To: <1451881723-2478-1-git-send-email-milo.kim@ti.com>
AIC and AIC5 use same driver file, so IRQ chip specific driver files can
be deleted.
aic_common_ext_irq_of_init() is renamed as aic_ext_irq_of_init().
Fix checkpatch warning.
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Jason Cooper <jason@lakedaemon.net>
Cc: Marc Zyngier <marc.zyngier@arm.com>
Cc: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Cc: Boris BREZILLON <boris.brezillon@free-electrons.com>
Cc: Ludovic Desroches <ludovic.desroches@atmel.com>
Cc: Nicolas Ferre <nicolas.ferre@atmel.com>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Milo Kim <milo.kim@ti.com>
---
drivers/irqchip/Makefile | 4 +--
drivers/irqchip/irq-atmel-aic-common.c | 10 +++---
drivers/irqchip/irq-atmel-aic.c | 54 ----------------------------
drivers/irqchip/irq-atmel-aic5.c | 64 ----------------------------------
4 files changed, 7 insertions(+), 125 deletions(-)
delete mode 100644 drivers/irqchip/irq-atmel-aic.c
delete mode 100644 drivers/irqchip/irq-atmel-aic5.c
diff --git a/drivers/irqchip/Makefile b/drivers/irqchip/Makefile
index 83d1fce..6e43333 100644
--- a/drivers/irqchip/Makefile
+++ b/drivers/irqchip/Makefile
@@ -28,8 +28,8 @@ obj-$(CONFIG_ARM_GIC_V3_ITS) += irq-gic-v3-its.o irq-gic-v3-its-pci-msi.o irq-g
obj-$(CONFIG_HISILICON_IRQ_MBIGEN) += irq-mbigen.o
obj-$(CONFIG_ARM_NVIC) += irq-nvic.o
obj-$(CONFIG_ARM_VIC) += irq-vic.o
-obj-$(CONFIG_ATMEL_AIC_IRQ) += irq-atmel-aic-common.o irq-atmel-aic.o
-obj-$(CONFIG_ATMEL_AIC5_IRQ) += irq-atmel-aic-common.o irq-atmel-aic5.o
+obj-$(CONFIG_ATMEL_AIC_IRQ) += irq-atmel-aic-common.o
+obj-$(CONFIG_ATMEL_AIC5_IRQ) += irq-atmel-aic-common.o
obj-$(CONFIG_I8259) += irq-i8259.o
obj-$(CONFIG_IMGPDC_IRQ) += irq-imgpdc.o
obj-$(CONFIG_IRQ_MIPS_CPU) += irq-mips-cpu.o
diff --git a/drivers/irqchip/irq-atmel-aic-common.c b/drivers/irqchip/irq-atmel-aic-common.c
index cd89d635..1d3978e 100644
--- a/drivers/irqchip/irq-atmel-aic-common.c
+++ b/drivers/irqchip/irq-atmel-aic-common.c
@@ -1,6 +1,5 @@
/*
- * Atmel AT91 common AIC (Advanced Interrupt Controller) code shared by
- * irq-atmel-aic and irq-atmel-aic5 drivers
+ * Atmel AIC (Advanced Interrupt Controller) Driver
*
* Copyright (C) 2004 SAN People
* Copyright (C) 2004 ATMEL
@@ -413,7 +412,8 @@ static void aic_pm_shutdown(struct irq_data *d)
if (aic_is_ssr_used()) {
irq_gc_lock(bgc);
for (i = 0; i < AIC_IRQS_PER_CHIP; i++) {
- irq_reg_writel(bgc, i + gc->irq_base, aic_reg_data->ssr);
+ irq_reg_writel(bgc, i + gc->irq_base,
+ aic_reg_data->ssr);
irq_reg_writel(bgc, 1, aic_reg_data->idcr);
irq_reg_writel(bgc, 1, aic_reg_data->iccr);
}
@@ -455,7 +455,7 @@ static int __init aic_get_num_chips(struct device_node *node)
return DIV_ROUND_UP(nirqs, AIC_IRQS_PER_CHIP);
}
-static void __init aic_common_ext_irq_of_init(struct irq_domain *domain)
+static void __init aic_ext_irq_of_init(struct irq_domain *domain)
{
struct device_node *node = irq_domain_get_of_node(domain);
struct irq_chip_generic *gc;
@@ -587,7 +587,7 @@ static int __init aic_of_init(struct device_node *node,
}
aic_domain = domain;
- aic_common_ext_irq_of_init(domain);
+ aic_ext_irq_of_init(domain);
aic_hw_init(domain);
set_handle_irq(aic_handle);
diff --git a/drivers/irqchip/irq-atmel-aic.c b/drivers/irqchip/irq-atmel-aic.c
deleted file mode 100644
index 335a94e..0000000
--- a/drivers/irqchip/irq-atmel-aic.c
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Atmel AT91 AIC (Advanced Interrupt Controller) driver
- *
- * Copyright (C) 2004 SAN People
- * Copyright (C) 2004 ATMEL
- * Copyright (C) Rick Bronson
- * Copyright (C) 2014 Free Electrons
- *
- * Author: Boris BREZILLON <boris.brezillon@free-electrons.com>
- *
- * This file is licensed under the terms of the GNU General Public
- * License version 2. This program is licensed "as is" without any
- * warranty of any kind, whether express or implied.
- */
-
-#include <linux/init.h>
-#include <linux/module.h>
-#include <linux/mm.h>
-#include <linux/bitmap.h>
-#include <linux/types.h>
-#include <linux/irq.h>
-#include <linux/irqchip.h>
-#include <linux/of.h>
-#include <linux/of_address.h>
-#include <linux/of_irq.h>
-#include <linux/irqdomain.h>
-#include <linux/err.h>
-#include <linux/slab.h>
-#include <linux/io.h>
-
-#include <asm/exception.h>
-#include <asm/mach/irq.h>
-
-/* Number of irq lines managed by AIC */
-#define NR_AIC_IRQS 32
-
-#define AT91_AIC_SMR(n) ((n) * 4)
-
-#define AT91_AIC_SVR(n) (0x80 + ((n) * 4))
-#define AT91_AIC_IVR 0x100
-#define AT91_AIC_FVR 0x104
-#define AT91_AIC_ISR 0x108
-
-#define AT91_AIC_IPR 0x10c
-#define AT91_AIC_IMR 0x110
-#define AT91_AIC_CISR 0x114
-
-#define AT91_AIC_IECR 0x120
-#define AT91_AIC_IDCR 0x124
-#define AT91_AIC_ICCR 0x128
-#define AT91_AIC_ISCR 0x12c
-#define AT91_AIC_EOICR 0x130
-#define AT91_AIC_SPU 0x134
-#define AT91_AIC_DCR 0x138
diff --git a/drivers/irqchip/irq-atmel-aic5.c b/drivers/irqchip/irq-atmel-aic5.c
deleted file mode 100644
index 082fdde..0000000
--- a/drivers/irqchip/irq-atmel-aic5.c
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Atmel AT91 AIC5 (Advanced Interrupt Controller) driver
- *
- * Copyright (C) 2004 SAN People
- * Copyright (C) 2004 ATMEL
- * Copyright (C) Rick Bronson
- * Copyright (C) 2014 Free Electrons
- *
- * Author: Boris BREZILLON <boris.brezillon@free-electrons.com>
- *
- * This file is licensed under the terms of the GNU General Public
- * License version 2. This program is licensed "as is" without any
- * warranty of any kind, whether express or implied.
- */
-
-#include <linux/init.h>
-#include <linux/module.h>
-#include <linux/mm.h>
-#include <linux/bitmap.h>
-#include <linux/types.h>
-#include <linux/irq.h>
-#include <linux/irqchip.h>
-#include <linux/of.h>
-#include <linux/of_address.h>
-#include <linux/of_irq.h>
-#include <linux/irqdomain.h>
-#include <linux/err.h>
-#include <linux/slab.h>
-#include <linux/io.h>
-
-#include <asm/exception.h>
-#include <asm/mach/irq.h>
-
-/* Number of irq lines managed by AIC */
-#define NR_AIC5_IRQS 128
-
-#define AT91_AIC5_SSR 0x0
-#define AT91_AIC5_INTSEL_MSK (0x7f << 0)
-
-#define AT91_AIC5_SMR 0x4
-
-#define AT91_AIC5_SVR 0x8
-#define AT91_AIC5_IVR 0x10
-#define AT91_AIC5_FVR 0x14
-#define AT91_AIC5_ISR 0x18
-
-#define AT91_AIC5_IPR0 0x20
-#define AT91_AIC5_IPR1 0x24
-#define AT91_AIC5_IPR2 0x28
-#define AT91_AIC5_IPR3 0x2c
-#define AT91_AIC5_IMR 0x30
-#define AT91_AIC5_CISR 0x34
-
-#define AT91_AIC5_IECR 0x40
-#define AT91_AIC5_IDCR 0x44
-#define AT91_AIC5_ICCR 0x48
-#define AT91_AIC5_ISCR 0x4c
-#define AT91_AIC5_EOICR 0x38
-#define AT91_AIC5_SPU 0x3c
-#define AT91_AIC5_DCR 0x6c
-
-#define AT91_AIC5_FFER 0x50
-#define AT91_AIC5_FFDR 0x54
-#define AT91_AIC5_FFSR 0x58
--
2.6.4
next prev parent reply other threads:[~2016-01-04 4:29 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-04 4:28 [PATCH 00/19] irqchip: atmel-aic: make " Milo Kim
2016-01-04 4:28 ` [PATCH 01/19] irqchip: atmel-aic: fix wrong bit operation for IRQ priority Milo Kim
2016-01-04 8:11 ` Boris Brezillon
2016-01-04 4:28 ` [PATCH 02/19] irqchip: atmel-aic: clean up RTC interrupt code Milo Kim
2016-01-04 8:16 ` Boris Brezillon
2016-01-04 4:28 ` [PATCH 03/19] irqchip: atmel-aic: clean up RTT " Milo Kim
2016-01-04 8:17 ` Boris Brezillon
2016-01-04 4:28 ` [PATCH 04/19] irqchip: atmel-aic: replace magic numbers with named constant Milo Kim
2016-01-04 8:29 ` Boris Brezillon
2016-01-04 4:28 ` [PATCH 05/19] irqchip: atmel-aic: use simple constant to get number of interrupts per chip Milo Kim
2016-01-04 8:33 ` Boris Brezillon
2016-01-04 4:28 ` [PATCH 06/19] irqchip: atmel-aic: introduce register data structure Milo Kim
2016-01-04 8:53 ` Boris Brezillon
2016-01-06 8:30 ` Milo Kim
2016-01-04 4:28 ` [PATCH 07/19] irqchip: atmel-aic: make common IRQ domain translate function Milo Kim
2016-01-04 4:28 ` [PATCH 08/19] irqchip: atmel-aic: add common mask and unmask functions Milo Kim
2016-01-04 8:48 ` Boris Brezillon
2016-01-04 4:28 ` [PATCH 09/19] irqchip: atmel-aic: add common retrigger function Milo Kim
2016-01-04 4:28 ` [PATCH 10/19] irqchip: atmel-aic: add common set_type function Milo Kim
2016-01-04 4:28 ` [PATCH 11/19] irqchip: atmel-aic: add common PM IRQ chip operation Milo Kim
2016-01-04 4:28 ` [PATCH 12/19] irqchip: atmel-aic: use EOI register data in aic_reg_data Milo Kim
2016-01-04 4:28 ` [PATCH 13/19] irqchip: atmel-aic: clean up irq_chip_generic Milo Kim
2016-01-04 4:28 ` [PATCH 14/19] irqchip: atmel-aic: add common HW init function Milo Kim
2016-01-04 4:28 ` [PATCH 15/19] irqchip: atmel-aic: add common interrupt handler Milo Kim
2016-01-04 4:28 ` [PATCH 16/19] irqchip: atmel-aic: get total number of IRQs from device node Milo Kim
2016-01-04 4:28 ` [PATCH 17/19] irqchip: atmel-aic: use unified IRQ chip initialization function Milo Kim
2016-01-04 4:28 ` Milo Kim [this message]
2016-01-04 4:28 ` [PATCH 19/19] irqchip: atmel-aic: rename AIC driver and fix Kconfig Milo Kim
2016-01-04 9:02 ` [PATCH 00/19] irqchip: atmel-aic: make unified AIC driver Boris Brezillon
2016-01-04 9:37 ` Nicolas Ferre
2016-01-06 7:55 ` Milo Kim
2016-01-06 7:48 ` Milo Kim
2016-01-06 9:07 ` Boris Brezillon
2016-01-06 14:49 ` Jason Cooper
2016-01-07 7:48 ` Milo Kim
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=1451881723-2478-19-git-send-email-milo.kim@ti.com \
--to=milo.kim@ti.com \
--cc=alexandre.belloni@free-electrons.com \
--cc=boris.brezillon@free-electrons.com \
--cc=jason@lakedaemon.net \
--cc=linux-kernel@vger.kernel.org \
--cc=ludovic.desroches@atmel.com \
--cc=marc.zyngier@arm.com \
--cc=nicolas.ferre@atmel.com \
--cc=tglx@linutronix.de \
/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
all inboxes | Powered by JetHome®