diff options
author | Rafał Miłecki <zajec5@gmail.com> | 2014-10-07 07:35:17 +0000 |
---|---|---|
committer | Rafał Miłecki <zajec5@gmail.com> | 2014-10-07 07:35:17 +0000 |
commit | c623065eac4250abbb3c3b3472b39bd2cfbbcd3f (patch) | |
tree | af828dbdfe7ba45260d054e5bece2f554b2eea10 /target/linux/generic/patches-3.14/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch | |
parent | 2e64fe88692de20c1ce3494bcd0c6271570f3622 (diff) | |
download | master-187ad058-c623065eac4250abbb3c3b3472b39bd2cfbbcd3f.tar.gz master-187ad058-c623065eac4250abbb3c3b3472b39bd2cfbbcd3f.tar.bz2 master-187ad058-c623065eac4250abbb3c3b3472b39bd2cfbbcd3f.zip |
kernel: move old "rootfs" splitter into separated file
This will simplify removing it in the future.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@42828 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/generic/patches-3.14/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch')
-rw-r--r-- | target/linux/generic/patches-3.14/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/target/linux/generic/patches-3.14/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch b/target/linux/generic/patches-3.14/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch index 583e44ca12..242d957667 100644 --- a/target/linux/generic/patches-3.14/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch +++ b/target/linux/generic/patches-3.14/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch @@ -38,7 +38,7 @@ static inline unsigned long mtd_pad_erasesize(struct mtd_info *mtd, int offset, int len) { -@@ -714,6 +745,12 @@ static void split_uimage(struct mtd_info +@@ -673,6 +704,12 @@ static void split_uimage(struct mtd_info static void split_firmware(struct mtd_info *master, struct mtd_part *part) { @@ -51,20 +51,19 @@ if (config_enabled(CONFIG_MTD_UIMAGE_SPLIT)) split_uimage(master, part); } -@@ -731,9 +768,12 @@ static void mtd_partition_split(struct m +@@ -689,6 +726,12 @@ static void mtd_partition_split(struct m + if (rootfs_found) return; - if (!strcmp(part->mtd.name, "rootfs")) { -+ int ret; ++ if (!strcmp(part->mtd.name, "rootfs")) { ++ run_parsers_by_type(part, MTD_PARSER_TYPE_ROOTFS); + - rootfs_found = 1; - -- if (config_enabled(CONFIG_MTD_ROOTFS_SPLIT)) -+ ret = run_parsers_by_type(part, MTD_PARSER_TYPE_ROOTFS); -+ if (ret <= 0 && config_enabled(CONFIG_MTD_ROOTFS_SPLIT)) - split_rootfs_data(master, part); - } - ++ rootfs_found = 1; ++ } ++ + if (!strcmp(part->mtd.name, SPLIT_FIRMWARE_NAME) && + config_enabled(CONFIG_MTD_SPLIT_FIRMWARE)) + split_firmware(master, part); --- a/include/linux/mtd/partitions.h +++ b/include/linux/mtd/partitions.h @@ -70,6 +70,8 @@ struct mtd_part_parser_data { |