Commit c4687333 authored by Dave Gerlach's avatar Dave Gerlach Committed by Nishanth Menon

[AM437x][PRCM] Allow dump of prcm irq or prcm dpll raw registers

Add dump of dpll and irq prcm registers to dump prcm command.
Signed-off-by: default avatarDave Gerlach <d-gerlach@ti.com>
Signed-off-by: default avatarNishanth Menon <nm@ti.com>
parent 4cc02cc9
......@@ -83,6 +83,6 @@ void help_am437x(help_category cat, char *context)
printf("\t Dump PRCM Registers related to <pwrdm> power "
"domain ('all' assumed if omitted).\n");
printf("\t Support <pwrdm>: all, cefuse, device, gfx, mpu, per, "
"rtc, wkup\n");
"rtc, wkup, irq, dpll\n");
}
}
......@@ -197,6 +197,38 @@ static inline int _prcm_am437x_dev_dump(FILE *stream)
return cm_am437x_dump(stream, CM_AM437X_CM_DEVICE);
}
/* ------------------------------------------------------------------------*//**
* @FUNCTION _prcm_am437x_irq_dump
* @BRIEF dump PRCM IRQ PRCM registers and pretty-print it
* @RETURNS 0 in case of success
* OMAPCONF_ERR_CPU
* OMAPCONF_ERR_ARG
* OMAPCONF_ERR_REG_ACCESS
* @param[in,out] stream: output stream
* @DESCRIPTION dump PRM IRQ PRCM registers and pretty-print it.
* NOTE: No corresponding CM module
*/
static inline int _prcm_am437x_irq_dump(FILE *stream)
{
return prm_am437x_dump(stream, PRM_AM437X_PRM_IRQ);
}
/* ------------------------------------------------------------------------*//**
* @FUNCTION _prcm_am437x_dpll_dump
* @BRIEF dump PRCM IRQ PRCM registers and pretty-print it
* @RETURNS 0 in case of success
* OMAPCONF_ERR_CPU
* OMAPCONF_ERR_ARG
* OMAPCONF_ERR_REG_ACCESS
* @param[in,out] stream: output stream
* @DESCRIPTION dump CM DPLL PRCM registers and pretty-print it.
* NOTE: No corresponding PRM module
*/
static inline int _prcm_am437x_dpll_dump(FILE *stream)
{
return cm_am437x_dump(stream, CM_AM437X_CM_DPLL);
}
/* ------------------------------------------------------------------------*//**
* @FUNCTION prcm_am437x_dump
* @BRIEF dump (formated in table) PRCM registers related to power
......@@ -222,6 +254,8 @@ int prcm_am437x_dump(char *s)
ret |= _prcm_am437x_rtc_dump(stdout);
ret |= _prcm_am437x_gfx_dump(stdout);
ret |= _prcm_am437x_efuse_dump(stdout);
ret |= _prcm_am437x_irq_dump(stdout);
ret |= _prcm_am437x_dpll_dump(stdout);
return ret;
} else if (strcmp(s, "wkup") == 0) {
return _prcm_am437x_wkup_dump(stdout);
......@@ -237,6 +271,10 @@ int prcm_am437x_dump(char *s)
return _prcm_am437x_efuse_dump(stdout);
} else if (strcmp(s, "dev") == 0) {
return _prcm_am437x_dev_dump(stdout);
} else if (strcmp(s, "irq") == 0) {
return _prcm_am437x_irq_dump(stdout);
} else if (strcmp(s, "dpll") == 0) {
return _prcm_am437x_dpll_dump(stdout);
} else {
return err_arg_msg_show(HELP_PRCM);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment