new file mode 100644
@@ -0,0 +1,25 @@
+From f3f836c78f27c7b302b4c1ae49c44109f313ad44 Mon Sep 17 00:00:00 2001
+From: Pushpal Sidhu <psidhu@gateworks.com>
+Date: Thu, 24 Sep 2015 10:28:17 -0700
+Subject: [PATCH] mtd: fix implicit declaration of 'offsetof'
+
+Signed-off-by: Pushpal Sidhu <psidhu@gateworks.com>
+---
+ src/mtd.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/src/mtd.c b/src/mtd.c
+index 2974814..986b0ae 100644
+--- a/src/mtd.c
++++ b/src/mtd.c
+@@ -26,6 +26,7 @@
+ #include <stdio.h>
+ #include <malloc.h>
+ #include <unistd.h>
++#include <stddef.h>
+ #include <stdlib.h>
+ #include <string.h>
+ #include <fcntl.h>
+--
+2.5.3
+
new file mode 100644
@@ -0,0 +1,28 @@
+From 370d73f4437c4bc3b0d1518768a593b0c44ea429 Mon Sep 17 00:00:00 2001
+From: Pushpal Sidhu <psidhu@gateworks.com>
+Date: Thu, 24 Sep 2015 10:34:29 -0700
+Subject: [PATCH] mtd: define missing type in musl
+
+Signed-off-by: Pushpal Sidhu <psidhu@gateworks.com>
+---
+ src/mtd.h | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/src/mtd.h b/src/mtd.h
+index 99d7887..db5561b 100644
+--- a/src/mtd.h
++++ b/src/mtd.h
+@@ -31,6 +31,10 @@
+ #include "BootControlBlocks.h"
+ #include "rom_nand_hamming_code_ecc.h"
+
++#ifndef loff_t
++#define loff_t off_t
++#endif
++
+ //------------------------------------------------------------------------------
+ // Re-definitions of true and false, because the standard ones aren't good
+ // enough?
+--
+2.5.3
+
Fixes https://dev.openwrt.org/ticket/20077 Signed-off-by: Pushpal Sidhu <psidhu@gateworks.com> --- ...-mtd-fix-implicit-declaration-of-offsetof.patch | 25 +++++++++++++++++++ .../004-mtd-define-missing-type-in-musl.patch | 28 ++++++++++++++++++++++ 2 files changed, 53 insertions(+) create mode 100644 package/boot/kobs-ng/patches/003-mtd-fix-implicit-declaration-of-offsetof.patch create mode 100644 package/boot/kobs-ng/patches/004-mtd-define-missing-type-in-musl.patch