diff options
author | Kumar Gala <galak@kernel.crashing.org> | 2006-01-11 11:19:12 -0600 |
---|---|---|
committer | Kumar Gala <galak@kernel.crashing.org> | 2006-01-11 11:19:12 -0600 |
commit | ce574ff5060b63b1bad143d84f0c386892d3243f (patch) | |
tree | ff52d749c0d6637957316c2478ad05b82ce679f6 /cpu | |
parent | 9260a56151e9aed923e61994b4c368297690a78e (diff) | |
download | bootable_bootloader_goldelico_gta04-ce574ff5060b63b1bad143d84f0c386892d3243f.zip bootable_bootloader_goldelico_gta04-ce574ff5060b63b1bad143d84f0c386892d3243f.tar.gz bootable_bootloader_goldelico_gta04-ce574ff5060b63b1bad143d84f0c386892d3243f.tar.bz2 |
Enable time handling on 83xx
Patch by Kumar Gala, 11 Jan 2006
Diffstat (limited to 'cpu')
-rw-r--r-- | cpu/mpc83xx/interrupts.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/cpu/mpc83xx/interrupts.c b/cpu/mpc83xx/interrupts.c index 53474f6..dfd51c1 100644 --- a/cpu/mpc83xx/interrupts.c +++ b/cpu/mpc83xx/interrupts.c @@ -43,6 +43,16 @@ struct irq_action { int interrupt_init_cpu (unsigned *decrementer_count) { + DECLARE_GLOBAL_DATA_PTR; + + volatile immap_t *immr = (immap_t *) CFG_IMMRBAR; + + *decrementer_count = (gd->bus_clk / 4) / CFG_HZ; + + /* Enable e300 time base */ + + immr->sysconf.spcr |= 0x00400000; + return 0; } |