kernel: import pending patches adding support for NVMEM on UBI and MMC

Similar to supporting nvmem-layouts on MTD devices, also allow referencing
UBI and MMC devices in DT.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
This commit is contained in:
Daniel Golle
2023-12-04 23:48:40 +00:00
parent cff4335245
commit fc153aa8d9
22 changed files with 1876 additions and 56 deletions

View File

@@ -72,18 +72,17 @@ Subject: [PATCH] kernel: add block fit partition parser
+int parse_fit_partitions(struct parsed_partitions *state, u64 start_sector, u64 nr_sectors, int *slot, int add_remain);
--- a/block/partitions/core.c
+++ b/block/partitions/core.c
@@ -10,6 +10,10 @@
#include <linux/ctype.h>
@@ -11,6 +11,9 @@
#include <linux/vmalloc.h>
#include <linux/raid/detect.h>
#include <linux/property.h>
+#ifdef CONFIG_FIT_PARTITION
+#include <linux/root_dev.h>
+#endif
+
#include "check.h"
static int (*check_part[])(struct parsed_partitions *) = {
@@ -46,6 +50,9 @@ static int (*check_part[])(struct parsed
@@ -48,6 +51,9 @@ static int (*check_part[])(struct parsed
#ifdef CONFIG_EFI_PARTITION
efi_partition, /* this must come before msdos */
#endif
@@ -93,7 +92,7 @@ Subject: [PATCH] kernel: add block fit partition parser
#ifdef CONFIG_SGI_PARTITION
sgi_partition,
#endif
@@ -398,6 +405,11 @@ static struct block_device *add_partitio
@@ -439,6 +445,11 @@ static struct block_device *add_partitio
goto out_del;
}
@@ -105,7 +104,7 @@ Subject: [PATCH] kernel: add block fit partition parser
/* everything is up and running, commence */
err = xa_insert(&disk->part_tbl, partno, bdev, GFP_KERNEL);
if (err)
@@ -590,6 +602,11 @@ static bool blk_add_partition(struct gen
@@ -631,6 +642,11 @@ static bool blk_add_partition(struct gen
(state->parts[p].flags & ADDPART_FLAG_RAID))
md_autodetect_dev(part->bd_dev);
@@ -194,7 +193,7 @@ Subject: [PATCH] kernel: add block fit partition parser
set_capacity(gd, ((u64)new->size * tr->blksize) >> 9);
--- a/drivers/mtd/ubi/block.c
+++ b/drivers/mtd/ubi/block.c
@@ -431,7 +431,9 @@ int ubiblock_create(struct ubi_volume_in
@@ -432,7 +432,9 @@ int ubiblock_create(struct ubi_volume_in
ret = -ENODEV;
goto out_cleanup_disk;
}