Subversion Repositories HelenOS

Rev

Rev 2107 | Rev 3583 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 2107 Rev 3578
Line 53... Line 53...
53
 
53
 
54
/** Initialize Interval Timer. */
54
/** Initialize Interval Timer. */
55
void it_init(void)
55
void it_init(void)
56
{
56
{
57
    cr_itv_t itv;
57
    cr_itv_t itv;
58
 
58
   
-
 
59
    if(config.cpu_active==1)
-
 
60
    {
59
    irq_initialize(&it_irq);
61
        irq_initialize(&it_irq);
60
    it_irq.inr = INTERRUPT_TIMER;
62
        it_irq.inr = INTERRUPT_TIMER;
61
    it_irq.devno = device_assign_devno();
63
        it_irq.devno = device_assign_devno();
62
    it_irq.claim = it_claim;
64
        it_irq.claim = it_claim;
63
    it_irq.handler = it_interrupt;
65
        it_irq.handler = it_interrupt;
64
    irq_register(&it_irq);
66
        irq_register(&it_irq);
-
 
67
    }
65
 
68
   
66
    /* initialize Interval Timer external interrupt vector */
69
    /* initialize Interval Timer external interrupt vector */
67
    itv.value = itv_read();
70
    itv.value = itv_read();
68
    itv.vector = INTERRUPT_TIMER;
71
    itv.vector = INTERRUPT_TIMER;
69
    itv.m = 0;
72
    itv.m = 0;
70
    itv_write(itv.value);
73
    itv_write(itv.value);