Skip to content

Commit

Permalink
ast-bmc: Rename LPC FW cycle helpers
Browse files Browse the repository at this point in the history
[ Upstream commit 8972e44 ]

Introduce some consistency for readability and make the names better
reflect the nature of the tests.

Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
  • Loading branch information
amboar authored and stewartsmith committed Oct 31, 2018
1 parent c7dd603 commit 5421d79
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions hw/ast-bmc/ast-io.c
Original file line number Diff line number Diff line change
Expand Up @@ -316,12 +316,12 @@ void ast_io_init(void)
ast_setup_sio_irq_polarity();
}

bool ast_is_mbox_pnor(void)
bool ast_lpc_fw_is_mbox(void)
{
return dt_find_compatible_node(dt_root, NULL, "mbox");
}

bool ast_is_ahb_lpc_pnor(void)
bool ast_lpc_fw_is_flash(void)
{
uint8_t boot_version;
uint8_t boot_flags;
Expand Down
4 changes: 2 additions & 2 deletions include/ast.h
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ void ast_ahb_writel(uint32_t val, uint32_t reg);
uint32_t ast_ahb_readl(uint32_t reg);

void ast_io_init(void);
bool ast_is_ahb_lpc_pnor(void);
bool ast_is_mbox_pnor(void);
bool ast_lpc_fw_is_flash(void);
bool ast_lpc_fw_is_mbox(void);
bool ast_scratch_reg_is_mbox(void);

/* UART configuration */
Expand Down
4 changes: 2 additions & 2 deletions platforms/astbmc/pnor.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ int pnor_init(void)
int rc;
bool do_mbox;

do_mbox = ast_is_mbox_pnor();
do_mbox = ast_lpc_fw_is_mbox();
if (do_mbox) {
rc = mbox_flash_init(&bl);
} else {
Expand All @@ -43,7 +43,7 @@ int pnor_init(void)
* FW reads & writes).
*/

if (ast_is_ahb_lpc_pnor())
if (ast_lpc_fw_is_flash())
rc = ast_sf_open(AST_SF_TYPE_PNOR, &pnor_ctrl);
else {
printf("PLAT: Memboot detected\n");
Expand Down

0 comments on commit 5421d79

Please sign in to comment.