]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - board/pn62/cmd_pn62.c
Make sure that argv[] argument pointers are not modified.
[karo-tx-uboot.git] / board / pn62 / cmd_pn62.c
index 10d0df63a8c5b8983c9db3e2718ce77420b2cd45..73294351baecd408937a2429b933629f4b03ac3c 100644 (file)
@@ -36,7 +36,7 @@ extern int do_bootm (cmd_tbl_t *, int, int, char *[]);
 /*
  * Command led: controls the various LEDs 0..11 on the PN62 card.
  */
-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[])
 {
     unsigned int number, function;
 
@@ -54,8 +54,8 @@ int do_led (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
 U_BOOT_CMD(
        led    ,        3,      1,      do_led,
        "set LED 0..11 on the PN62 board",
-       "i fun\n"
-       "    - set 'i'th LED to function 'fun'\n"
+       "i fun"
+       "    - set 'i'th LED to function 'fun'"
 );
 
 /*
@@ -64,7 +64,7 @@ U_BOOT_CMD(
 #define CMD_MOVE_WINDOW 0x1
 #define CMD_BOOT_IMAGE  0x2
 
-int do_loadpci (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
+int do_loadpci (cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
 {
     char *s;
     ulong addr = 0, count = 0;
@@ -152,23 +152,6 @@ int do_loadpci (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
        rcode = do_bootm (cmdtp, 0, 1, local_args);
     }
 
-#ifdef CONFIG_AUTOSCRIPT
-    if (load_addr) {
-       char *s;
-
-       if (((s = getenv("autoscript")) != NULL) && (strcmp(s,"yes") == 0)) {
-               printf ("Running autoscript at addr 0x%08lX", load_addr);
-
-               s = getenv ("autoscript_uname");
-               if (s)
-                       printf (":%s ...\n", s);
-               else
-                       puts (" ...\n");
-
-               rcode = autoscript (load_addr, s);
-       }
-    }
-#endif
     return rcode;
 }
 
@@ -176,7 +159,7 @@ U_BOOT_CMD(
        loadpci,        2,      1,      do_loadpci,
        "load binary file over PCI",
        "[addr]\n"
-       "    - load binary file over PCI to address 'addr'\n"
+       "    - load binary file over PCI to address 'addr'"
 );
 
 #endif