Subversion Repositories HelenOS

Rev

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

Rev 1432 Rev 1434
Line 78... Line 78...
78
    /* It is not assumed by default */
78
    /* It is not assumed by default */
79
    interrupts_disable();
79
    interrupts_disable();
80
   
80
   
81
    /* Initialize dispatch table */
81
    /* Initialize dispatch table */
82
    exception_init();
82
    exception_init();
83
    interrupt_init();
-
 
84
 
-
 
85
    arc_init();
83
    arc_init();
86
 
84
 
87
    /* Copy the exception vectors to the right places */
85
    /* Copy the exception vectors to the right places */
88
    memcpy(TLB_EXC, (char *)tlb_refill_entry, EXCEPTION_JUMP_SIZE);
86
    memcpy(TLB_EXC, (char *)tlb_refill_entry, EXCEPTION_JUMP_SIZE);
89
    memcpy(NORM_EXC, (char *)exception_entry, EXCEPTION_JUMP_SIZE);
87
    memcpy(NORM_EXC, (char *)exception_entry, EXCEPTION_JUMP_SIZE);
90
    memcpy(CACHE_EXC, (char *)cache_error_entry, EXCEPTION_JUMP_SIZE);
88
    memcpy(CACHE_EXC, (char *)cache_error_entry, EXCEPTION_JUMP_SIZE);
91
 
89
 
-
 
90
    interrupt_init();
92
    /*
91
    /*
93
     * Switch to BEV normal level so that exception vectors point to the kernel.
92
     * Switch to BEV normal level so that exception vectors point to the kernel.
94
     * Clear the error level.
93
     * Clear the error level.
95
     */
94
     */
96
    cp0_status_write(cp0_status_read() & ~(cp0_status_bev_bootstrap_bit|cp0_status_erl_error_bit));
95
    cp0_status_write(cp0_status_read() & ~(cp0_status_bev_bootstrap_bit|cp0_status_erl_error_bit));
97
 
96
 
98
    /*
97
    /*
99
     * Mask all interrupts
98
     * Mask all interrupts
100
     */
99
     */
101
    cp0_mask_all_int();
100
    cp0_mask_all_int();
-
 
101
 
102
    /*
102
    /*
103
     * Unmask hardware clock interrupt.
103
     * Unmask hardware clock interrupt.
104
     */
104
     */
105
    cp0_unmask_int(TIMER_IRQ);
105
    cp0_unmask_int(TIMER_IRQ);
106
 
106
 
107
    /*
-
 
108
     * Start hardware clock.
-
 
109
     */
-
 
110
    cp0_compare_write(cp0_compare_value + cp0_count_read());
-
 
111
 
-
 
112
    console_init();
107
    console_init();
113
    debugger_init();
108
    debugger_init();
114
}
109
}
115
 
110
 
116
void arch_post_mm_init(void)
111
void arch_post_mm_init(void)