diff options
Diffstat (limited to 'board/esd/meesc/meesc.c')
-rw-r--r-- | board/esd/meesc/meesc.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/board/esd/meesc/meesc.c b/board/esd/meesc/meesc.c index 93a02ab0ee..0c5900a15a 100644 --- a/board/esd/meesc/meesc.c +++ b/board/esd/meesc/meesc.c @@ -181,7 +181,7 @@ int checkboard(void) puts("Board: EtherCAN/2 Gateway"); break; } - if (getenv_f("serial#", str, sizeof(str)) > 0) { + if (env_get_f("serial#", str, sizeof(str)) > 0) { puts(", serial# "); puts(str); } @@ -198,7 +198,7 @@ void get_board_serial(struct tag_serialnr *serialnr) { char *str; - char *serial = getenv("serial#"); + char *serial = env_get("serial#"); if (serial) { str = strchr(serial, '_'); if (str && (strlen(str) >= 4)) { @@ -231,7 +231,8 @@ int misc_init_r(void) * In some cases this this needs to be set to 4. * Check the user has set environment mdiv to 4 to change the divisor. */ - if ((str = getenv("mdiv")) && (strcmp(str, "4") == 0)) { + str = env_get("mdiv"); + if (str && (strcmp(str, "4") == 0)) { writel((readl(&pmc->mckr) & ~AT91_PMC_MDIV) | AT91SAM9_PMC_MDIV_4, &pmc->mckr); at91_clock_init(CONFIG_SYS_AT91_MAIN_CLOCK); |