Separate mtdparts command from jffs2
Subsystems (2)
PATCH v4 1/1 Separate mtdparts command from jffs2
Currently the mtdparts commands are included in the jffs2 command support. This doesn't make sense anymore since other commands (e.g. UBI) use this infrastructure as well now. This patch separates the mtdparts commands from the jffs2 commands making it possible to only select mtdparts when no JFFS2 support is needed.
---
v4:
- Keep config_cmd_all.h sorted
- Add "mtd_" to the names of some now non-static functions
- Cleanup of "jffs2" names and comments in cmd_mtdparts.c
v3:
- Keep lists sorted (README, Makefile) as pointed out by Wolfgang
- Generated without find-copies-harder
v2:
This patch is based in the original version by Kyungmin Park with some additional changes by Jean-Christophe Plagniol-Villard. Changes are the patch description and removal of the compilation errors/warnings.
README | 1 +
board/fads/fads.h | 4 +-
common/Makefile | 1 +
common/cmd_flash.c | 18 +-
common/cmd_jffs2.c | 1731 +-------------------------------
common/{cmd_jffs2.c => cmd_mtdparts.c} | 432 +--------
common/cmd_nand.c | 10 +-
include/config_cmd_all.h | 1 +
include/configs/ADNPESC1.h | 4 +-
include/configs/Alaska8220.h | 4 +-
include/configs/BAB7xx.h | 4 +-
include/configs/BC3450.h | 2 +-
include/configs/CATcenter.h | 4 +-
include/configs/DB64360.h | 4 +-
include/configs/DB64460.h | 4 +-
include/configs/DK1C20.h | 4 +-
include/configs/DK1S10.h | 4 +-
include/configs/ELPPC.h | 4 +-
include/configs/FPS850L.h | 2 +-
include/configs/FPS860L.h | 2 +-
include/configs/LANTEC.h | 4 +-
include/configs/MHPC.h | 4 +-
include/configs/MIP405.h | 4 +-
include/configs/ML2.h | 4 +-
include/configs/MPC8266ADS.h | 4 +-
include/configs/NC650.h | 4 +-
include/configs/NETTA.h | 4 +-
include/configs/PPChameleonEVB.h | 4 +-
include/configs/R360MPI.h | 4 +-
include/configs/RBC823.h | 4 +-
include/configs/Rattler.h | 4 +-
include/configs/SIMPC8313.h | 2 +-
include/configs/SXNI855T.h | 4 +-
include/configs/TB5200.h | 2 +-
include/configs/TQM5200.h | 2 +-
include/configs/TQM823L.h | 2 +-
include/configs/TQM823M.h | 2 +-
include/configs/TQM834x.h | 2 +-
include/configs/TQM850L.h | 2 +-
include/configs/TQM850M.h | 2 +-
include/configs/TQM855L.h | 2 +-
include/configs/TQM855M.h | 2 +-
include/configs/TQM85xx.h | 4 +-
include/configs/TQM860L.h | 2 +-
include/configs/TQM860M.h | 2 +-
include/configs/TQM862L.h | 2 +-
include/configs/TQM862M.h | 2 +-
include/configs/TQM866M.h | 2 +-
include/configs/ZUMA.h | 4 +-
include/configs/apollon.h | 2 +-
include/configs/cm5200.h | 2 +-
include/configs/debris.h | 4 +-
include/configs/ep7312.h | 4 +-
include/configs/ep8260.h | 4 +-
include/configs/fx12mm.h | 2 +-
include/configs/hymod.h | 4 +-
include/configs/idmr.h | 2 +-
include/configs/impa7.h | 4 +-
include/configs/imx31_litekit.h | 2 +-
include/configs/imx31_phycore.h | 2 +-
include/configs/incaip.h | 4 +-
include/configs/innokom.h | 4 +-
include/configs/microblaze-generic.h | 2 +-
include/configs/modnet50.h | 4 +-
include/configs/motionpro.h | 2 +-
include/configs/mx1fs2.h | 4 +-
include/configs/mx31ads.h | 2 +-
include/configs/netstar.h | 2 +-
include/configs/omap2420h4.h | 4 +-
include/configs/qong.h | 2 +-
include/configs/sc3.h | 2 +-
include/configs/sc520_cdp.h | 4 +-
include/configs/sc520_spunk.h | 4 +-
include/configs/smmaco4.h | 2 +-
include/configs/trab.h | 2 +-
include/configs/v37.h | 4 +-
include/configs/vct.h | 2 +-
include/configs/virtlab2.h | 2 +-
include/configs/voiceblue.h | 2 +-
include/configs/xilinx-ppc.h | 4 +-
include/configs/xsengine.h | 4 +-
81 files changed, 164 insertions(+), 2256 deletions(-)
copy common/{cmd_jffs2.c => cmd_mtdparts.c} (82%)README +1 -0
@@ -636,6 +636,7 @@ The following options need to be configured: CONFIG_CMD_MISC Misc functions like sleep etc CONFIG_CMD_MMC * MMC memory mapped support CONFIG_CMD_MII * MII utility commands + CONFIG_CMD_MTDPARTS * MTD partition support CONFIG_CMD_NAND * NAND support CONFIG_CMD_NET bootp, tftpboot, rarpboot CONFIG_CMD_PCA953X * PCA953x I2C gpio commands
board/fads/fads.h +2 -2
@@ -241,7 +241,7 @@* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor0"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000
@@ -249,7 +249,7 @@/* mtdparts command line support */ /* Note: fake mtd_id used, no linux mtd map file */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=fads0,nor1=fads-1,nor2=fads-2,nor3=fads-3" #define MTDPARTS_DEFAULT "mtdparts=fads-0:- at 1m(user1),fads-1:-(user2),fads-2:-(user3),fads-3:-(user4)" */
common/Makefile +1 -0
@@ -110,6 +110,7 @@ COBJS-$(CONFIG_CMD_MII) += cmd_mii.o COBJS-$(CONFIG_CMD_MISC) += cmd_misc.o COBJS-$(CONFIG_CMD_MMC) += cmd_mmc.o COBJS-$(CONFIG_MP) += cmd_mp.o +COBJS-$(CONFIG_CMD_MTDPARTS) += cmd_mtdparts.o COBJS-y += cmd_nand.o COBJS-$(CONFIG_CMD_NET) += cmd_net.o COBJS-$(CONFIG_CMD_ONENAND) += cmd_onenand.o
common/cmd_flash.c +9 -9
@@ -31,12 +31,12 @@#include <dataflash.h> #endif -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_JFFS2_CMDLINE ) +#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS )#include <jffs2/jffs2.h> /* parition handling routines */ int mtdparts_init (void ); -int id_parse (const char *id,const char **ret_id,u8 *dev_type,u8 *dev_num); +int mtd_id_parse (const char *id,const char **ret_id,u8 *dev_type,u8 *dev_num);int find_dev_and_part (const char *id,struct mtd_device **dev,u8 *part_num,struct part_info **part);#endif
@@ -325,7 +325,7 @@ int do_flerase (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])flash_info_t *info;ulong bank, addr_first, addr_last;int n, sect_first, sect_last; -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_JFFS2_CMDLINE ) +#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS )struct mtd_device *dev;struct part_info *part;u8 dev_type, dev_num, pnum;
@@ -357,9 +357,9 @@ int do_flerase (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])return rcode; } -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_JFFS2_CMDLINE ) +#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS )/* erase <part-id> - erase partition */ -if ((argc ==2 ) && (id_parse (argv[1 ],NULL , &dev_type, &dev_num) ==0 )) { +if ((argc ==2 ) && (mtd_id_parse (argv[1 ],NULL , &dev_type, &dev_num) ==0 )) {mtdparts_init ();if (find_dev_and_part (argv[1 ], &dev, &pnum, &part) ==0 ) {if (dev->id->type ==MTD_DEV_TYPE_NOR ) {
@@ -470,7 +470,7 @@ int do_protect (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])#endif /* CONFIG_SYS_NO_FLASH */ ulong addr_first, addr_last;int p; -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_JFFS2_CMDLINE ) +#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS )struct mtd_device *dev;struct part_info *part;u8 dev_type, dev_num, pnum;
@@ -563,9 +563,9 @@ int do_protect (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])return rcode; } -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_JFFS2_CMDLINE ) +#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS )/* protect on/off <part-id> */ -if ((argc ==3 ) && (id_parse (argv[2 ],NULL , &dev_type, &dev_num) ==0 )) { +if ((argc ==3 ) && (mtd_id_parse (argv[2 ],NULL , &dev_type, &dev_num) ==0 )) {mtdparts_init ();if (find_dev_and_part (argv[2 ], &dev, &pnum, &part) ==0 ) {if (dev->id->type ==MTD_DEV_TYPE_NOR ) {
@@ -698,7 +698,7 @@ int flash_sect_protect (int p, ulong addr_first, ulong addr_last)/**************************************************/ -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_JFFS2_CMDLINE ) +#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS )# define TMP_ERASE "erase <part-id>\n - erase partition\n"# define TMP_PROT_ON "protect on <part-id>\n - protect partition\n"# define TMP_PROT_OFF "protect off <part-id>\n - make partition writable\n"
common/cmd_jffs2.c +6 -1725
1,789 lines not on this page · raw message
common/cmd_mtdparts.c renamed from common/cmd_jffs2.c +28 -404
638 lines not on this page · raw message
common/cmd_nand.c +5 -5
@@ -29,7 +29,7 @@#include <jffs2/jffs2.h> #include <nand.h> -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_JFFS2_CMDLINE ) +#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS )/* parition handling routines */ int mtdparts_init (void );
@@ -105,7 +105,7 @@ static int arg_off_size(int argc, char *argv[], nand_info_t *nand, ulong *off, size_t *size) { int idx = nand_curr_device; -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_JFFS2_CMDLINE ) +#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS )struct mtd_device *dev;struct part_info *part;u8 pnum;
@@ -153,7 +153,7 @@ arg_off_size(int argc, char *argv[], nand_info_t *nand, ulong *off, size_t *size *size = nand->size - *off; } -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_JFFS2_CMDLINE ) +#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS ) out:#endif printf ("device %d " , idx);
@@ -589,7 +589,7 @@ int do_nandboot(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[])char *boot_device =NULL ;int idx;ulong addr, offset =0 ; -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_JFFS2_CMDLINE ) +#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS )struct mtd_device *dev;struct part_info *part;u8 pnum;
@@ -634,7 +634,7 @@ int do_nandboot(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[]) offset =simple_strtoul (argv[3 ],NULL ,16 );break ;default : -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_JFFS2_CMDLINE ) +#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS ) usage:#endif cmd_usage (cmdtp);
include/config_cmd_all.h +1 -0
@@ -58,6 +58,7 @@#define CONFIG_CMD_MII /* MII support */ #define CONFIG_CMD_MISC /* Misc functions like sleep etc*/ #define CONFIG_CMD_MMC /* MMC support */ +#define CONFIG_CMD_MTDPARTS /* mtd parts support */ #define CONFIG_CMD_NAND /* NAND support */ #define CONFIG_CMD_NET /* bootp, tftpboot, rarpboot */ #define CONFIG_CMD_NFS /* NFS support */
include/configs/ADNPESC1.h +2 -2
@@ -673,14 +673,14 @@* */ /* No command line, one static partition */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000/* mtdparts command line support */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "" #define MTDPARTS_DEFAULT "" */
include/configs/Alaska8220.h +2 -2
@@ -320,7 +320,7 @@/* No command line, one static partition */ /* -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS #define CONFIG_JFFS2_DEV "nor0" #define CONFIG_JFFS2_PART_SIZE 0x00400000 #define CONFIG_JFFS2_PART_OFFSET 0x00000000
@@ -328,7 +328,7 @@/* mtdparts command line support */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=alaska-0" #define MTDPARTS_DEFAULT "mtdparts=alaska-0:4m(user)" */
include/configs/BAB7xx.h +2 -2
@@ -219,7 +219,7 @@* */ /* No command line, one static partition */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000
@@ -229,7 +229,7 @@* Note: fake mtd_id used, no linux mtd map file */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=bab7xx-0" #define MTDPARTS_DEFAULT "mtdparts=bab7xx-0:-(jffs2)" */
include/configs/BC3450.h +1 -1
@@ -346,7 +346,7 @@#define CONFIG_SYS_FLASH_WRITE_TOUT 500/* Flash Write Timeout (in ms) */ /* Dynamic MTD partition support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=TQM5200-0"#define MTDPARTS_DEFAULT "mtdparts=TQM5200-0:640k(firmware)," \ "1408k(kernel)," \
include/configs/CATcenter.h +2 -2
@@ -781,7 +781,7 @@* */ /* No command line, one static partition */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nand"#define CONFIG_JFFS2_PART_SIZE 0x00200000#define CONFIG_JFFS2_PART_OFFSET 0x00000000
@@ -791,7 +791,7 @@* Note: fake mtd_id used, no linux mtd map file */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nand0=catcenter" #define MTDPARTS_DEFAULT "mtdparts=catcenter:2m(nand)" */
include/configs/DB64360.h +2 -2
@@ -230,7 +230,7 @@ ip=${ipaddr}:${serverip}${bootargs_end}; bootm 0x400000;\0"* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor1"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000
@@ -242,7 +242,7 @@ ip=${ipaddr}:${serverip}${bootargs_end}; bootm 0x400000;\0"* Note: fake mtd_id's used, no linux mtd map file. */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor1=db64360-1" #define MTDPARTS_DEFAULT "mtdparts=db64360-1:-(jffs2)" */
include/configs/DB64460.h +2 -2
@@ -168,7 +168,7 @@ ip=${ipaddr}:${serverip}${bootargs_end}; bootm 0x400000;\0"* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor1"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000
@@ -180,7 +180,7 @@ ip=${ipaddr}:${serverip}${bootargs_end}; bootm 0x400000;\0"* Note: fake mtd_id's used, no linux mtd map file. */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor1=db64460-1" #define MTDPARTS_DEFAULT "mtdparts=db64460-1:-(jffs2)" */
include/configs/DK1C20.h +2 -2
@@ -539,14 +539,14 @@* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor0"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000/* mtdparts command line support */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "" #define MTDPARTS_DEFAULT "" */
include/configs/DK1S10.h +2 -2
@@ -545,14 +545,14 @@* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor0"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000/* mtdparts command line support */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "" #define MTDPARTS_DEFAULT "" */
include/configs/ELPPC.h +2 -2
@@ -196,7 +196,7 @@* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor0"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000
@@ -204,7 +204,7 @@/* mtdparts command line support */ /* Note: fake mtd_id used, no linux mtd map file */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=elppc-0,nor1=elppc-1" #define MTDPARTS_DEFAULT "mtdparts=elppc-0:-(jffs2),elppc-1:-(user)" */
include/configs/FPS850L.h +1 -1
@@ -216,7 +216,7 @@/*----------------------------------------------------------------------- * Dynamic MTD partition support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=TQM8xxL-0"#define MTDPARTS_DEFAULT "mtdparts=TQM8xxL-0:256k(u-boot)," \
include/configs/FPS860L.h +1 -1
@@ -216,7 +216,7 @@/*----------------------------------------------------------------------- * Dynamic MTD partition support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=TQM8xxL-0"#define MTDPARTS_DEFAULT "mtdparts=TQM8xxL-0:256k(u-boot)," \
include/configs/LANTEC.h +2 -2
@@ -352,14 +352,14 @@* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor0"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000/* mtdparts command line support */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "" #define MTDPARTS_DEFAULT "" */
include/configs/MHPC.h +2 -2
@@ -200,7 +200,7 @@* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor0"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000
@@ -208,7 +208,7 @@/* mtdparts command line support */ /* Note: fake mtd_id used, no linux mtd map file */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=mhpc-0" #define MTDPARTS_DEFAULT "mtdparts=mhpc-0:-(jffs2)" */
include/configs/MIP405.h +2 -2
@@ -243,7 +243,7 @@* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor0"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000
@@ -251,7 +251,7 @@/* mtdparts command line support */ /* Note: fake mtd_id used, no linux mtd map file */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=mip405-0" #define MTDPARTS_DEFAULT "mtdparts=mip405-0:-(jffs2)" */
include/configs/ML2.h +2 -2
@@ -249,7 +249,7 @@* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor0"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00080000
@@ -257,7 +257,7 @@/* mtdparts command line support */ /* Note: fake mtd_id used, no linux mtd map file */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=ml2-0" #define MTDPARTS_DEFAULT "mtdparts=ml2-0:- at 512k(jffs2)" */
include/configs/MPC8266ADS.h +2 -2
@@ -563,14 +563,14 @@* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor0"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000/* mtdparts command line support */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "" #define MTDPARTS_DEFAULT "" */
include/configs/NC650.h +2 -2
@@ -440,13 +440,13 @@*/ /* No command line, one static partition */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nand0"#define CONFIG_JFFS2_PART_SIZE 0x00400000#define CONFIG_JFFS2_PART_OFFSET 0x00000000/* mtdparts command line support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=nc650-0,nand0=nc650-nand"#define MTDPARTS_DEFAULT "mtdparts=nc650-0:1m(kernel1),1m(kernel2)," \
include/configs/NETTA.h +2 -2
@@ -702,7 +702,7 @@* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nand0"#define CONFIG_JFFS2_PART_SIZE 0x00100000#define CONFIG_JFFS2_PART_OFFSET 0x00200000
@@ -710,7 +710,7 @@/* mtdparts command line support */ /* Note: fake mtd_id used, no linux mtd map file */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nand0=netta-nand" #define MTDPARTS_DEFAULT "mtdparts=netta-nand:1m at 2m(jffs2)" */
include/configs/PPChameleonEVB.h +2 -2
@@ -804,14 +804,14 @@*/ /* No command line, one static partition */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nand0"#define CONFIG_JFFS2_PART_SIZE 0x00400000#define CONFIG_JFFS2_PART_OFFSET 0x00000000/* mtdparts command line support */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=PPChameleon-0,nand0=ppchameleonevb-nand" */
include/configs/R360MPI.h +2 -2
@@ -167,14 +167,14 @@*/ /* No command line, one static partition * use all the space starting at offset 3MB*/ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor0"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00300000/* mtdparts command line support */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=r360-0" #define MTDPARTS_DEFAULT "mtdparts=r360-0:- at 3m(user)" */
include/configs/RBC823.h +2 -2
@@ -429,7 +429,7 @@* */ /* No command line, one static partition, whole device */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor0"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00000000
@@ -437,7 +437,7 @@/* mtdparts command line support */ /* Note: fake mtd_id used, no linux mtd map file */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "" #define MTDPARTS_DEFAULT "" */
include/configs/Rattler.h +2 -2
@@ -202,7 +202,7 @@* */ /* No command line, one static partition */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS#define CONFIG_JFFS2_DEV "nor0"#define CONFIG_JFFS2_PART_SIZE 0xFFFFFFFF#define CONFIG_JFFS2_PART_OFFSET 0x00100000
@@ -210,7 +210,7 @@/* mtdparts command line support */ /* Note: fake mtd_id used, no linux mtd map file */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=rattler-0" #define MTDPARTS_DEFAULT "mtdparts=rattler-0:- at 1m(jffs2)" */
include/configs/SIMPC8313.h +1 -1
@@ -189,7 +189,7 @@#define CONFIG_JFFS2_DEV "nand0"/* mtdparts command line support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nand0=nand0"#define MTDPARTS_DEFAULT "mtdparts=nand0:2M(u-boot),6M(kernel),-(jffs2)"
include/configs/SXNI855T.h +2 -2
@@ -174,7 +174,7 @@* */ /* No command line, one static partition */ -#undef CONFIG_JFFS2_CMDLINE +#undef CONFIG_CMD_MTDPARTS/* #define CONFIG_JFFS2_DEV "nor0"
@@ -189,7 +189,7 @@/* mtdparts command line support */ /* Note: fake mtd_id used, no linux mtd map file */ /* -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=sixnet-0,nand0=sixnet-nand" #define MTDPARTS_DEFAULT "mtdparts=sixnet-0:7680k at 512k();sixnet-nand:2m(jffs2-nand)" */
include/configs/TB5200.h +1 -1
@@ -275,7 +275,7 @@(= chip selects) */ /* Dynamic MTD partition support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=TQM5200-0"#if defined(CONFIG_TQM5200_B )#define MTDPARTS_DEFAULT "mtdparts=TQM5200-0:768k(firmware)," \
include/configs/TQM5200.h +1 -1
@@ -407,7 +407,7 @@#endif /* Dynamic MTD partition support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=TQM5200-0"#ifdef CONFIG_STK52XX
include/configs/TQM823L.h +1 -1
@@ -231,7 +231,7 @@/*----------------------------------------------------------------------- * Dynamic MTD partition support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=TQM8xxL-0"#define MTDPARTS_DEFAULT "mtdparts=TQM8xxL-0:256k(u-boot)," \
include/configs/TQM823M.h +1 -1
@@ -227,7 +227,7 @@/*----------------------------------------------------------------------- * Dynamic MTD partition support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=TQM8xxM-0"#define MTDPARTS_DEFAULT "mtdparts=TQM8xxM-0:512k(u-boot)," \
include/configs/TQM834x.h +1 -1
@@ -537,7 +537,7 @@ extern int tqm834x_num_flash_banks;* JFFS2 partitions */ /* mtdparts command line support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=TQM834x-0"/* default mtd partition table */
include/configs/TQM850L.h +1 -1
@@ -216,7 +216,7 @@/*----------------------------------------------------------------------- * Dynamic MTD partition support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=TQM8xxL-0"#define MTDPARTS_DEFAULT "mtdparts=TQM8xxL-0:256k(u-boot)," \
include/configs/TQM850M.h +1 -1
@@ -216,7 +216,7 @@/*----------------------------------------------------------------------- * Dynamic MTD partition support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=TQM8xxM-0"#define MTDPARTS_DEFAULT "mtdparts=TQM8xxM-0:512k(u-boot)," \
include/configs/TQM855L.h +1 -1
@@ -221,7 +221,7 @@/*----------------------------------------------------------------------- * Dynamic MTD partition support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS #define MTDIDS_DEFAULT "nor0=TQM8xxL-0"#define MTDPARTS_DEFAULT "mtdparts=TQM8xxL-0:256k(u-boot)," \
include/configs/TQM855M.h +1 -1
@@ -256,7 +256,7 @@/*----------------------------------------------------------------------- * Dynamic MTD partition support */ -#define CONFIG_JFFS2_CMDLINE +#define CONFIG_CMD_MTDPARTS
Lines of this file are not shown. View the raw message.
The rest of this diff is not shown. View the raw message.
Signature · 1 line
1.6.2.1
Part of the diff is not shown here. View the raw message.
PATCH v4 1/1 Separate mtdparts command from jffs2
Dear Stefan Roese,
Quoted 98 lines · In message <[email protected]> you wrote:
Currently the mtdparts commands are included in the jffs2 command support. This doesn't make sense anymore since other commands (e.g. UBI) use this infrastructure as well now. This patch separates the mtdparts commands from the jffs2 commands making it possible to only select mtdparts when no JFFS2 support is needed.
Signed-off-by Stefan Roese <[email protected]>Signed-off-by Kyungmin Park <[email protected]>---
v4:
- Keepconfig_cmd_all.hsorted
- Add "mtd_" to the names of some now non-static functions
- Cleanup of "jffs2" names and comments incmd_mtdparts.cv3:
- Keep lists sorted (README,Makefile) as pointed out by Wolfgang
- Generated without find-copies-harderv2:
This patch is based in the original version by Kyungmin Park with some additional changes by Jean-Christophe Plagniol-Villard. Changes are the patch description and removal of the compilation errors/warnings.README | 1 + board/fads/fads.h | 4 +- common/Makefile | 1 + common/cmd_flash.c | 18 +- common/cmd_jffs2.c | 1731 +------------------------------- common/{cmd_jffs2.c => cmd_mtdparts.c} | 432 +-------- common/cmd_nand.c | 10 +- include/config_cmd_all.h | 1 + include/configs/ADNPESC1.h | 4 +- include/configs/Alaska8220.h | 4 +- include/configs/BAB7xx.h | 4 +- include/configs/BC3450.h | 2 +- include/configs/CATcenter.h | 4 +- include/configs/DB64360.h | 4 +- include/configs/DB64460.h | 4 +- include/configs/DK1C20.h | 4 +- include/configs/DK1S10.h | 4 +- include/configs/ELPPC.h | 4 +- include/configs/FPS850L.h | 2 +- include/configs/FPS860L.h | 2 +- include/configs/LANTEC.h | 4 +- include/configs/MHPC.h | 4 +- include/configs/MIP405.h | 4 +- include/configs/ML2.h | 4 +- include/configs/MPC8266ADS.h | 4 +- include/configs/NC650.h | 4 +- include/configs/NETTA.h | 4 +- include/configs/PPChameleonEVB.h | 4 +- include/configs/R360MPI.h | 4 +- include/configs/RBC823.h | 4 +- include/configs/Rattler.h | 4 +- include/configs/SIMPC8313.h | 2 +- include/configs/SXNI855T.h | 4 +- include/configs/TB5200.h | 2 +- include/configs/TQM5200.h | 2 +- include/configs/TQM823L.h | 2 +- include/configs/TQM823M.h | 2 +- include/configs/TQM834x.h | 2 +- include/configs/TQM850L.h | 2 +- include/configs/TQM850M.h | 2 +- include/configs/TQM855L.h | 2 +- include/configs/TQM855M.h | 2 +- include/configs/TQM85xx.h | 4 +- include/configs/TQM860L.h | 2 +- include/configs/TQM860M.h | 2 +- include/configs/TQM862L.h | 2 +- include/configs/TQM862M.h | 2 +- include/configs/TQM866M.h | 2 +- include/configs/ZUMA.h | 4 +- include/configs/apollon.h | 2 +- include/configs/cm5200.h | 2 +- include/configs/debris.h | 4 +- include/configs/ep7312.h | 4 +- include/configs/ep8260.h | 4 +- include/configs/fx12mm.h | 2 +- include/configs/hymod.h | 4 +- include/configs/idmr.h | 2 +- include/configs/impa7.h | 4 +- include/configs/imx31_litekit.h | 2 +- include/configs/imx31_phycore.h | 2 +- include/configs/incaip.h | 4 +- include/configs/innokom.h | 4 +- include/configs/microblaze-generic.h | 2 +- include/configs/modnet50.h | 4 +- include/configs/motionpro.h | 2 +- include/configs/mx1fs2.h | 4 +- include/configs/mx31ads.h | 2 +- include/configs/netstar.h | 2 +- include/configs/omap2420h4.h | 4 +- include/configs/qong.h | 2 +- include/configs/sc3.h | 2 +- include/configs/sc520_cdp.h | 4 +- include/configs/sc520_spunk.h | 4 +- include/configs/smmaco4.h | 2 +- include/configs/trab.h | 2 +-
Quoted 8 lines
include/configs/v37.h | 4 +-
include/configs/vct.h | 2 +-
include/configs/virtlab2.h | 2 +-
include/configs/voiceblue.h | 2 +-
include/configs/xilinx-ppc.h | 4 +-
include/configs/xsengine.h | 4 +-
81 files changed, 164 insertions(+), 2256 deletions(-)
copy common/{cmd_jffs2.c => cmd_mtdparts.c} (82%)Thanks. Applied to "next" branch.
Best regards,
Wolfgang Denk
Signature · 5 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de A witty saying proves nothing, but saying something pointless gets people's attention.
PATCH v4 1/1 Separate mtdparts command from jffs2
In reply to Stefan RoeseQuoted 5 lines · Stefan Roese
Currently the mtdparts commands are included in the jffs2 command support. This doesn't make sense anymore since other commands (e.g. UBI) use this infrastructure as well now. This patch separates the mtdparts commands from the jffs2 commands making it possible to only select mtdparts when no JFFS2 support is needed.
... and to make it useful for NAND chips as well, we should also remove now unrelated CONFIG_JFFS2_NAND. Note that struct part_info etc is in jffs2/load_kernel.h which is a bit misleading filename for that purpose, but that can be fixed later (tm).
common/cmd_mtdparts.c +3 -6
@@ -84,13 +84,10 @@* */ -/* -* JFFS2/CRAMFS support -*/ #include <common.h> #include <command.h> #include <malloc.h> -#include <jffs2/jffs2.h> +#include <jffs2/load_kernel.h> #include <linux/list.h> #include <linux/ctype.h> #include <cramfs/cramfs_fs.h>
@@ -375,7 +372,7 @@ static int part_validate_nor(struct mtdids *id, struct part_info *part)*/ static int part_validate_nand (struct mtdids *id,struct part_info *part) { -#if defined(CONFIG_JFFS2_NAND ) && defined(CONFIG_CMD_NAND ) +#if defined(CONFIG_CMD_NAND )/* info for NAND chips */ nand_info_t *nand;
@@ -780,7 +777,7 @@ int mtd_device_validate(u8 type, u8 num, u32 *size)printf ("support for FLASH devices not present\n" );#endif }else if (type ==MTD_DEV_TYPE_NAND ) { -#if defined(CONFIG_JFFS2_NAND ) && defined(CONFIG_CMD_NAND ) +#if defined(CONFIG_CMD_NAND )if (num <CONFIG_SYS_MAX_NAND_DEVICE ) {#ifndef CONFIG_NAND_LEGACY *size = nand_info[num].size;
Wolfgang Denk
AppliedPATCH v4 1/1 Separate mtdparts command from jffs2
Dear Ladislav Michl,
Quoted 7 lines · In message <[email protected]> you wrote:
Quoted 5 lines · Stefan Roese
Currently the mtdparts commands are included in the jffs2 command support. This doesn't make sense anymore since other commands (e.g. UBI) use this infrastructure as well now. This patch separates the mtdparts commands from the jffs2 commands making it possible to only select mtdparts when no JFFS2 support is needed.
Quoted 6 lines
... and to make it useful for NAND chips as well, we should also remove now unrelated
CONFIG_JFFS2_NAND. Note that structpart_infoetc is injffs2/load_kernel.hwhich is a bit misleading filename for that purpose, but that can be fixed later (tm).Signed-off-by Ladislav Michl <[email protected]>
Applied, thanks.
Best regards,
Wolfgang Denk
Signature · 5 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de The human race is faced with a cruel choice: work or daytime tele- vision.
PATCH v4 1/1 Separate mtdparts command from jffs2
In reply to Stefan RoeseQuoted 5 lines · Stefan Roese
Currently the mtdparts commands are included in the jffs2 command support. This doesn't make sense anymore since other commands (e.g. UBI) use this infrastructure as well now. This patch separates the mtdparts commands from the jffs2 commands making it possible to only select mtdparts when no JFFS2 support is needed.
One more leftover... Let nboot command know about partitions even if JFFS2 support is not enabled.
common/cmd_nand.c +5 -5
@@ -29,7 +29,7 @@#include <jffs2/jffs2.h> #include <nand.h> -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS ) +#if defined(CONFIG_CMD_MTDPARTS )/* parition handling routines */ int mtdparts_init (void );
@@ -105,7 +105,7 @@ static int arg_off_size(int argc, char *argv[], nand_info_t *nand, ulong *off, size_t *size) { int idx = nand_curr_device; -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS ) +#if defined(CONFIG_CMD_MTDPARTS )struct mtd_device *dev;struct part_info *part;u8 pnum;
@@ -153,7 +153,7 @@ arg_off_size(int argc, char *argv[], nand_info_t *nand, ulong *off, size_t *size *size = nand->size - *off; } -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS ) +#if defined(CONFIG_CMD_MTDPARTS ) out:#endif printf ("device %d " , idx);
@@ -598,7 +598,7 @@ int do_nandboot(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[])char *boot_device =NULL ;int idx;ulong addr, offset =0 ; -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS ) +#if defined(CONFIG_CMD_MTDPARTS )struct mtd_device *dev;struct part_info *part;u8 pnum;
@@ -643,7 +643,7 @@ int do_nandboot(cmd_tbl_t * cmdtp, int flag, int argc, char *argv[]) offset =simple_strtoul (argv[3 ],NULL ,16 );break ;default : -#if defined(CONFIG_CMD_JFFS2 ) && defined(CONFIG_CMD_MTDPARTS ) +#if defined(CONFIG_CMD_MTDPARTS ) usage:#endif cmd_usage (cmdtp);
PATCH v4 1/1 Separate mtdparts command from jffs2
Quoted 11 lines · Ladislav Michl
Quoted 5 lines · Stefan Roese
Currently the mtdparts commands are included in the jffs2 command support. This doesn't make sense anymore since other commands (e.g. UBI) use this infrastructure as well now. This patch separates the mtdparts commands from the jffs2 commands making it possible to only select mtdparts when no JFFS2 support is needed.
One more leftover... Let nboot command know about partitions even if JFFS2 support is not enabled.
Signed-off-by Ladislav Michl <[email protected]>
Thanks.
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
Wolfgang Denk
AppliedPATCH v4 1/1 Separate mtdparts command from jffs2
In reply to Ladislav MichlDear Ladislav Michl,
Quoted 11 lines · In message <[email protected]> you wrote:
Quoted 5 lines · Stefan Roese
Currently the mtdparts commands are included in the jffs2 command support. This doesn't make sense anymore since other commands (e.g. UBI) use this infrastructure as well now. This patch separates the mtdparts commands from the jffs2 commands making it possible to only select mtdparts when no JFFS2 support is needed.
One more leftover... Let nboot command know about partitions even if JFFS2 support is not enabled.
Signed-off-by Ladislav Michl <[email protected]>
Applied, thanks.
Best regards,
Wolfgang Denk
Signature · 7 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de PROGRAM - n. A magic spell cast over a computer allowing it to turn one's input into error messages. v. tr. - To engage in a pastime similar to banging one's head against a wall, but with fewer opportunities for reward.
PATCH v4 1/1 Separate mtdparts command from jffs2
In reply to Stefan RoeseDear Stefan Roese,
Quoted 8 lines · In message <[email protected]> you wrote:
Currently the mtdparts commands are included in the jffs2 command support. This doesn't make sense anymore since other commands (e.g. UBI) use this infrastructure as well now. This patch separates the mtdparts commands from the jffs2 commands making it possible to only select mtdparts when no JFFS2 support is needed.
Signed-off-by Stefan Roese <[email protected]>Signed-off-by Kyungmin Park <[email protected]>
As it turns out, that split was incomplete or incorrect.
It seems that since commit 68d7d65100 we have two different, incompatible implementations of mtdparts_init() - one in common/cmd_jffs2.c and another one in common/cmd_mtdparts.c
When NAND and JFFS2 and MTDPARTS are enabled at the same time, the mtdparts_init() from common/cmd_mtdparts.c is called, which obviously does not pereform the required intializations for JFFS2: all JFFS2 related commands just return without any error messages but also without any useful output either.
Please provide a fix!
Best regards,
Wolfgang Denk
Signature · 5 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de Q: How many DEC repairman does it take to fix a flat ? A: Five; four to hold the car up and one to swap tires.
PATCH v4 1/1 Separate mtdparts command from jffs2
Hi Wolfgang,
Quoted 15 lines · On Friday 15 May 2009 17:32:17 Wolfgang Denk wrote:
Quoted 8 lines
Currently the mtdparts commands are included in the jffs2 command support. This doesn't make sense anymore since other commands (e.g. UBI) use this infrastructure as well now. This patch separates the mtdparts commands from the jffs2 commands making it possible to only select mtdparts when no JFFS2 support is needed.
Signed-off-by Stefan Roese <[email protected]>Signed-off-by Kyungmin Park <[email protected]>As it turns out, that split was incomplete or incorrect.
It seems that since commit
68d7d65100we have two different, incompatible implementations ofmtdparts_init()- one incommon/cmd_jffs2.cand another one incommon/cmd_mtdparts.c
Quoted 5 lines
When NAND and JFFS2 and MTDPARTS are enabled at the same time, the
mtdparts_init()fromcommon/cmd_mtdparts.cis called, which obviously does not pereform the required intializations for JFFS2: all JFFS2 related commands just return without any error messages but also without any useful output either.
Sorry about this.
Quoted 1 line
Please provide a fix!
OK, I'll try to come up with a patch quickly.
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================