[OE-core] [PATCH] e2fsprogs: fix the ptest
rongqing.li at windriver.com
rongqing.li at windriver.com
Tue Nov 10 04:56:57 UTC 2015
From: Roy Li <rongqing.li at windriver.com>
1. a hard-coded path in ptest is used, fix it.
2. fix the cache_inode.patch, the m_bigjournal test case show it has
a off-by-one issue
/usr/lib64/e2fsprogs/ptest/test# ./test_one m_big
m_bigjournal: journal over 4GB in size: failed
/usr/lib64/e2fsprogs/ptest/test#
/usr/lib64/e2fsprogs/ptest/test# cat m_bigjournal
m_bigjournal.1.log m_bigjournal.failed
.failed _Gaming_Socketed_GT3-1:/usr/lib64/e2fsprogs/ptest/test# cat m_bigjournal.
--- m_bigjournal/expect.1 2015-11-09 08:33:14.000000000 +0000
+++ m_bigjournal.1.log 2015-11-10 02:42:08.337571000 +0000
@@ -52,8 +52,8 @@
Reserved GDT blocks at 2-672
Block bitmap at 673 (+673), Inode bitmap at 1185 (+1185)
Inode table at 1697-1697 (+1697)
- 31836 free blocks, 5 free inodes, 2 directories, 5 unused inodes
- Free blocks: 764-1184, 1269-1696, 1781-32767
+ 31837 free blocks, 5 free inodes, 2 directories, 5 unused inodes
+ Free blocks: 763-1184, 1269-1696, 1781-32767
Free inodes: 12-16
Group 1: (Blocks 32768-65535) [INODE_UNINIT]
Backup superblock at 32768, Group descriptors at 32769-32769
@@ -542,8 +542,8 @@
Group 79: (Blocks 2588672-2621439) [INODE_UNINIT]
Block bitmap at 752 (bg #0 + 752), Inode bitmap at 1264 (bg #0 + 1264)
Inode table at 1776-1776 (bg #0 + 1776)
- 30047 free blocks, 16 free inodes, 0 directories, 16 unused inodes
- Free blocks: 2591393-2621439
+ 30046 free blocks, 16 free inodes, 0 directories, 16 unused inodes
+ Free blocks: 2591394-2621439
Free inodes: 1265-1280
Group 80: (Blocks 2621440-2654207) [INODE_UNINIT, BLOCK_UNINIT]
Block bitmap at 753 (bg #0 + 753), Inode bitmap at 1265 (bg #0 + 1265)
/usr/lib64/e2fsprogs/ptest/test#
Signed-off-by: Roy Li <rongqing.li at windriver.com>
---
meta/recipes-devtools/e2fsprogs/e2fsprogs/cache_inode.patch | 2 +-
meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.9.bb | 1 +
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs/cache_inode.patch b/meta/recipes-devtools/e2fsprogs/e2fsprogs/cache_inode.patch
index f9ef8e5..4de78e5 100644
--- a/meta/recipes-devtools/e2fsprogs/e2fsprogs/cache_inode.patch
+++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs/cache_inode.patch
@@ -37,7 +37,7 @@ Index: e2fsprogs-1.42.9/lib/ext2fs/alloc.c
int c_ratio;
+ if (!goal)
-+ goal = last_goal;
++ goal = last_goal - 1 >= 0; last_goal - 1, 0;
+
EXT2_CHECK_MAGIC(fs, EXT2_ET_MAGIC_EXT2FS_FILSYS);
diff --git a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.9.bb b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.9.bb
index ce7d2e8..a7b9816 100644
--- a/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.9.bb
+++ b/meta/recipes-devtools/e2fsprogs/e2fsprogs_1.42.9.bb
@@ -114,4 +114,5 @@ do_install_ptest() {
cp -a ${B}/tests ${D}${PTEST_PATH}/test
cp -a ${S}/tests/* ${D}${PTEST_PATH}/test
sed -e 's!../e2fsck/e2fsck!e2fsck!g' -i ${D}${PTEST_PATH}/test/*/expect*
+ sed -e 's!/usr/lib/e2fsprogs/ptest!${PTEST_PATH}!g' -i ${D}${PTEST_PATH}/test/test_*
}
--
1.9.1
More information about the Openembedded-core
mailing list