]> Git Repo - J-u-boot.git/blobdiff - cmd/exit.c
Subtree merge tag 'v6.12-dts' of dts repo [1] into dts/upstream
[J-u-boot.git] / cmd / exit.c
index 923f0870fbfa0a7262e63aecf89866585d3aa799..d125ec1e31f2d80d8a5b3e288db94e988bec16ff 100644 (file)
@@ -4,16 +4,19 @@
  * Wolfgang Denk, DENX Software Engineering, [email protected].
  */
 
-#include <common.h>
 #include <command.h>
+#include <vsprintf.h>
 
 static int do_exit(struct cmd_tbl *cmdtp, int flag, int argc,
                   char *const argv[])
 {
+       int r;
+
+       r = 0;
        if (argc > 1)
-               return simple_strtoul(argv[1], NULL, 10);
+               r = simple_strtoul(argv[1], NULL, 10);
 
-       return 0;
+       return -r - 2;
 }
 
 U_BOOT_CMD(
This page took 0.022388 seconds and 4 git commands to generate.