diff options
Diffstat (limited to 'arch/arm/mach-omap2/prm_common.c')
-rw-r--r-- | arch/arm/mach-omap2/prm_common.c | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/prm_common.c b/arch/arm/mach-omap2/prm_common.c index f596e1e91ffd..228b850e632f 100644 --- a/arch/arm/mach-omap2/prm_common.c +++ b/arch/arm/mach-omap2/prm_common.c | |||
@@ -365,6 +365,51 @@ u32 prm_read_reset_sources(void) | |||
365 | } | 365 | } |
366 | 366 | ||
367 | /** | 367 | /** |
368 | * prm_was_any_context_lost_old - was device context lost? (old API) | ||
369 | * @part: PRM partition ID (e.g., OMAP4430_PRM_PARTITION) | ||
370 | * @inst: PRM instance offset (e.g., OMAP4430_PRM_MPU_INST) | ||
371 | * @idx: CONTEXT register offset | ||
372 | * | ||
373 | * Return 1 if any bits were set in the *_CONTEXT_* register | ||
374 | * identified by (@part, @inst, @idx), which means that some context | ||
375 | * was lost for that module; otherwise, return 0. XXX Deprecated; | ||
376 | * callers need to use a less-SoC-dependent way to identify hardware | ||
377 | * IP blocks. | ||
378 | */ | ||
379 | bool prm_was_any_context_lost_old(u8 part, s16 inst, u16 idx) | ||
380 | { | ||
381 | bool ret = true; | ||
382 | |||
383 | if (prm_ll_data->was_any_context_lost_old) | ||
384 | ret = prm_ll_data->was_any_context_lost_old(part, inst, idx); | ||
385 | else | ||
386 | WARN_ONCE(1, "prm: %s: no mapping function defined\n", | ||
387 | __func__); | ||
388 | |||
389 | return ret; | ||
390 | } | ||
391 | |||
392 | /** | ||
393 | * prm_clear_context_lost_flags_old - clear context loss flags (old API) | ||
394 | * @part: PRM partition ID (e.g., OMAP4430_PRM_PARTITION) | ||
395 | * @inst: PRM instance offset (e.g., OMAP4430_PRM_MPU_INST) | ||
396 | * @idx: CONTEXT register offset | ||
397 | * | ||
398 | * Clear hardware context loss bits for the module identified by | ||
399 | * (@part, @inst, @idx). No return value. XXX Deprecated; callers | ||
400 | * need to use a less-SoC-dependent way to identify hardware IP | ||
401 | * blocks. | ||
402 | */ | ||
403 | void prm_clear_context_loss_flags_old(u8 part, s16 inst, u16 idx) | ||
404 | { | ||
405 | if (prm_ll_data->clear_context_loss_flags_old) | ||
406 | prm_ll_data->clear_context_loss_flags_old(part, inst, idx); | ||
407 | else | ||
408 | WARN_ONCE(1, "prm: %s: no mapping function defined\n", | ||
409 | __func__); | ||
410 | } | ||
411 | |||
412 | /** | ||
368 | * prm_register - register per-SoC low-level data with the PRM | 413 | * prm_register - register per-SoC low-level data with the PRM |
369 | * @pld: low-level per-SoC OMAP PRM data & function pointers to register | 414 | * @pld: low-level per-SoC OMAP PRM data & function pointers to register |
370 | * | 415 | * |