diff options
author | Richard Purdie <richard@openedhand.com> | 2006-05-09 16:45:38 +0000 |
---|---|---|
committer | Richard Purdie <richard@openedhand.com> | 2006-05-09 16:45:38 +0000 |
commit | 572f07af31f16b04f83755ee4d7a245eaf38a9f9 (patch) | |
tree | bcccab93d2a61d0dbc64f71786eae23acc671f7a /openembedded/packages | |
parent | 8e898fe29b4b621df383b49b4a1df8d7d12b9a8f (diff) | |
download | poky-572f07af31f16b04f83755ee4d7a245eaf38a9f9.tar.gz |
mtd-utils: Upgrade 20050801 -> 20060223
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@380 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'openembedded/packages')
-rw-r--r-- | openembedded/packages/mtd/mtd-utils-native_20060223.bb (renamed from openembedded/packages/mtd/mtd-utils-native_20050801.bb) | 0 | ||||
-rw-r--r-- | openembedded/packages/mtd/mtd-utils/add-exclusion-to-mkfs-jffs2-20060131.patch | 100 | ||||
-rw-r--r-- | openembedded/packages/mtd/mtd-utils/fix-ignoreerrors-20060131.patch | 20 | ||||
-rw-r--r-- | openembedded/packages/mtd/mtd-utils/fix-ignoreerrors.patch | 20 | ||||
-rw-r--r-- | openembedded/packages/mtd/mtd-utils_20060223.bb (renamed from openembedded/packages/mtd/mtd-utils_20050801.bb) | 6 |
5 files changed, 143 insertions, 3 deletions
diff --git a/openembedded/packages/mtd/mtd-utils-native_20050801.bb b/openembedded/packages/mtd/mtd-utils-native_20060223.bb index cd1fb7d11b..cd1fb7d11b 100644 --- a/openembedded/packages/mtd/mtd-utils-native_20050801.bb +++ b/openembedded/packages/mtd/mtd-utils-native_20060223.bb | |||
diff --git a/openembedded/packages/mtd/mtd-utils/add-exclusion-to-mkfs-jffs2-20060131.patch b/openembedded/packages/mtd/mtd-utils/add-exclusion-to-mkfs-jffs2-20060131.patch new file mode 100644 index 0000000000..e24f395890 --- /dev/null +++ b/openembedded/packages/mtd/mtd-utils/add-exclusion-to-mkfs-jffs2-20060131.patch | |||
@@ -0,0 +1,100 @@ | |||
1 | --- mtd/util/mkfs.jffs2.c~add-exclusion-to-mkfs-jffs2.patch | ||
2 | +++ mtd/util/mkfs.jffs2.c | ||
3 | @@ -92,7 +92,12 @@ | ||
4 | struct filesystem_entry *files; /* Only relevant to directories */ | ||
5 | }; | ||
6 | |||
7 | - | ||
8 | +struct ignorepath_entry { | ||
9 | + struct ignorepath_entry* next; /* Points to the next ignorepath element */ | ||
10 | + char name[PATH_MAX]; /* Name of the entry */ | ||
11 | +}; | ||
12 | + | ||
13 | +static struct ignorepath_entry* ignorepath = 0; | ||
14 | static int out_fd = -1; | ||
15 | static int in_fd = -1; | ||
16 | static char default_rootdir[] = "."; | ||
17 | @@ -367,7 +372,7 @@ | ||
18 | char *hpath, *tpath; | ||
19 | struct dirent *dp, **namelist; | ||
20 | struct filesystem_entry *entry; | ||
21 | - | ||
22 | + struct ignorepath_entry* element = ignorepath; | ||
23 | |||
24 | if (lstat(hostpath, &sb)) { | ||
25 | perror_msg_and_die("%s", hostpath); | ||
26 | @@ -376,6 +381,15 @@ | ||
27 | entry = add_host_filesystem_entry(targetpath, hostpath, | ||
28 | sb.st_uid, sb.st_gid, sb.st_mode, 0, parent); | ||
29 | |||
30 | + while ( element ) { | ||
31 | + if ( strcmp( element->name, targetpath ) == 0 ) { | ||
32 | + printf( "Note: ignoring directories below '%s'\n", targetpath ); | ||
33 | + return entry; | ||
34 | + break; | ||
35 | + } | ||
36 | + element = element->next; | ||
37 | + } | ||
38 | + | ||
39 | n = scandir(hostpath, &namelist, 0, alphasort); | ||
40 | if (n < 0) { | ||
41 | perror_msg_and_die("opening directory %s", hostpath); | ||
42 | @@ -1157,6 +1171,7 @@ | ||
43 | {"root", 1, NULL, 'r'}, | ||
44 | {"pagesize", 1, NULL, 's'}, | ||
45 | {"eraseblock", 1, NULL, 'e'}, | ||
46 | + {"ignore", 1, NULL, 'I'}, | ||
47 | {"output", 1, NULL, 'o'}, | ||
48 | {"help", 0, NULL, 'h'}, | ||
49 | {"verbose", 0, NULL, 'v'}, | ||
50 | @@ -1199,6 +1214,7 @@ | ||
51 | " -L, --list-compressors Show the list of the avaiable compressors\n" | ||
52 | " -t, --test-compression Call decompress and compare with the original (for test)\n" | ||
53 | " -n, --no-eraseblock-headers Don't add a eraseblock header to every eraseblock\n" | ||
54 | + " -I, --ignore=PATH Ignore sub directory and file tree below PATH when recursing over the file system\n" | ||
55 | " -o, --output=FILE Output to FILE (default: stdout)\n" | ||
56 | " -l, --little-endian Create a little-endian filesystem\n" | ||
57 | " -b, --big-endian Create a big-endian filesystem\n" | ||
58 | @@ -1368,11 +1384,12 @@ | ||
59 | struct filesystem_entry *root; | ||
60 | char *compr_name = NULL; | ||
61 | int compr_prior = -1; | ||
62 | + struct ignorepath_entry* element = ignorepath; | ||
63 | |||
64 | jffs2_compressors_init(); | ||
65 | |||
66 | while ((opt = getopt_long(argc, argv, | ||
67 | - "D:d:r:s:o:qUPfh?vVe:lbp::nc:m:x:X:Lty:i:", long_options, &c)) >= 0) | ||
68 | + "D:d:r:s:I:o:qUPfh?vVe:lbp::nc:m:x:X:Lty:i:", long_options, &c)) >= 0) | ||
69 | { | ||
70 | switch (opt) { | ||
71 | case 'D': | ||
72 | @@ -1395,6 +1412,28 @@ | ||
73 | page_size = strtol(optarg, NULL, 0); | ||
74 | break; | ||
75 | |||
76 | + case 'I': | ||
77 | + printf( "Note: Adding '%s' to ignore Path\n", optarg ); | ||
78 | + element = ignorepath; | ||
79 | + if ( !ignorepath ) { | ||
80 | + ignorepath = xmalloc( sizeof( struct ignorepath_entry ) ); | ||
81 | + ignorepath->next = 0; | ||
82 | + strcpy( &ignorepath->name[0], optarg ); | ||
83 | + } else { | ||
84 | + while ( element->next ) element = element->next; | ||
85 | + element->next = xmalloc( sizeof( struct ignorepath_entry ) ); | ||
86 | + element->next->next = 0; | ||
87 | + strcpy( &element->next->name[0], optarg ); | ||
88 | + } | ||
89 | + printf( "--------- Dumping ignore path list ----------------\n" ); | ||
90 | + element = ignorepath; | ||
91 | + while ( element ) { | ||
92 | + printf( " * '%s'\n", &element->name[0] ); | ||
93 | + element = element->next; | ||
94 | + } | ||
95 | + printf( "---------------------------------------------------\n" ); | ||
96 | + break; | ||
97 | + | ||
98 | case 'o': | ||
99 | if (out_fd != -1) { | ||
100 | error_msg_and_die("output filename specified more than once"); | ||
diff --git a/openembedded/packages/mtd/mtd-utils/fix-ignoreerrors-20060131.patch b/openembedded/packages/mtd/mtd-utils/fix-ignoreerrors-20060131.patch new file mode 100644 index 0000000000..8266a37c46 --- /dev/null +++ b/openembedded/packages/mtd/mtd-utils/fix-ignoreerrors-20060131.patch | |||
@@ -0,0 +1,20 @@ | |||
1 | --- mtd/util/nanddump.c.orig 2006-01-30 21:19:22.000000000 +0100 | ||
2 | +++ mtd/util/nanddump.c 2006-01-30 21:19:24.000000000 +0100 | ||
3 | @@ -224,7 +224,7 @@ | ||
4 | } | ||
5 | } | ||
6 | |||
7 | - if (badblock) { | ||
8 | + if (badblock && !ignoreerrors) { | ||
9 | if (omitbad) | ||
10 | continue; | ||
11 | memset (readbuf, 0xff, bs); | ||
12 | @@ -259,7 +259,7 @@ | ||
13 | if (omitoob) | ||
14 | continue; | ||
15 | |||
16 | - if (badblock) { | ||
17 | + if (badblock && !ignoreerrors) { | ||
18 | memset (readbuf, 0xff, meminfo.oobsize); | ||
19 | } else { | ||
20 | /* Read OOB data and exit on failure */ | ||
diff --git a/openembedded/packages/mtd/mtd-utils/fix-ignoreerrors.patch b/openembedded/packages/mtd/mtd-utils/fix-ignoreerrors.patch new file mode 100644 index 0000000000..b1f702a316 --- /dev/null +++ b/openembedded/packages/mtd/mtd-utils/fix-ignoreerrors.patch | |||
@@ -0,0 +1,20 @@ | |||
1 | --- mtd/util/nanddump.c.orig 2005-12-30 19:07:39.000000000 +0100 | ||
2 | +++ mtd/util/nanddump.c 2005-12-30 19:08:53.000000000 +0100 | ||
3 | @@ -224,7 +224,7 @@ | ||
4 | } | ||
5 | } | ||
6 | |||
7 | - if (badblock) { | ||
8 | + if (badblock && !ignoreerrors) { | ||
9 | if (omitbad) | ||
10 | continue; | ||
11 | memset (readbuf, 0xff, bs); | ||
12 | @@ -259,7 +259,7 @@ | ||
13 | if (omitoob) | ||
14 | continue; | ||
15 | |||
16 | - if (badblock) { | ||
17 | + if (badblock && !ignoreerrors) { | ||
18 | memset (readbuf, 0xff, meminfo.oobsize); | ||
19 | } else { | ||
20 | /* Read OOB data and exit on failure */ | ||
diff --git a/openembedded/packages/mtd/mtd-utils_20050801.bb b/openembedded/packages/mtd/mtd-utils_20060223.bb index 02f1120d97..21d0f21fcd 100644 --- a/openembedded/packages/mtd/mtd-utils_20050801.bb +++ b/openembedded/packages/mtd/mtd-utils_20060223.bb | |||
@@ -7,8 +7,8 @@ PR = "r0" | |||
7 | SRCDATE = "${PV}" | 7 | SRCDATE = "${PV}" |
8 | 8 | ||
9 | SRC_URI = "cvs://anoncvs:anoncvs@cvs.infradead.org/home/cvs;module=mtd \ | 9 | SRC_URI = "cvs://anoncvs:anoncvs@cvs.infradead.org/home/cvs;module=mtd \ |
10 | file://add-exclusion-to-mkfs-jffs2.patch;patch=1 \ | 10 | file://add-exclusion-to-mkfs-jffs2-20060131.patch;patch=1 \ |
11 | file://more-verbosity.patch;patch=1" | 11 | file://fix-ignoreerrors-20060131.patch;patch=1" |
12 | S = "${WORKDIR}/mtd/" | 12 | S = "${WORKDIR}/mtd/" |
13 | 13 | ||
14 | CFLAGS_prepend = "-I${S}/include " | 14 | CFLAGS_prepend = "-I${S}/include " |
@@ -26,7 +26,7 @@ do_stage () { | |||
26 | 26 | ||
27 | mtd_utils = "ftl_format flash_erase flash_eraseall nanddump doc_loadbios \ | 27 | mtd_utils = "ftl_format flash_erase flash_eraseall nanddump doc_loadbios \ |
28 | mkfs.jffs ftl_check mkfs.jffs2 flash_lock flash_unlock flash_info mtd_debug \ | 28 | mkfs.jffs ftl_check mkfs.jffs2 flash_lock flash_unlock flash_info mtd_debug \ |
29 | flashcp nandwrite jffs2dump" | 29 | flashcp nandwrite jffs2dump sumtool" |
30 | 30 | ||
31 | do_install () { | 31 | do_install () { |
32 | install -d ${D}${bindir} | 32 | install -d ${D}${bindir} |