-void __init mips_time_init(void)
-{
- u32 clock;
-
- clock = *(u32*)KSEG1ADDR(ADM5120_CODEREG);
-
- switch (clock & ADM5120_CPU_CLK_MASK) {
- case ADM5120_CPU_CLK_175:
- mips_counter_frequency = 87500000;
- printk("CPU clock: 175MHz\n");
- break;
- case ADM5120_CPU_CLK_200:
- mips_counter_frequency = 100000000;
- printk("CPU clock: 200MHz\n");
- break;
- case ADM5120_CPU_CLK_225:
- mips_counter_frequency = 112500000;
- printk("CPU clock: 225MHz\n");
- break;
- case ADM5120_CPU_CLK_250:
- mips_counter_frequency = 125000000;
- printk("CPU clock: 250MHz\n");
- break;
- }
-}
-
-void __init plat_timer_setup(struct irqaction *irq)
-{
- /* to generate the first timer interrupt */
- write_c0_compare(read_c0_count()+ mips_counter_frequency/HZ);
- clear_c0_status(ST0_BEV);
- set_c0_status(ALLINTS);
-}
-