aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips/netlogic
diff options
context:
space:
mode:
authorJayachandran C <jchandra@broadcom.com>2013-12-21 06:22:22 -0500
committerRalf Baechle <ralf@linux-mips.org>2014-01-24 16:39:48 -0500
commitd150cef4e8cc723d90226e503ef6aff2ca9fc57c (patch)
tree8e5a9d1d0457b80ec535b0f7858ffbec84d0f0c9 /arch/mips/netlogic
parent5513c760db4f3a914247b8fff1ba74b9ebb0af8e (diff)
MIPS: Netlogic: XLP9XX PIC updates
Functions for the XLP9XX interrupt table entry format and other PIC register changes. Signed-off-by: Jayachandran C <jchandra@broadcom.com> Signed-off-by: John Crispin <blogic@openwrt.org> Patchwork: http://patchwork.linux-mips.org/patch/6279/
Diffstat (limited to 'arch/mips/netlogic')
-rw-r--r--arch/mips/netlogic/xlp/nlm_hal.c15
-rw-r--r--arch/mips/netlogic/xlp/wakeup.c2
2 files changed, 16 insertions, 1 deletions
diff --git a/arch/mips/netlogic/xlp/nlm_hal.c b/arch/mips/netlogic/xlp/nlm_hal.c
index 5f191f54f9c0..2d31cf1137fb 100644
--- a/arch/mips/netlogic/xlp/nlm_hal.c
+++ b/arch/mips/netlogic/xlp/nlm_hal.c
@@ -69,6 +69,17 @@ int nlm_irq_to_irt(int irq)
69 uint64_t pcibase; 69 uint64_t pcibase;
70 int devoff, irt; 70 int devoff, irt;
71 71
72 /* bypass for 9xx */
73 if (cpu_is_xlp9xx()) {
74 switch (irq) {
75 case PIC_UART_0_IRQ:
76 return 133;
77 case PIC_UART_1_IRQ:
78 return 134;
79 }
80 return -1;
81 }
82
72 devoff = 0; 83 devoff = 0;
73 switch (irq) { 84 switch (irq) {
74 case PIC_UART_0_IRQ: 85 case PIC_UART_0_IRQ:
@@ -277,6 +288,10 @@ static unsigned int nlm_2xx_get_pic_frequency(int node)
277 288
278unsigned int nlm_get_pic_frequency(int node) 289unsigned int nlm_get_pic_frequency(int node)
279{ 290{
291 /* TODO Has to calculate freq as like 2xx */
292 if (cpu_is_xlp9xx())
293 return 250000000;
294
280 if (cpu_is_xlpii()) 295 if (cpu_is_xlpii())
281 return nlm_2xx_get_pic_frequency(node); 296 return nlm_2xx_get_pic_frequency(node);
282 else 297 else
diff --git a/arch/mips/netlogic/xlp/wakeup.c b/arch/mips/netlogic/xlp/wakeup.c
index e6f77c053658..f11035b1ad11 100644
--- a/arch/mips/netlogic/xlp/wakeup.c
+++ b/arch/mips/netlogic/xlp/wakeup.c
@@ -47,8 +47,8 @@
47#include <asm/netlogic/mips-extns.h> 47#include <asm/netlogic/mips-extns.h>
48 48
49#include <asm/netlogic/xlp-hal/iomap.h> 49#include <asm/netlogic/xlp-hal/iomap.h>
50#include <asm/netlogic/xlp-hal/pic.h>
51#include <asm/netlogic/xlp-hal/xlp.h> 50#include <asm/netlogic/xlp-hal/xlp.h>
51#include <asm/netlogic/xlp-hal/pic.h>
52#include <asm/netlogic/xlp-hal/sys.h> 52#include <asm/netlogic/xlp-hal/sys.h>
53 53
54static int xlp_wakeup_core(uint64_t sysbase, int node, int core) 54static int xlp_wakeup_core(uint64_t sysbase, int node, int core)