Skip to content

Commit

Permalink
ARM: plat-versatile: move FPGA irq driver to drivers/irqchip
Browse files Browse the repository at this point in the history
This moves the Versatile FPGA interrupt controller driver, used in
the Integrator/AP, Integrator/CP and some Versatile boards, out
of arch/arm/plat-versatile and down to drivers/irqchip where we
have consensus that such drivers belong. The header file is
consequently moved to <linux/platform_data/irq-versatile-fpga.h>.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
  • Loading branch information
Linus Walleij committed Nov 4, 2012
1 parent da72a66 commit 2389d50
Show file tree
Hide file tree
Showing 10 changed files with 16 additions and 19 deletions.
4 changes: 2 additions & 2 deletions arch/arm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -284,8 +284,8 @@ config ARCH_INTEGRATOR
select MULTI_IRQ_HANDLER
select NEED_MACH_MEMORY_H
select PLAT_VERSATILE
select PLAT_VERSATILE_FPGA_IRQ
select SPARSE_IRQ
select VERSATILE_FPGA_IRQ
help
Support for ARM's Integrator platform.

Expand Down Expand Up @@ -318,7 +318,7 @@ config ARCH_VERSATILE
select PLAT_VERSATILE
select PLAT_VERSATILE_CLCD
select PLAT_VERSATILE_CLOCK
select PLAT_VERSATILE_FPGA_IRQ
select VERSATILE_FPGA_IRQ
help
This enables support for ARM Ltd Versatile board.

Expand Down
3 changes: 1 addition & 2 deletions arch/arm/mach-integrator/integrator_ap.c
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
#include <linux/clockchips.h>
#include <linux/interrupt.h>
#include <linux/io.h>
#include <linux/irqchip/versatile-fpga.h>
#include <linux/mtd/physmap.h>
#include <linux/clk.h>
#include <linux/platform_data/clk-integrator.h>
Expand All @@ -56,8 +57,6 @@
#include <asm/mach/pci.h>
#include <asm/mach/time.h>

#include <plat/fpga-irq.h>

#include "common.h"

/*
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-integrator/integrator_cp.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
#include <linux/amba/clcd.h>
#include <linux/amba/mmci.h>
#include <linux/io.h>
#include <linux/irqchip/versatile-fpga.h>
#include <linux/gfp.h>
#include <linux/mtd/physmap.h>
#include <linux/platform_data/clk-integrator.h>
Expand All @@ -46,7 +47,6 @@
#include <asm/hardware/timer-sp.h>

#include <plat/clcd.h>
#include <plat/fpga-irq.h>
#include <plat/sched_clock.h>

#include "common.h"
Expand Down
2 changes: 1 addition & 1 deletion arch/arm/mach-versatile/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@
#include <linux/amba/mmci.h>
#include <linux/amba/pl022.h>
#include <linux/io.h>
#include <linux/irqchip/versatile-fpga.h>
#include <linux/gfp.h>
#include <linux/clkdev.h>
#include <linux/mtd/physmap.h>
Expand All @@ -51,7 +52,6 @@
#include <asm/hardware/timer-sp.h>

#include <plat/clcd.h>
#include <plat/fpga-irq.h>
#include <plat/sched_clock.h>

#include "core.h"
Expand Down
9 changes: 0 additions & 9 deletions arch/arm/plat-versatile/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,6 @@ config PLAT_VERSATILE_CLOCK
config PLAT_VERSATILE_CLCD
bool

config PLAT_VERSATILE_FPGA_IRQ
bool
select IRQ_DOMAIN

config PLAT_VERSATILE_FPGA_IRQ_NR
int
default 4
depends on PLAT_VERSATILE_FPGA_IRQ

config PLAT_VERSATILE_LEDS
def_bool y if NEW_LEDS
depends on ARCH_REALVIEW || ARCH_VERSATILE
Expand Down
1 change: 0 additions & 1 deletion arch/arm/plat-versatile/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ ccflags-$(CONFIG_ARCH_MULTIPLATFORM) := -I$(srctree)/$(src)/include

obj-$(CONFIG_PLAT_VERSATILE_CLOCK) += clock.o
obj-$(CONFIG_PLAT_VERSATILE_CLCD) += clcd.o
obj-$(CONFIG_PLAT_VERSATILE_FPGA_IRQ) += fpga-irq.o
obj-$(CONFIG_PLAT_VERSATILE_LEDS) += leds.o
obj-$(CONFIG_PLAT_VERSATILE_SCHED_CLOCK) += sched-clock.o
obj-$(CONFIG_SMP) += headsmp.o platsmp.o
9 changes: 8 additions & 1 deletion drivers/irqchip/Kconfig
Original file line number Diff line number Diff line change
@@ -1 +1,8 @@
# empty
config VERSATILE_FPGA_IRQ
bool
select IRQ_DOMAIN

config VERSATILE_FPGA_IRQ_NR
int
default 4
depends on VERSATILE_FPGA_IRQ
1 change: 1 addition & 0 deletions drivers/irqchip/Makefile
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
obj-$(CONFIG_ARCH_BCM2835) += irq-bcm2835.o
obj-$(CONFIG_VERSATILE_FPGA_IRQ) += irq-versatile-fpga.o
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@
#include <linux/bitops.h>
#include <linux/irq.h>
#include <linux/io.h>
#include <linux/irqchip/versatile-fpga.h>
#include <linux/irqdomain.h>
#include <linux/module.h>
#include <linux/of.h>
#include <linux/of_address.h>

#include <asm/exception.h>
#include <asm/mach/irq.h>
#include <plat/fpga-irq.h>

#define IRQ_STATUS 0x00
#define IRQ_RAW_STATUS 0x04
Expand Down Expand Up @@ -42,7 +42,7 @@ struct fpga_irq_data {
};

/* we cannot allocate memory when the controllers are initially registered */
static struct fpga_irq_data fpga_irq_devices[CONFIG_PLAT_VERSATILE_FPGA_IRQ_NR];
static struct fpga_irq_data fpga_irq_devices[CONFIG_VERSATILE_FPGA_IRQ_NR];
static int fpga_irq_id;

static void fpga_irq_mask(struct irq_data *d)
Expand Down
File renamed without changes.

0 comments on commit 2389d50

Please sign in to comment.