summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/genext2fs/genext2fs-1.4.1/0015-Rework-creating-the-lost-found-directory.patch
diff options
context:
space:
mode:
authorDexuan Cui <dexuan.cui@intel.com>2012-03-29 00:35:09 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-04-02 04:31:48 +0100
commit79c806cb404c2d85aeec45b40ea6adbeae9f6346 (patch)
tree5627bb72a24373b931e6a3d4190335bc904cfd88 /meta/recipes-devtools/genext2fs/genext2fs-1.4.1/0015-Rework-creating-the-lost-found-directory.patch
parent84b7541abc2d7e59c22891219fce97d320d3bb33 (diff)
downloadpoky-79c806cb404c2d85aeec45b40ea6adbeae9f6346.tar.gz
genext2fs: support large files and filesystems without using large amounts of memory
update_to_1.95.patch was generated by making a diff bewteen the 1.4.1 release and the latest 1.9.5 version in the cvs repo: http://genext2fs.cvs.sourceforge.net/viewvc/genext2fs/genext2fs/genext2fs.c?revision=1.95 The patches 0001-0019 come from mailing list of genext2fs-devel http://sourceforge.net/mailarchive/forum.php?forum_name=genext2fs-devel&max_rows=100&style=flat&viewmonth=201106 (From OE-Core rev: 8f17e499cf91191727c8767e839738cb39c21655) Signed-off-by: Dexuan Cui <dexuan.cui@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/genext2fs/genext2fs-1.4.1/0015-Rework-creating-the-lost-found-directory.patch')
-rw-r--r--meta/recipes-devtools/genext2fs/genext2fs-1.4.1/0015-Rework-creating-the-lost-found-directory.patch57
1 files changed, 57 insertions, 0 deletions
diff --git a/meta/recipes-devtools/genext2fs/genext2fs-1.4.1/0015-Rework-creating-the-lost-found-directory.patch b/meta/recipes-devtools/genext2fs/genext2fs-1.4.1/0015-Rework-creating-the-lost-found-directory.patch
new file mode 100644
index 0000000000..fbde366854
--- /dev/null
+++ b/meta/recipes-devtools/genext2fs/genext2fs-1.4.1/0015-Rework-creating-the-lost-found-directory.patch
@@ -0,0 +1,57 @@
1Upstream-Status: inappropriate
2
3From 34a2d139e3cbc9fec1b07171fd13684d4239aa6b Mon Sep 17 00:00:00 2001
4From: Corey Minyard <cminyard@mvista.com>
5Date: Mon, 6 Jun 2011 13:51:50 -0500
6Subject: [PATCH 15/19] Rework creating the lost+found directory
7
8For some reason the lost+found directory was being created with
9the size of the number of reserved blocks. I can't find any rationale
10for that, mke2fs creates it with 16 blocks. So just create it with
1116 blocks, too.
12---
13 genext2fs.c | 15 ++++++---------
14 1 files changed, 6 insertions(+), 9 deletions(-)
15
16diff --git a/genext2fs.c b/genext2fs.c
17index b466a6d..fc7fe5f 100644
18--- a/genext2fs.c
19+++ b/genext2fs.c
20@@ -2537,28 +2537,25 @@ init_fs(int nbblocks, int nbinodes, int nbresrvd, int holes,
21 inode_pos_finish(fs, &ipos);
22 put_dir(&dw);
23
24- // make lost+found directory and reserve blocks
25+ // make lost+found directory
26 if(fs->sb->s_r_blocks_count)
27 {
28 inode *node;
29 uint8 *b;
30
31- nod = mkdir_fs(fs, EXT2_ROOT_INO, "lost+found", FM_IRWXU, 0, 0, fs_timestamp, fs_timestamp);
32+ nod = mkdir_fs(fs, EXT2_ROOT_INO, "lost+found", FM_IRWXU,
33+ 0, 0, fs_timestamp, fs_timestamp);
34 b = get_workblk();
35 memset(b, 0, BLOCKSIZE);
36 ((directory*)b)->d_rec_len = BLOCKSIZE;
37- /* We run into problems with e2fsck if directory lost+found grows
38- * bigger than this. Need to find out why this happens - sundar
39- */
40- if (fs->sb->s_r_blocks_count > fs->sb->s_blocks_count * MAX_RESERVED_BLOCKS )
41- fs->sb->s_r_blocks_count = fs->sb->s_blocks_count * MAX_RESERVED_BLOCKS;
42 inode_pos_init(fs, &ipos, nod, INODE_POS_EXTEND, NULL);
43- for(i = 1; i < fs->sb->s_r_blocks_count; i++)
44+ // It is always 16 blocks to start out with
45+ for(i = 0; i < 16; i++)
46 extend_inode_blk(fs, &ipos, b, 1);
47 inode_pos_finish(fs, &ipos);
48 free_workblk(b);
49 node = get_nod(fs, nod, &ni);
50- node->i_size = fs->sb->s_r_blocks_count * BLOCKSIZE;
51+ node->i_size = 16 * BLOCKSIZE;
52 put_nod(ni);
53 }
54
55--
561.7.4.1
57