Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ARM: mxs: move icoll driver into drivers/irqchip

Move icoll.c into drivers/irqchip as irq-mxs.c, and along with the
renaming, change the driver to use IRQCHIP_DECLARE.

Signed-off-by: Shawn Guo <shawn.guo@linaro.org>

Shawn Guo 6a8e95b0 cec6bae8

+23 -16
+1 -1
arch/arm/mach-mxs/Makefile
··· 1 1 # Common support 2 - obj-y := icoll.o ocotp.o system.o mm.o 2 + obj-y := ocotp.o system.o mm.o 3 3 4 4 obj-$(CONFIG_PM) += pm.o 5 5
+3 -10
arch/arm/mach-mxs/icoll.c drivers/irqchip/irq-mxs.c
··· 27 27 #include <linux/stmp_device.h> 28 28 #include <asm/exception.h> 29 29 30 + #include "irqchip.h" 31 + 30 32 #define HW_ICOLL_VECTOR 0x0000 31 33 #define HW_ICOLL_LEVELACK 0x0010 32 34 #define HW_ICOLL_CTRL 0x0020 ··· 118 116 &icoll_irq_domain_ops, NULL); 119 117 WARN_ON(!icoll_domain); 120 118 } 121 - 122 - static const struct of_device_id icoll_of_match[] __initconst = { 123 - {.compatible = "fsl,icoll", .data = icoll_of_init}, 124 - { /* sentinel */ } 125 - }; 126 - 127 - void __init icoll_init_irq(void) 128 - { 129 - of_irq_init(icoll_of_match); 130 - } 119 + IRQCHIP_DECLARE(mxs, "fsl,icoll", icoll_of_init);
-3
arch/arm/mach-mxs/include/mach/common.h
··· 22 22 extern int mx28_clocks_init(void); 23 23 extern void mx28_map_io(void); 24 24 25 - extern void icoll_init_irq(void); 26 - extern void icoll_handle_irq(struct pt_regs *); 27 - 28 25 #endif /* __MACH_MXS_COMMON_H__ */
+4 -2
arch/arm/mach-mxs/mach-mxs.c
··· 18 18 #include <linux/err.h> 19 19 #include <linux/gpio.h> 20 20 #include <linux/init.h> 21 + #include <linux/irqchip.h> 22 + #include <linux/irqchip/mxs.h> 21 23 #include <linux/micrel_phy.h> 22 24 #include <linux/mxsfb.h> 23 25 #include <linux/of_platform.h> ··· 471 469 472 470 DT_MACHINE_START(IMX23, "Freescale i.MX23 (Device Tree)") 473 471 .map_io = mx23_map_io, 474 - .init_irq = icoll_init_irq, 472 + .init_irq = irqchip_init, 475 473 .handle_irq = icoll_handle_irq, 476 474 .init_time = imx23_timer_init, 477 475 .init_machine = mxs_machine_init, ··· 481 479 482 480 DT_MACHINE_START(IMX28, "Freescale i.MX28 (Device Tree)") 483 481 .map_io = mx28_map_io, 484 - .init_irq = icoll_init_irq, 482 + .init_irq = irqchip_init, 485 483 .handle_irq = icoll_handle_irq, 486 484 .init_time = imx28_timer_init, 487 485 .init_machine = mxs_machine_init,
+1
drivers/irqchip/Makefile
··· 2 2 3 3 obj-$(CONFIG_ARCH_BCM2835) += irq-bcm2835.o 4 4 obj-$(CONFIG_ARCH_EXYNOS) += exynos-combiner.o 5 + obj-$(CONFIG_ARCH_MXS) += irq-mxs.o 5 6 obj-$(CONFIG_METAG) += irq-metag-ext.o 6 7 obj-$(CONFIG_METAG_PERFCOUNTER_IRQS) += irq-metag.o 7 8 obj-$(CONFIG_ARCH_SUNXI) += irq-sunxi.o
+14
include/linux/irqchip/mxs.h
··· 1 + /* 2 + * Copyright (C) 2013 Freescale Semiconductor, Inc. 3 + * 4 + * This program is free software; you can redistribute it and/or modify 5 + * it under the terms of the GNU General Public License version 2 as 6 + * published by the Free Software Foundation. 7 + */ 8 + 9 + #ifndef __LINUX_IRQCHIP_MXS_H 10 + #define __LINUX_IRQCHIP_MXS_H 11 + 12 + extern void icoll_handle_irq(struct pt_regs *); 13 + 14 + #endif