summaryrefslogtreecommitdiffstats
path: root/arch/x86/lib/timer.c
diff options
context:
space:
mode:
authorGraeme Russ <graeme.russ@gmail.com>2011-11-08 02:33:15 +0000
committerGraeme Russ <graeme.russ@gmail.com>2011-11-29 21:03:43 +1100
commit83088afbba0c142fda5313866abd1e679d0f9e78 (patch)
treedc968778c47d8aa2f915e928838b5bd72b71ff18 /arch/x86/lib/timer.c
parent01a0f5a1ebba7eeccf13fc5992ed59e8614fd58a (diff)
downloadtalos-obmc-uboot-83088afbba0c142fda5313866abd1e679d0f9e78.tar.gz
talos-obmc-uboot-83088afbba0c142fda5313866abd1e679d0f9e78.zip
cosmetic: checkpatch cleanup of arch/x86/lib/*.c
Signed-off-by: Graeme Russ <graeme.russ@gmail.com>
Diffstat (limited to 'arch/x86/lib/timer.c')
-rw-r--r--arch/x86/lib/timer.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/arch/x86/lib/timer.c b/arch/x86/lib/timer.c
index 8b1bde708c..fd7032e92c 100644
--- a/arch/x86/lib/timer.c
+++ b/arch/x86/lib/timer.c
@@ -35,15 +35,15 @@ struct timer_isr_function {
timer_fnc_t *isr_func;
};
-static struct timer_isr_function *first_timer_isr = NULL;
-static volatile unsigned long system_ticks = 0;
+static struct timer_isr_function *first_timer_isr;
+static unsigned long system_ticks;
/*
* register_timer_isr() allows multiple architecture and board specific
* functions to be called every millisecond. Keep the execution time of
* each function as low as possible
*/
-int register_timer_isr (timer_fnc_t *isr_func)
+int register_timer_isr(timer_fnc_t *isr_func)
{
struct timer_isr_function *new_func;
struct timer_isr_function *temp;
@@ -61,7 +61,7 @@ int register_timer_isr (timer_fnc_t *isr_func)
* Don't allow timer interrupts while the
* linked list is being modified
*/
- flag = disable_interrupts ();
+ flag = disable_interrupts();
if (first_timer_isr == NULL) {
first_timer_isr = new_func;
@@ -73,7 +73,7 @@ int register_timer_isr (timer_fnc_t *isr_func)
}
if (flag)
- enable_interrupts ();
+ enable_interrupts();
return 0;
}
@@ -89,12 +89,12 @@ void timer_isr(void *unused)
/* Execute each registered function */
while (temp != NULL) {
- temp->isr_func ();
+ temp->isr_func();
temp = temp->next;
}
}
-ulong get_timer (ulong base)
+ulong get_timer(ulong base)
{
- return (system_ticks - base);
+ return system_ticks - base;
}
OpenPOWER on IntegriCloud