-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Paul Mundt
committed
Sep 8, 2008
1 parent
e0d76eb
commit 8a13bd6
Showing
7 changed files
with
78 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
--- | ||
refs/heads/master: 6f52707e6882eb3bc6920c3f59beb05d23d68354 | ||
refs/heads/master: 8c24594deab89a484879bee270e948f0a556ed75 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
/* | ||
* Dummy local timer | ||
* | ||
* Copyright (C) 2008 Paul Mundt | ||
* | ||
* cloned from: | ||
* | ||
* linux/arch/arm/mach-realview/localtimer.c | ||
* | ||
* Copyright (C) 2002 ARM Ltd. | ||
* All Rights Reserved | ||
* | ||
* This program is free software; you can redistribute it and/or modify | ||
* it under the terms of the GNU General Public License version 2 as | ||
* published by the Free Software Foundation. | ||
*/ | ||
#include <linux/init.h> | ||
#include <linux/kernel.h> | ||
#include <linux/delay.h> | ||
#include <linux/device.h> | ||
#include <linux/smp.h> | ||
#include <linux/jiffies.h> | ||
#include <linux/percpu.h> | ||
#include <linux/clockchips.h> | ||
#include <linux/irq.h> | ||
|
||
static DEFINE_PER_CPU(struct clock_event_device, local_clockevent); | ||
|
||
/* | ||
* Used on SMP for either the local timer or SMP_MSG_TIMER | ||
*/ | ||
void local_timer_interrupt(void) | ||
{ | ||
struct clock_event_device *clk = &__get_cpu_var(local_clockevent); | ||
|
||
clk->event_handler(clk); | ||
} | ||
|
||
static void dummy_timer_set_mode(enum clock_event_mode mode, | ||
struct clock_event_device *clk) | ||
{ | ||
} | ||
|
||
void __cpuinit local_timer_setup(unsigned int cpu) | ||
{ | ||
struct clock_event_device *clk = &per_cpu(local_clockevent, cpu); | ||
|
||
clk->name = "dummy_timer"; | ||
clk->features = CLOCK_EVT_FEAT_DUMMY; | ||
clk->rating = 200; | ||
clk->mult = 1; | ||
clk->set_mode = dummy_timer_set_mode; | ||
clk->broadcast = smp_timer_broadcast; | ||
clk->cpumask = cpumask_of_cpu(cpu); | ||
|
||
clockevents_register_device(clk); | ||
} |