diff options
author | Rafał Miłecki <zajec5@gmail.com> | 2015-12-04 09:33:08 +0000 |
---|---|---|
committer | Rafał Miłecki <zajec5@gmail.com> | 2015-12-04 09:33:08 +0000 |
commit | 4d71d66b4f1c93cbebed3b7bda7bb536332a0518 (patch) | |
tree | d236332ef1a661e214e3a791622dac01d33b4e9b /target/linux/generic/patches-4.4/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch | |
parent | cc849c9ff6b5d371d4e9eeca45fc6a28893cd79a (diff) | |
download | master-187ad058-4d71d66b4f1c93cbebed3b7bda7bb536332a0518.tar.gz master-187ad058-4d71d66b4f1c93cbebed3b7bda7bb536332a0518.tar.bz2 master-187ad058-4d71d66b4f1c93cbebed3b7bda7bb536332a0518.zip |
kernel: drop unneeded modification of mtd_add_partition function
In old days mtd_add_partition was checking for partitions overlapping
which was breaking our splitting feature. We had to modify this function
by adding an extra bool dup_check parameter. Upstream commit:
3a434f66e6da ("mtd: part: Remove partition overlap checks")
removed that check so we don't need our modification anymore.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@47748 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/generic/patches-4.4/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch')
-rw-r--r-- | target/linux/generic/patches-4.4/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/target/linux/generic/patches-4.4/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch b/target/linux/generic/patches-4.4/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch index 725dbe8b4d..2ea2056ba2 100644 --- a/target/linux/generic/patches-4.4/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch +++ b/target/linux/generic/patches-4.4/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch @@ -1,6 +1,6 @@ --- a/drivers/mtd/mtdpart.c +++ b/drivers/mtd/mtdpart.c -@@ -656,6 +656,37 @@ int mtd_del_partition(struct mtd_info *m +@@ -649,6 +649,36 @@ int mtd_del_partition(struct mtd_info *m } EXPORT_SYMBOL_GPL(mtd_del_partition); @@ -23,11 +23,10 @@ + /* adjust partition offsets */ + parts[i].offset += slave->offset; + -+ __mtd_add_partition(slave->master, -+ parts[i].name, -+ parts[i].offset, -+ parts[i].size, -+ false); ++ mtd_add_partition(slave->master, ++ parts[i].name, ++ parts[i].offset, ++ parts[i].size); + } + + kfree(parts); @@ -38,7 +37,7 @@ #ifdef CONFIG_MTD_SPLIT_FIRMWARE_NAME #define SPLIT_FIRMWARE_NAME CONFIG_MTD_SPLIT_FIRMWARE_NAME #else -@@ -664,6 +695,7 @@ EXPORT_SYMBOL_GPL(mtd_del_partition); +@@ -657,6 +687,7 @@ EXPORT_SYMBOL_GPL(mtd_del_partition); static void split_firmware(struct mtd_info *master, struct mtd_part *part) { @@ -46,7 +45,7 @@ } void __weak arch_split_mtd_part(struct mtd_info *master, const char *name, -@@ -678,6 +710,12 @@ static void mtd_partition_split(struct m +@@ -671,6 +702,12 @@ static void mtd_partition_split(struct m if (rootfs_found) return; |