X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=board%2Fpcs440ep%2Fpcs440ep.c;h=5a3ec584451bbd502cdce86a69f50a3bf95e8f58;hb=711a6722f97d21404d04c7a36ccfdc6e2b442229;hp=ce1e616679f49fa77f792c61b5a072d32e702ef4;hpb=e598dfc22c8789991d165714bec53b2390fc999d;p=u-boot diff --git a/board/pcs440ep/pcs440ep.c b/board/pcs440ep/pcs440ep.c index ce1e616679..5a3ec58445 100644 --- a/board/pcs440ep/pcs440ep.c +++ b/board/pcs440ep/pcs440ep.c @@ -22,7 +22,7 @@ */ #include -#include +#include #include #include #include @@ -148,7 +148,7 @@ int board_early_init_f(void) mtdcr(EBC0_CFGDATA, reg | 0x04000000); /* Set ATC */ /*-------------------------------------------------------------------- - * GPIO's are alreay setup in cpu/ppc4xx/cpu_init.c + * GPIO's are alreay setup in arch/powerpc/cpu/ppc4xx/cpu_init.c * via define from board config file. *-------------------------------------------------------------------*/ @@ -509,12 +509,13 @@ int misc_init_r (void) int checkboard(void) { - char *s = getenv("serial#"); + char buf[64]; + int i = getenv_f("serial#", buf, sizeof(buf)); printf("Board: PCS440EP"); - if (s != NULL) { + if (i > 0) { puts(", serial# "); - puts(s); + puts(buf); } putc('\n'); @@ -567,7 +568,7 @@ void hw_watchdog_reset(void) * "led" Commando for the U-Boot shell * ************************************************************************/ -int do_led (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) +int do_led (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) { int rcode = 0, i; ulong pattern = 0; @@ -611,14 +612,13 @@ U_BOOT_CMD( * "sha1" Commando for the U-Boot shell * ************************************************************************/ -int do_sha1 (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) +int do_sha1 (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) { int rcode = -1; if (argc < 2) { - usage: - cmd_usage(cmdtp); - return 1; +usage: + return cmd_usage(cmdtp); } if (argc >= 3) {