diff options
Diffstat (limited to 'arch/arm/mach-omap2/prm_common.c')
| -rw-r--r-- | arch/arm/mach-omap2/prm_common.c | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/prm_common.c b/arch/arm/mach-omap2/prm_common.c index 8670a3c4bc5e..e200e4fb47dc 100644 --- a/arch/arm/mach-omap2/prm_common.c +++ b/arch/arm/mach-omap2/prm_common.c | |||
| @@ -28,6 +28,8 @@ | |||
| 28 | #include <plat/prcm.h> | 28 | #include <plat/prcm.h> |
| 29 | 29 | ||
| 30 | #include "prm2xxx_3xxx.h" | 30 | #include "prm2xxx_3xxx.h" |
| 31 | #include "prm2xxx.h" | ||
| 32 | #include "prm3xxx.h" | ||
| 31 | #include "prm44xx.h" | 33 | #include "prm44xx.h" |
| 32 | 34 | ||
| 33 | /* | 35 | /* |
| @@ -327,6 +329,30 @@ err: | |||
| 327 | } | 329 | } |
| 328 | 330 | ||
| 329 | /** | 331 | /** |
| 332 | * prm_read_reset_sources - return the sources of the SoC's last reset | ||
| 333 | * | ||
| 334 | * Return a u32 bitmask representing the reset sources that caused the | ||
| 335 | * SoC to reset. The low-level per-SoC functions called by this | ||
| 336 | * function remap the SoC-specific reset source bits into an | ||
| 337 | * OMAP-common set of reset source bits, defined in | ||
| 338 | * arch/arm/mach-omap2/prm.h. Returns the standardized reset source | ||
| 339 | * u32 bitmask from the hardware upon success, or returns (1 << | ||
| 340 | * OMAP_UNKNOWN_RST_SRC_ID_SHIFT) if no low-level read_reset_sources() | ||
| 341 | * function was registered. | ||
| 342 | */ | ||
| 343 | u32 prm_read_reset_sources(void) | ||
| 344 | { | ||
| 345 | u32 ret = 1 << OMAP_UNKNOWN_RST_SRC_ID_SHIFT; | ||
| 346 | |||
| 347 | if (prm_ll_data->read_reset_sources) | ||
| 348 | ret = prm_ll_data->read_reset_sources(); | ||
| 349 | else | ||
| 350 | WARN_ONCE(1, "prm: %s: no mapping function defined for reset sources\n", __func__); | ||
| 351 | |||
| 352 | return ret; | ||
| 353 | } | ||
| 354 | |||
| 355 | /** | ||
| 330 | * prm_register - register per-SoC low-level data with the PRM | 356 | * prm_register - register per-SoC low-level data with the PRM |
| 331 | * @pld: low-level per-SoC OMAP PRM data & function pointers to register | 357 | * @pld: low-level per-SoC OMAP PRM data & function pointers to register |
| 332 | * | 358 | * |
