aboutsummaryrefslogtreecommitdiff
path: root/arch/arm/mach-w90x900/irq.c
diff options
context:
space:
mode:
authorwanzongshun <mcuos.com@gmail.com>2009-08-21 07:07:46 +0100
committerRussell King <rmk+kernel@arm.linux.org.uk>2009-09-02 11:22:23 +0100
commit35c9221acb133ecc9abd701a1fb6fa909d177a77 (patch)
treee2a283112398450001410b5f3fa9a471c34738a7 /arch/arm/mach-w90x900/irq.c
parenta8bc4eadd936bbad9e99b89fe692679451ad75c9 (diff)
downloadlinux-2.6.34-ux500-35c9221acb133ecc9abd701a1fb6fa909d177a77.tar.gz
ARM: 5682/1: Add cpu.c and dev.c and modify some files of w90p910 platform
Add the cpu.c and dev.c and modify w90p910 platform to apply to use the common API(provided by cpu.c and dev.c) at the same time, I renamed all w90x900 to nuc900 in every c file of w90x900 platform and touchscreen's driver name. Signed-off-by: Wan ZongShun <mcuos.com@gmail.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-w90x900/irq.c')
-rw-r--r--arch/arm/mach-w90x900/irq.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/arch/arm/mach-w90x900/irq.c b/arch/arm/mach-w90x900/irq.c
index a296c9b81d2..0ce9d8e867e 100644
--- a/arch/arm/mach-w90x900/irq.c
+++ b/arch/arm/mach-w90x900/irq.c
@@ -36,13 +36,13 @@ struct group_irq {
static DEFINE_SPINLOCK(groupirq_lock);
-#define DEFINE_GROUP(_name, _ctrlbit, _num) \
-struct group_irq group_##_name = { \
- .enable = w90x900_group_enable, \
- .gpen = ((2 ^ _num) - 1) << _ctrlbit, \
+#define DEFINE_GROUP(_name, _ctrlbit, _num) \
+struct group_irq group_##_name = { \
+ .enable = nuc900_group_enable, \
+ .gpen = ((1 << _num) - 1) << _ctrlbit, \
}
-static void w90x900_group_enable(struct group_irq *gpirq, int enable);
+static void nuc900_group_enable(struct group_irq *gpirq, int enable);
static DEFINE_GROUP(nirq0, 0, 4);
static DEFINE_GROUP(nirq1, 4, 4);
@@ -77,7 +77,7 @@ static void group_irq_disable(struct group_irq *group_irq)
spin_unlock_irqrestore(&groupirq_lock, flags);
}
-static void w90x900_group_enable(struct group_irq *gpirq, int enable)
+static void nuc900_group_enable(struct group_irq *gpirq, int enable)
{
unsigned int groupen = gpirq->gpen;
unsigned long regval;
@@ -92,7 +92,7 @@ static void w90x900_group_enable(struct group_irq *gpirq, int enable)
__raw_writel(regval, REG_AIC_GEN);
}
-static void w90x900_irq_mask(unsigned int irq)
+static void nuc900_irq_mask(unsigned int irq)
{
struct group_irq *group_irq;
@@ -143,12 +143,12 @@ static void w90x900_irq_mask(unsigned int irq)
* to REG_AIC_EOSCR for ACK
*/
-static void w90x900_irq_ack(unsigned int irq)
+static void nuc900_irq_ack(unsigned int irq)
{
__raw_writel(0x01, REG_AIC_EOSCR);
}
-static void w90x900_irq_unmask(unsigned int irq)
+static void nuc900_irq_unmask(unsigned int irq)
{
struct group_irq *group_irq;
@@ -194,20 +194,20 @@ static void w90x900_irq_unmask(unsigned int irq)
group_irq_enable(group_irq);
}
-static struct irq_chip w90x900_irq_chip = {
- .ack = w90x900_irq_ack,
- .mask = w90x900_irq_mask,
- .unmask = w90x900_irq_unmask,
+static struct irq_chip nuc900_irq_chip = {
+ .ack = nuc900_irq_ack,
+ .mask = nuc900_irq_mask,
+ .unmask = nuc900_irq_unmask,
};
-void __init w90x900_init_irq(void)
+void __init nuc900_init_irq(void)
{
int irqno;
__raw_writel(0xFFFFFFFE, REG_AIC_MDCR);
for (irqno = IRQ_WDT; irqno <= IRQ_ADC; irqno++) {
- set_irq_chip(irqno, &w90x900_irq_chip);
+ set_irq_chip(irqno, &nuc900_irq_chip);
set_irq_handler(irqno, handle_level_irq);
set_irq_flags(irqno, IRQF_VALID);
}