mtd: rename the redboot module to RedBoot
PATCH 1/1 mtd: rename the redboot module to RedBoot
parse_mtd_partitions takes a list of partition types; if the driver isn't loaded, it attempts to load it, and then it grabs the partition parser. For redboot, the module name is "redboot.ko", while the parser name is "RedBoot". Since modprobe is case-sensitive, attempting to modprobe "RedBoot" will never work. I suspect the embedded systems that make use of redboot just always manually loaded redboot prior to loading their specific nand chip drivers (or statically compiled it in).
Alternatives include renaming the parser to "redboot", changing parse_mtd_partitions to accept pairs of strings, or changing modprobe to be case-insensitive. Renaming the module seems like the easy, obvious solution. :)
--- drivers/mtd/Makefile | 2 +- drivers/mtd/RedBoot.c | 315 +++++++++++++++++++++++++++++++++++++++++++++++++ drivers/mtd/redboot.c | 315 ------------------------------------------------- 3 files changed, 316 insertions(+), 316 deletions(-) create mode 100644 drivers/mtd/RedBoot.c delete mode 100644 drivers/mtd/redboot.c
drivers/mtd/Makefile +1 -1
@@ -7,7 +7,7 @@ obj-$(CONFIG_MTD) += mtd.o mtd-y := mtdcore.o mtdsuper.o mtdconcat.o mtdpart.o mtd-$(CONFIG_MTD_OF_PARTS) += ofpart.o -obj-$(CONFIG_MTD_REDBOOT_PARTS) += redboot.o +obj-$(CONFIG_MTD_REDBOOT_PARTS) += RedBoot.o obj-$(CONFIG_MTD_CMDLINE_PARTS) += cmdlinepart.o obj-$(CONFIG_MTD_AFS_PARTS) += afs.o obj-$(CONFIG_MTD_AR7_PARTS) += ar7part.o
drivers/mtd/RedBoot.c new file +315 -0
315 lines not on this page · raw message
drivers/mtd/redboot.c deleted +0 -315
315 lines not on this page · raw message
Signature · 1 line
1.7.2.5
Quoted 13 lines · Andres Salomon
parse_mtd_partitionstakes a list of partition types; if the driver isn't loaded, it attempts to load it, and then it grabs the partition parser. For redboot, the module name is "redboot.ko", while the parser name is "RedBoot". Since modprobe is case-sensitive, attempting to modprobe "RedBoot" will never work. I suspect the embedded systems that make use of redboot just always manually loaded redboot prior to loading their specific nand chip drivers (or statically compiled it in).Alternatives include renaming the parser to "redboot", changing
parse_mtd_partitionsto accept pairs of strings, or changing modprobe to be case-insensitive. Renaming the module seems like the easy, obvious solution. :)
Quoted 8 lines
Signed-off-by Andres Salomon <[email protected]>--- drivers/mtd/Makefile | 2 +- drivers/mtd/RedBoot.c | 315 +++++++++++++++++++++++++++++++++++++++++++++++++ drivers/mtd/redboot.c | 315 ------------------------------------------------- 3 files changed, 316 insertions(+), 316 deletions(-) create mode 100644 drivers/mtd/RedBoot.c delete mode 100644 drivers/mtd/redboot.c
Could you please use MODULE_ALIAS(RedBoot) instead?
Signature · 2 lines
Best Regards, Artem Bityutskiy