diff options
Diffstat (limited to 'cpu/arm920t/at91rm9200/interrupts.c')
| -rw-r--r-- | cpu/arm920t/at91rm9200/interrupts.c | 27 | 
1 files changed, 7 insertions, 20 deletions
| diff --git a/cpu/arm920t/at91rm9200/interrupts.c b/cpu/arm920t/at91rm9200/interrupts.c index 5f0703c2d..cff491664 100644 --- a/cpu/arm920t/at91rm9200/interrupts.c +++ b/cpu/arm920t/at91rm9200/interrupts.c @@ -45,6 +45,8 @@ AT91PS_TC tmr;  static ulong timestamp;  static ulong lastinc; +void board_reset(void) __attribute__((__weak__)); +  int interrupt_init (void)  {  	tmr = AT91C_BASE_TC0; @@ -166,29 +168,14 @@ ulong get_tbclk (void)  void reset_cpu (ulong ignored)  { -#ifdef CONFIG_DBGU -	AT91PS_USART us = (AT91PS_USART) AT91C_BASE_DBGU; -#endif -#ifdef CONFIG_USART0 -	AT91PS_USART us = AT91C_BASE_US0; -#endif -#ifdef CONFIG_USART1 -	AT91PS_USART us = AT91C_BASE_US1; -#endif -#ifdef CONFIG_AT91RM9200DK -	AT91PS_PIO pio = AT91C_BASE_PIOA; -#endif - +#if defined(CONFIG_AT91RM9200_USART)  	/*shutdown the console to avoid strange chars during reset */ -	us->US_CR = (AT91C_US_RSTRX | AT91C_US_RSTTX); - -#ifdef CONFIG_AT91RM9200DK -	/* Clear PA19 to trigger the hard reset */ -	pio->PIO_CODR = 0x00080000; -	pio->PIO_OER  = 0x00080000; -	pio->PIO_PER  = 0x00080000; +	serial_exit();  #endif +	if (board_reset) +		board_reset(); +  	/* this is the way Linux does it */  	/* FIXME: |