ramips: Add support for mt7621 to lzma-loader
[openwrt/openwrt.git] / target / linux / ramips / image / lzma-loader / src / loader.c
index 1d42bfa..c73b60b 100644 (file)
@@ -21,6 +21,7 @@
 
 #include <stddef.h>
 #include <stdint.h>
+#include <sys/types.h>
 
 #include "config.h"
 #include "cache.h"
@@ -73,9 +74,10 @@ static unsigned long lzma_outsize;
 static unsigned long kernel_la;
 
 #ifdef CONFIG_KERNEL_CMDLINE
-#define kernel_argc    1
+#define kernel_argc    2
 static const char kernel_cmdline[] = CONFIG_KERNEL_CMDLINE;
 static const char *kernel_argv[] = {
+       NULL,
        kernel_cmdline,
        NULL,
 };