Pull fix drop-legacy-IRQ-code patch, pull from upstream
authorRISCi_ATOM <bob@bobcall.me>
Tue, 17 Sep 2019 14:24:26 +0000 (10:24 -0400)
committerRISCi_ATOM <bob@bobcall.me>
Tue, 17 Sep 2019 14:24:26 +0000 (10:24 -0400)
target/linux/ath79/patches-4.14/0027-MIPS-ath79-drop-legacy-IRQ-code.patch

index 2471628be993da89927115ee6f71cfd701ca7754..6586f084314145968c31768451ef2337a6a8d4d6 100644 (file)
@@ -9,15 +9,14 @@ All IRQs are now handled via the new irqchip drivers.
 Signed-off-by: John Crispin <john@phrozen.org>
 ---
  arch/mips/ath79/Makefile                 |   2 +-
+ arch/mips/ath79/irq.c                    | 169 -------------------------------
  arch/mips/ath79/setup.c                  |   6 ++
  arch/mips/include/asm/mach-ath79/ath79.h |   4 -
  4 files changed, 7 insertions(+), 174 deletions(-)
  delete mode 100644 arch/mips/ath79/irq.c
 
-Index: linux-4.14.143/arch/mips/ath79/Makefile
-===================================================================
---- linux-4.14.143.orig/arch/mips/ath79/Makefile
-+++ linux-4.14.143/arch/mips/ath79/Makefile
+--- a/arch/mips/ath79/Makefile
++++ b/arch/mips/ath79/Makefile
 @@ -8,7 +8,7 @@
  # under the terms of the GNU General Public License version 2 as published
  # by the Free Software Foundation.
@@ -27,48 +26,9 @@ Index: linux-4.14.143/arch/mips/ath79/Makefile
  
  obj-$(CONFIG_EARLY_PRINTK)            += early_printk.o
  obj-$(CONFIG_PCI)                     += pci.o
-Index: linux-4.14.143/arch/mips/ath79/setup.c
-===================================================================
---- linux-4.14.143.orig/arch/mips/ath79/setup.c
-+++ linux-4.14.143/arch/mips/ath79/setup.c
-@@ -19,6 +19,7 @@
- #include <linux/clk.h>
- #include <linux/clk-provider.h>
- #include <linux/of_fdt.h>
-+#include <linux/irqchip.h>
- #include <asm/bootinfo.h>
- #include <asm/idle.h>
-@@ -305,6 +306,11 @@ void __init plat_time_init(void)
-       mips_hpt_frequency = cpu_clk_rate / 2;
- }
-+void __init arch_init_irq(void)
-+{
-+      irqchip_init();
-+}
-+
- static int __init ath79_setup(void)
- {
-       if  (mips_machtype == ATH79_MACH_GENERIC_OF)
-Index: linux-4.14.143/arch/mips/include/asm/mach-ath79/ath79.h
-===================================================================
---- linux-4.14.143.orig/arch/mips/include/asm/mach-ath79/ath79.h
-+++ linux-4.14.143/arch/mips/include/asm/mach-ath79/ath79.h
-@@ -178,8 +178,4 @@ static inline u32 ath79_reset_rr(unsigne
- void ath79_device_reset_set(u32 mask);
- void ath79_device_reset_clear(u32 mask);
--void ath79_cpu_irq_init(unsigned irq_wb_chan2, unsigned irq_wb_chan3);
--void ath79_misc_irq_init(void __iomem *regs, int irq,
--                      int irq_base, bool is_ar71xx);
--
- #endif /* __ASM_MACH_ATH79_H */
-Index: linux-4.14.143/arch/mips/ath79/irq.c
-===================================================================
---- linux-4.14.143.orig/arch/mips/ath79/irq.c
+--- a/arch/mips/ath79/irq.c
 +++ /dev/null
-@@ -1,175 +0,0 @@
+@@ -1,169 +0,0 @@
 -/*
 - *  Atheros AR71xx/AR724x/AR913x specific interrupt handling
 - *
@@ -103,21 +63,15 @@ Index: linux-4.14.143/arch/mips/ath79/irq.c
 -      u32 status;
 -
 -      status = ath79_reset_rr(AR934X_RESET_REG_PCIE_WMAC_INT_STATUS);
--      status &= AR934X_PCIE_WMAC_INT_PCIE_ALL | AR934X_PCIE_WMAC_INT_WMAC_ALL;
--
--      if (status == 0) {
--              spurious_interrupt();
--              return;
--      }
 -
 -      if (status & AR934X_PCIE_WMAC_INT_PCIE_ALL) {
 -              ath79_ddr_wb_flush(3);
 -              generic_handle_irq(ATH79_IP2_IRQ(0));
--      }
--
--      if (status & AR934X_PCIE_WMAC_INT_WMAC_ALL) {
+-      } else if (status & AR934X_PCIE_WMAC_INT_WMAC_ALL) {
 -              ath79_ddr_wb_flush(4);
 -              generic_handle_irq(ATH79_IP2_IRQ(1));
+-      } else {
+-              spurious_interrupt();
 -      }
 -}
 -
@@ -244,3 +198,36 @@ Index: linux-4.14.143/arch/mips/ath79/irq.c
 -      else if (soc_is_qca955x())
 -              qca955x_irq_init();
 -}
+--- a/arch/mips/ath79/setup.c
++++ b/arch/mips/ath79/setup.c
+@@ -19,6 +19,7 @@
+ #include <linux/clk.h>
+ #include <linux/clk-provider.h>
+ #include <linux/of_fdt.h>
++#include <linux/irqchip.h>
+ #include <asm/bootinfo.h>
+ #include <asm/idle.h>
+@@ -305,6 +306,11 @@ void __init plat_time_init(void)
+       mips_hpt_frequency = cpu_clk_rate / 2;
+ }
++void __init arch_init_irq(void)
++{
++      irqchip_init();
++}
++
+ static int __init ath79_setup(void)
+ {
+       if  (mips_machtype == ATH79_MACH_GENERIC_OF)
+--- a/arch/mips/include/asm/mach-ath79/ath79.h
++++ b/arch/mips/include/asm/mach-ath79/ath79.h
+@@ -178,8 +178,4 @@ static inline u32 ath79_reset_rr(unsigne
+ void ath79_device_reset_set(u32 mask);
+ void ath79_device_reset_clear(u32 mask);
+-void ath79_cpu_irq_init(unsigned irq_wb_chan2, unsigned irq_wb_chan3);
+-void ath79_misc_irq_init(void __iomem *regs, int irq,
+-                      int irq_base, bool is_ar71xx);
+-
+ #endif /* __ASM_MACH_ATH79_H */