X-Git-Url: https://git.kernelconcepts.de/?a=blobdiff_plain;f=common%2Fcmd_vfd.c;h=18c14d1f3bc9456eac24618b5492ef910310e022;hb=d13ffa66aff1d9aed9081986492fb74c1a61a4a9;hp=104c3105612e5917b746db523e72bdef1f769ed3;hpb=0ad4770f8eb052a84800925ea4ab342cfc10dc32;p=karo-tx-uboot.git diff --git a/common/cmd_vfd.c b/common/cmd_vfd.c index 104c310561..18c14d1f3b 100644 --- a/common/cmd_vfd.c +++ b/common/cmd_vfd.c @@ -45,14 +45,12 @@ extern int transfer_pic(unsigned char, unsigned char *, int, int); int trab_vfd (ulong bitmap); -int do_vfd (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) +int do_vfd (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) { ulong bitmap; - if (argc != 2) { - printf ("Usage:\n%s\n", cmdtp->usage); - return 1; - } + if (argc != 2) + return cmd_usage(cmdtp); if (argv[1][0] == '/') { /* select bitmap by number */ bitmap = simple_strtoul(argv[1]+1, NULL, 10); @@ -67,15 +65,14 @@ int do_vfd (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]) U_BOOT_CMD( vfd, 2, 0, do_vfd, - "vfd - load a bitmap to the VFDs on TRAB\n", + "load a bitmap to the VFDs on TRAB", "/N\n" " - load bitmap N to the VFDs (N is _decimal_ !!!)\n" "vfd ADDR\n" - " - load bitmap at address ADDR\n" + " - load bitmap at address ADDR" ); #endif -#ifdef CONFIG_VFD int trab_vfd (ulong bitmap) { uchar *addr; @@ -103,4 +100,3 @@ int trab_vfd (ulong bitmap) transfer_pic(3, addr, VFD_LOGO_HEIGHT, VFD_LOGO_WIDTH); return 0; } -#endif /* CONFIG_VFD */