[OpenWrt-Devel] [PATCH 06/29] kernel: Remove deprecated generic linux, part-probe patch

Hauke Mehrtens hauke at hauke-m.de
Sun Dec 9 10:14:28 EST 2018


This is now replaced by some other mtd partition parsing which was
merged into upstream.

Signed-off-by: Hauke Mehrtens <hauke at hauke-m.de>
---
 ...t-add-generic-parsing-of-linux-part-probe.patch | 172 ---------------------
 .../400-mtd-add-rootfs-split-support.patch         |  11 +-
 ...port-for-different-partition-parser-types.patch |   6 +-
 ...mtd-parsers-for-rootfs-and-firmware-split.patch |   4 +-
 .../404-mtd-add-more-helper-functions.patch        |   2 +-
 .../411-mtd-partial_eraseblock_write.patch         |   8 +-
 .../412-mtd-partial_eraseblock_unlock.patch        |   2 +-
 7 files changed, 16 insertions(+), 189 deletions(-)
 delete mode 100644 target/linux/generic/pending-4.19/161-mtd-part-add-generic-parsing-of-linux-part-probe.patch

diff --git a/target/linux/generic/pending-4.19/161-mtd-part-add-generic-parsing-of-linux-part-probe.patch b/target/linux/generic/pending-4.19/161-mtd-part-add-generic-parsing-of-linux-part-probe.patch
deleted file mode 100644
index 2ab3717acb..0000000000
diff --git a/target/linux/generic/pending-4.19/400-mtd-add-rootfs-split-support.patch b/target/linux/generic/pending-4.19/400-mtd-add-rootfs-split-support.patch
index c449fef041..6fdd0267c1 100644
--- a/target/linux/generic/pending-4.19/400-mtd-add-rootfs-split-support.patch
+++ b/target/linux/generic/pending-4.19/400-mtd-add-rootfs-split-support.patch
@@ -37,12 +37,11 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
  	depends on m
 --- a/drivers/mtd/mtdpart.c
 +++ b/drivers/mtd/mtdpart.c
-@@ -29,11 +29,13 @@
+@@ -29,10 +29,12 @@
  #include <linux/kmod.h>
  #include <linux/mtd/mtd.h>
  #include <linux/mtd/partitions.h>
 +#include <linux/magic.h>
- #include <linux/of.h>
  #include <linux/err.h>
  #include <linux/of.h>
  
@@ -51,7 +50,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
  
  /* Our partition linked list */
  static LIST_HEAD(mtd_partitions);
-@@ -53,6 +55,8 @@ struct mtd_part {
+@@ -52,6 +54,8 @@ struct mtd_part {
  	struct list_head list;
  };
  
@@ -60,7 +59,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
  /*
   * Given a pointer to the MTD object in the mtd_part structure, we can retrieve
   * the pointer to that structure.
-@@ -620,6 +624,7 @@ int mtd_add_partition(struct mtd_info *p
+@@ -619,6 +623,7 @@ int mtd_add_partition(struct mtd_info *p
  	mutex_unlock(&mtd_partitions_mutex);
  
  	add_mtd_device(&new->mtd);
@@ -68,7 +67,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
  
  	mtd_add_partition_attrs(new);
  
-@@ -698,6 +703,29 @@ int mtd_del_partition(struct mtd_info *m
+@@ -697,6 +702,29 @@ int mtd_del_partition(struct mtd_info *m
  }
  EXPORT_SYMBOL_GPL(mtd_del_partition);
  
@@ -98,7 +97,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
  /*
   * This function, given a master MTD object and a partition table, creates
   * and registers slave MTD objects which are bound to the master according to
-@@ -729,6 +757,7 @@ int add_mtd_partitions(struct mtd_info *
+@@ -728,6 +756,7 @@ int add_mtd_partitions(struct mtd_info *
  		mutex_unlock(&mtd_partitions_mutex);
  
  		add_mtd_device(&slave->mtd);
diff --git a/target/linux/generic/pending-4.19/401-mtd-add-support-for-different-partition-parser-types.patch b/target/linux/generic/pending-4.19/401-mtd-add-support-for-different-partition-parser-types.patch
index 287ddd27a0..d48447fb9c 100644
--- a/target/linux/generic/pending-4.19/401-mtd-add-support-for-different-partition-parser-types.patch
+++ b/target/linux/generic/pending-4.19/401-mtd-add-support-for-different-partition-parser-types.patch
@@ -9,7 +9,7 @@ Signed-off-by: Gabor Juhos <juhosg at openwrt.org>
 
 --- a/drivers/mtd/mtdpart.c
 +++ b/drivers/mtd/mtdpart.c
-@@ -56,6 +56,10 @@ struct mtd_part {
+@@ -55,6 +55,10 @@ struct mtd_part {
  };
  
  static void mtd_partition_split(struct mtd_info *master, struct mtd_part *part);
@@ -20,7 +20,7 @@ Signed-off-by: Gabor Juhos <juhosg at openwrt.org>
  
  /*
   * Given a pointer to the MTD object in the mtd_part structure, we can retrieve
-@@ -703,6 +707,36 @@ int mtd_del_partition(struct mtd_info *m
+@@ -702,6 +706,36 @@ int mtd_del_partition(struct mtd_info *m
  }
  EXPORT_SYMBOL_GPL(mtd_del_partition);
  
@@ -57,7 +57,7 @@ Signed-off-by: Gabor Juhos <juhosg at openwrt.org>
  #ifdef CONFIG_MTD_SPLIT_FIRMWARE_NAME
  #define SPLIT_FIRMWARE_NAME	CONFIG_MTD_SPLIT_FIRMWARE_NAME
  #else
-@@ -1076,6 +1110,61 @@ void mtd_part_parser_cleanup(struct mtd_
+@@ -1037,6 +1071,61 @@ void mtd_part_parser_cleanup(struct mtd_
  	}
  }
  
diff --git a/target/linux/generic/pending-4.19/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch b/target/linux/generic/pending-4.19/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch
index afe3ec7756..ca9b6c3594 100644
--- a/target/linux/generic/pending-4.19/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch
+++ b/target/linux/generic/pending-4.19/402-mtd-use-typed-mtd-parsers-for-rootfs-and-firmware-split.patch
@@ -10,7 +10,7 @@ Signed-off-by: Gabor Juhos <juhosg at openwrt.org>
 
 --- a/drivers/mtd/mtdpart.c
 +++ b/drivers/mtd/mtdpart.c
-@@ -745,6 +745,7 @@ run_parsers_by_type(struct mtd_part *sla
+@@ -744,6 +744,7 @@ run_parsers_by_type(struct mtd_part *sla
  
  static void split_firmware(struct mtd_info *master, struct mtd_part *part)
  {
@@ -18,7 +18,7 @@ Signed-off-by: Gabor Juhos <juhosg at openwrt.org>
  }
  
  static void mtd_partition_split(struct mtd_info *master, struct mtd_part *part)
-@@ -754,6 +755,12 @@ static void mtd_partition_split(struct m
+@@ -753,6 +754,12 @@ static void mtd_partition_split(struct m
  	if (rootfs_found)
  		return;
  
diff --git a/target/linux/generic/pending-4.19/404-mtd-add-more-helper-functions.patch b/target/linux/generic/pending-4.19/404-mtd-add-more-helper-functions.patch
index 0721b4802e..82c74e27a9 100644
--- a/target/linux/generic/pending-4.19/404-mtd-add-more-helper-functions.patch
+++ b/target/linux/generic/pending-4.19/404-mtd-add-more-helper-functions.patch
@@ -11,7 +11,7 @@ Signed-off-by: Gabor Juhos <juhosg at openwrt.org>
 
 --- a/drivers/mtd/mtdpart.c
 +++ b/drivers/mtd/mtdpart.c
-@@ -1189,6 +1189,24 @@ int mtd_is_partition(const struct mtd_in
+@@ -1150,6 +1150,24 @@ int mtd_is_partition(const struct mtd_in
  }
  EXPORT_SYMBOL_GPL(mtd_is_partition);
  
diff --git a/target/linux/generic/pending-4.19/411-mtd-partial_eraseblock_write.patch b/target/linux/generic/pending-4.19/411-mtd-partial_eraseblock_write.patch
index 978d6a6f7b..0b5e4005ff 100644
--- a/target/linux/generic/pending-4.19/411-mtd-partial_eraseblock_write.patch
+++ b/target/linux/generic/pending-4.19/411-mtd-partial_eraseblock_write.patch
@@ -10,7 +10,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
 
 --- a/drivers/mtd/mtdpart.c
 +++ b/drivers/mtd/mtdpart.c
-@@ -37,6 +37,8 @@
+@@ -36,6 +36,8 @@
  #include "mtdcore.h"
  #include "mtdsplit/mtdsplit.h"
  
@@ -19,7 +19,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
  /* Our partition linked list */
  static LIST_HEAD(mtd_partitions);
  static DEFINE_MUTEX(mtd_partitions_mutex);
-@@ -221,6 +223,53 @@ static int part_erase(struct mtd_info *m
+@@ -220,6 +222,53 @@ static int part_erase(struct mtd_info *m
  {
  	struct mtd_part *part = mtd_to_part(mtd);
  	int ret;
@@ -73,7 +73,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
  
  	instr->addr += part->offset;
  	ret = part->parent->_erase(part->parent, instr);
-@@ -228,6 +277,24 @@ static int part_erase(struct mtd_info *m
+@@ -227,6 +276,24 @@ static int part_erase(struct mtd_info *m
  		instr->fail_addr -= part->offset;
  	instr->addr -= part->offset;
  
@@ -98,7 +98,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
  	return ret;
  }
  
-@@ -536,19 +603,22 @@ static struct mtd_part *allocate_partiti
+@@ -535,19 +602,22 @@ static struct mtd_part *allocate_partiti
  	remainder = do_div(tmp, wr_alignment);
  	if ((slave->mtd.flags & MTD_WRITEABLE) && remainder) {
  		/* Doesn't start on a boundary of major erase size */
diff --git a/target/linux/generic/pending-4.19/412-mtd-partial_eraseblock_unlock.patch b/target/linux/generic/pending-4.19/412-mtd-partial_eraseblock_unlock.patch
index e038c4e60c..a54603a0f8 100644
--- a/target/linux/generic/pending-4.19/412-mtd-partial_eraseblock_unlock.patch
+++ b/target/linux/generic/pending-4.19/412-mtd-partial_eraseblock_unlock.patch
@@ -20,7 +20,7 @@ Signed-off-by: Tim Harvey <tharvey at gateworks.com>
 
 --- a/drivers/mtd/mtdpart.c
 +++ b/drivers/mtd/mtdpart.c
-@@ -307,7 +307,16 @@ static int part_lock(struct mtd_info *mt
+@@ -306,7 +306,16 @@ static int part_lock(struct mtd_info *mt
  static int part_unlock(struct mtd_info *mtd, loff_t ofs, uint64_t len)
  {
  	struct mtd_part *part = mtd_to_part(mtd);
-- 
2.11.0


_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel



More information about the openwrt-devel mailing list