summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
e1491b3)
This allows mtdsplit parsers work with UBI which is very popular on
NAND flases.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
SVN-Revision: 48599
+#define UBI_EC_MAGIC 0x55424923 /* UBI# */
+
struct squashfs_super_block {
__le32 s_magic;
__le32 pad0[9];
struct squashfs_super_block {
__le32 s_magic;
__le32 pad0[9];
if (type)
*type = MTDSPLIT_PART_TYPE_JFFS2;
return 0;
if (type)
*type = MTDSPLIT_PART_TYPE_JFFS2;
return 0;
+ } else if (be32_to_cpu(magic) == UBI_EC_MAGIC) {
+ if (type)
+ *type = MTDSPLIT_PART_TYPE_UBI;
+ return 0;
MTDSPLIT_PART_TYPE_UNK = 0,
MTDSPLIT_PART_TYPE_SQUASHFS,
MTDSPLIT_PART_TYPE_JFFS2,
MTDSPLIT_PART_TYPE_UNK = 0,
MTDSPLIT_PART_TYPE_SQUASHFS,
MTDSPLIT_PART_TYPE_JFFS2,
+ MTDSPLIT_PART_TYPE_UBI,
};
#ifdef CONFIG_MTD_SPLIT
};
#ifdef CONFIG_MTD_SPLIT