修改格式
This commit is contained in:
parent
2b13e2fa57
commit
341e52d940
|
@ -75,6 +75,6 @@ void main(void)
|
||||||
/* startup RT-Thread RTOS */
|
/* startup RT-Thread RTOS */
|
||||||
rtthread_startup();
|
rtthread_startup();
|
||||||
|
|
||||||
for ( ; ; );
|
for(;;){}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -35,7 +35,7 @@ void rt_hw_systick_isr(void)
|
||||||
void rt_hw_system_timer_init(void)
|
void rt_hw_system_timer_init(void)
|
||||||
{
|
{
|
||||||
// initial system timer interrupt, map local timer interrupt to INT14
|
// initial system timer interrupt, map local timer interrupt to INT14
|
||||||
gpCGEM_regs->INTMUX3 = (CSL_GEM_TINTLN<<CSL_CGEM_INTMUX3_INTSEL14_SHIFT);
|
gpCGEM_regs->INTMUX3=(CSL_GEM_TINTLN<<CSL_CGEM_INTMUX3_INTSEL14_SHIFT);
|
||||||
// enable CPU INT14
|
// enable CPU INT14
|
||||||
CPU_interrupt_enable(1<<14);
|
CPU_interrupt_enable(1<<14);
|
||||||
|
|
||||||
|
@ -55,10 +55,10 @@ void rt_hw_system_timer_start(void)
|
||||||
gpBootCfgRegs->TOUTSEL = (DNUM*2)<<CSL_BOOTCFG_TOUTSEL_TOUTSEL0_SHIFT;
|
gpBootCfgRegs->TOUTSEL = (DNUM*2)<<CSL_BOOTCFG_TOUTSEL_TOUTSEL0_SHIFT;
|
||||||
|
|
||||||
// configure the timer to generate clocks and interrupts
|
// configure the timer to generate clocks and interrupts
|
||||||
tmrCfg.timer_num= DNUM;
|
tmrCfg.timer_num=DNUM;
|
||||||
tmrCfg.timerMode= TIMER_PERIODIC_CLOCK;
|
tmrCfg.timerMode=TIMER_PERIODIC_CLOCK;
|
||||||
tmrCfg.period= (unsigned long long) RT_TICK_PER_SECOND*gDSP_Core_Speed_Hz/6000;
|
tmrCfg.period = (unsigned long long) RT_TICK_PER_SECOND*gDSP_Core_Speed_Hz/6000;
|
||||||
tmrCfg.reload_period= 0;
|
tmrCfg.reload_period=0;
|
||||||
|
|
||||||
// initial timer
|
// initial timer
|
||||||
Timer64_Init(&tmrCfg);
|
Timer64_Init(&tmrCfg);
|
||||||
|
|
|
@ -37,7 +37,7 @@ RT_WEAK void rt_hw_cpu_shutdown(void)
|
||||||
|
|
||||||
void nested_exception_handler(void)
|
void nested_exception_handler(void)
|
||||||
{
|
{
|
||||||
for ( ; ; );
|
for(;;){}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*------------ hw_nmi_handler() function --------------------------------------
|
/*------------ hw_nmi_handler() function --------------------------------------
|
||||||
|
@ -48,7 +48,7 @@ void nested_exception_handler(void)
|
||||||
-----------------------------------------------------------------------------*/
|
-----------------------------------------------------------------------------*/
|
||||||
void hw_nmi_handler(struct rt_hw_exp_stack_register *regs)
|
void hw_nmi_handler(struct rt_hw_exp_stack_register *regs)
|
||||||
{
|
{
|
||||||
for ( ; ; );
|
for(;;){}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*------------ hw_bad_handler() function --------------------------------------
|
/*------------ hw_bad_handler() function --------------------------------------
|
||||||
|
@ -59,7 +59,7 @@ void hw_nmi_handler(struct rt_hw_exp_stack_register *regs)
|
||||||
-----------------------------------------------------------------------------*/
|
-----------------------------------------------------------------------------*/
|
||||||
void hw_bad_handler(void)
|
void hw_bad_handler(void)
|
||||||
{
|
{
|
||||||
for ( ; ; );
|
for(;;){}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*------------ hw_int4_handler() function -------------------------------------
|
/*------------ hw_int4_handler() function -------------------------------------
|
||||||
|
|
|
@ -114,10 +114,9 @@ void do_trap(struct rt_exception_info *except_info, struct rt_hw_exp_stack_regis
|
||||||
|
|
||||||
show_regs(regs);
|
show_regs(regs);
|
||||||
|
|
||||||
for( ; ; );
|
for(;;){}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static struct rt_exception_info iexcept_table[10] = {
|
static struct rt_exception_info iexcept_table[10] = {
|
||||||
{ " - instruction fetch", ABORT_TYPE_BUS, ABORT_BUS_ADDRERR },
|
{ " - instruction fetch", ABORT_TYPE_BUS, ABORT_BUS_ADDRERR },
|
||||||
{ " - fetch packet", ABORT_TYPE_BUS, ABORT_BUS_ADDRERR },
|
{ " - fetch packet", ABORT_TYPE_BUS, ABORT_BUS_ADDRERR },
|
||||||
|
@ -154,7 +153,6 @@ static int process_iexcept(struct rt_hw_exp_stack_register *regs)
|
||||||
set_iexcept(iexcept_report);
|
set_iexcept(iexcept_report);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
do_trap(&iexcept_table[iexcept_num], regs);
|
do_trap(&iexcept_table[iexcept_num], regs);
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Reference in New Issue