diff options
author | Lucas Stach <l.stach@pengutronix.de> | 2017-03-01 15:31:32 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2017-03-02 09:11:23 +0100 |
commit | 26bf82803646717e8ef2852f6635a463e4d31ffd (patch) | |
tree | 035e62b3c1d8be8d57dd7524231fdc84732c31de /arch/arm/mach-bcm283x/include | |
parent | 63e67a96337987550406415a0f28934fc47eda1e (diff) | |
download | barebox-26bf82803646717e8ef2852f6635a463e4d31ffd.tar.gz barebox-26bf82803646717e8ef2852f6635a463e4d31ffd.tar.xz |
ARM: rpi: convert watchdog/reset to regular driver
This way it can be probed from DT later on.
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/arm/mach-bcm283x/include')
-rw-r--r-- | arch/arm/mach-bcm283x/include/mach/core.h | 5 | ||||
-rw-r--r-- | arch/arm/mach-bcm283x/include/mach/wd.h | 6 |
2 files changed, 8 insertions, 3 deletions
diff --git a/arch/arm/mach-bcm283x/include/mach/core.h b/arch/arm/mach-bcm283x/include/mach/core.h index ce54d38707..5edd99efa2 100644 --- a/arch/arm/mach-bcm283x/include/mach/core.h +++ b/arch/arm/mach-bcm283x/include/mach/core.h @@ -37,5 +37,10 @@ static void inline bcm2835_register_mbox(void) add_generic_device("bcm2835_mbox", 0, NULL, BCM2835_MBOX_BASE, 0x40, IORESOURCE_MEM, NULL); } +static void inline bcm2835_register_wd(void) +{ + add_generic_device("bcm2835_wd", 0, NULL, BCM2835_PM_BASE, 0x28, + IORESOURCE_MEM, NULL); +} #endif diff --git a/arch/arm/mach-bcm283x/include/mach/wd.h b/arch/arm/mach-bcm283x/include/mach/wd.h index ad8b762d96..cdd22d48c0 100644 --- a/arch/arm/mach-bcm283x/include/mach/wd.h +++ b/arch/arm/mach-bcm283x/include/mach/wd.h @@ -21,9 +21,9 @@ /* * Watchdog */ -#define PM_RSTC (BCM2835_PM_BASE+0x1c) -#define PM_RSTS (BCM2835_PM_BASE+0x20) -#define PM_WDOG (BCM2835_PM_BASE+0x24) +#define PM_RSTC 0x1c +#define PM_RSTS 0x20 +#define PM_WDOG 0x24 #define PM_WDOG_RESET 0000000000 #define PM_PASSWORD 0x5a000000 |