forked from Ivasoft/openwrt
kernel: mtdsplit: modify rootfs helpers to provide partition type
Our mtdsplit parsers may want to create partition with name choice based on partition file system (e.g. SquashFS vs. JFFS2). This patch allows passing extra argument pointing to variable that will be set properly. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> SVN-Revision: 48598
This commit is contained in:
@@ -122,7 +122,7 @@ static int mtdsplit_parse_tplink(struct mtd_info *master,
|
||||
return -EINVAL;
|
||||
|
||||
/* Find the rootfs after the kernel. */
|
||||
err = mtd_check_rootfs_magic(master, kernel_size);
|
||||
err = mtd_check_rootfs_magic(master, kernel_size, NULL);
|
||||
if (!err) {
|
||||
rootfs_offset = kernel_size;
|
||||
} else {
|
||||
@@ -131,7 +131,7 @@ static int mtdsplit_parse_tplink(struct mtd_info *master,
|
||||
* Start the search from an arbitrary offset.
|
||||
*/
|
||||
err = mtd_find_rootfs_from(master, TPLINK_MIN_ROOTFS_OFFS,
|
||||
master->size, &rootfs_offset);
|
||||
master->size, &rootfs_offset, NULL);
|
||||
if (err)
|
||||
return err;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user