You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
1.1 KiB
44 lines
1.1 KiB
10 years ago
|
--- a/arch/arm/mach-cns3xxx/core.c
|
||
|
+++ b/arch/arm/mach-cns3xxx/core.c
|
||
|
@@ -17,6 +17,7 @@
|
||
|
#include <linux/platform_device.h>
|
||
|
#include <linux/usb/ehci_pdriver.h>
|
||
|
#include <linux/usb/ohci_pdriver.h>
|
||
|
+#include <asm/smp_twd.h>
|
||
|
#include <asm/mach/arch.h>
|
||
|
#include <asm/mach/map.h>
|
||
|
#include <asm/mach/time.h>
|
||
|
@@ -26,6 +27,8 @@
|
||
|
#include "core.h"
|
||
|
#include "pm.h"
|
||
|
|
||
|
+#define IRQ_LOCALTIMER 29
|
||
|
+
|
||
|
static struct map_desc cns3xxx_io_desc[] __initdata = {
|
||
|
{
|
||
|
.virtual = CNS3XXX_TC11MP_SCU_BASE_VIRT,
|
||
9 years ago
|
@@ -198,6 +201,15 @@ static struct irqaction cns3xxx_timer_ir
|
||
10 years ago
|
.handler = cns3xxx_timer_interrupt,
|
||
|
};
|
||
|
|
||
|
+static void __init cns3xxx_init_twd(void)
|
||
|
+{
|
||
|
+ static DEFINE_TWD_LOCAL_TIMER(cns3xx_twd_local_timer,
|
||
|
+ CNS3XXX_TC11MP_TWD_BASE,
|
||
|
+ IRQ_LOCALTIMER);
|
||
|
+
|
||
|
+ twd_local_timer_register(&cns3xx_twd_local_timer);
|
||
|
+}
|
||
|
+
|
||
|
/*
|
||
|
* Set up the clock source and clock events devices
|
||
|
*/
|
||
9 years ago
|
@@ -251,6 +263,7 @@ static void __init __cns3xxx_timer_init(
|
||
10 years ago
|
setup_irq(timer_irq, &cns3xxx_timer_irq);
|
||
|
|
||
|
cns3xxx_clockevents_init(timer_irq);
|
||
|
+ cns3xxx_init_twd();
|
||
|
}
|
||
|
|
||
|
void __init cns3xxx_timer_init(void)
|