summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-at91/at91sam9x5.c
blob: 40ba9ed56e8abd1130772123371b7083623a3f4f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#include <common.h>
#include <init.h>
#include <restart.h>
#include <mach/at91sam9x5.h>
#include <mach/board.h>
#include <mach/at91_rstc.h>

static void at91sam9x5_restart(struct restart_handler *rst)
{
	at91sam9g45_reset(IOMEM(AT91SAM9X5_BASE_DDRSDRC0),
			  IOMEM(AT91SAM9X5_BASE_RSTC + AT91_RSTC_CR));
}

static int at91sam9x5_initialize(void)
{
	restart_handler_register_fn(at91sam9x5_restart);

	return 0;
}
coredevice_initcall(at91sam9x5_initialize);