projects
/
yaffs2.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
f77aa1f
)
Reduce size for nor simulation testing to try force errors
author
charles
<charles>
Tue, 11 Nov 2008 01:48:47 +0000
(
01:48
+0000)
committer
charles
<charles>
Tue, 11 Nov 2008 01:48:47 +0000
(
01:48
+0000)
direct/Makefile
patch
|
blob
|
history
direct/nor_stress.c
patch
|
blob
|
history
direct/yaffs_norif1.c
patch
|
blob
|
history
direct/yaffscfg2k.c
patch
|
blob
|
history
direct/ynorsim.c
patch
|
blob
|
history
diff --git
a/direct/Makefile
b/direct/Makefile
index 9f4b6063adf71c75cf66f55620affcfa159e4175..bfd98be92606ea00c4336cda0bf454822a97e78f 100644
(file)
--- a/
direct/Makefile
+++ b/
direct/Makefile
@@
-14,14
+14,15
@@
#
# NB Warning this Makefile does not include header dependencies.
#
#
# NB Warning this Makefile does not include header dependencies.
#
-# $Id: Makefile,v 1.
19 2008-11-07 00:32:21
charles Exp $
+# $Id: Makefile,v 1.
20 2008-11-11 01:48:47
charles Exp $
#EXTRA_COMPILE_FLAGS = -DYAFFS_IGNORE_TAGS_ECC
CFLAGS = -DCONFIG_YAFFS_DIRECT -DCONFIG_YAFFS_SHORT_NAMES_IN_RAM -DCONFIG_YAFFS_YAFFS2
CFLAGS += -DCONFIG_YAFFS_PROVIDE_DEFS -DCONFIG_YAFFSFS_PROVIDE_VALUES -DNO_Y_INLINE
#EXTRA_COMPILE_FLAGS = -DYAFFS_IGNORE_TAGS_ECC
CFLAGS = -DCONFIG_YAFFS_DIRECT -DCONFIG_YAFFS_SHORT_NAMES_IN_RAM -DCONFIG_YAFFS_YAFFS2
CFLAGS += -DCONFIG_YAFFS_PROVIDE_DEFS -DCONFIG_YAFFSFS_PROVIDE_VALUES -DNO_Y_INLINE
-CFLAGS += -Wall -g $(EXTRA_COMPILE_FLAGS) -Wstrict-aliasing -fno-strict-aliasing
-CFLAGS += -O0
+CFLAGS += -Wall -g $(EXTRA_COMPILE_FLAGS) -Wstrict-aliasing
+#CFLAGS += -fno-strict-aliasing
+CFLAGS += -O3
#CFLAGS += -DVALGRIND_TEST
#CFLAGS+= -Wshadow -Wpointer-arith -Wwrite-strings -Wstrict-prototypes -Wmissing-declarations
#CFLAGS += -DVALGRIND_TEST
#CFLAGS+= -Wshadow -Wpointer-arith -Wwrite-strings -Wstrict-prototypes -Wmissing-declarations
diff --git
a/direct/nor_stress.c
b/direct/nor_stress.c
index 0eaaf1bd0f23419dcd9cedd77b92396e7c1a0c06..4ac10b1c6186f929b0e1ea9f00aca7c353d679f3 100644
(file)
--- a/
direct/nor_stress.c
+++ b/
direct/nor_stress.c
@@
-48,8
+48,8
@@
static void FatalError(void)
static void UpdateCounter(const char *name, unsigned *val, int initialise)
{
static void UpdateCounter(const char *name, unsigned *val, int initialise)
{
- int inh;
- int outh;
+ int inh
=-1
;
+ int outh
=-1
;
unsigned x[2];
int nread = 0;
int nwritten = 0;
unsigned x[2];
int nread = 0;
int nwritten = 0;
@@
-139,6
+139,9
@@
static void dump_directory_tree_worker(const char *dname,int recursive)
if((s.st_mode & S_IFMT) == S_IFDIR && recursive)
dump_directory_tree_worker(str,1);
if((s.st_mode & S_IFMT) == S_IFDIR && recursive)
dump_directory_tree_worker(str,1);
+
+ if(s.st_ino > 10000)
+ FatalError();
}
}
diff --git
a/direct/yaffs_norif1.c
b/direct/yaffs_norif1.c
index c9534ac4c6a52e2dbe5171217bb5c44dd6dfcc27..c49b6c4aca22b78faefa71362c0f1b8482b7c54f 100644
(file)
--- a/
direct/yaffs_norif1.c
+++ b/
direct/yaffs_norif1.c
@@
-35,7
+35,7
@@
*
*/
*
*/
-const char *yaffs_norif1_c_version = "$Id: yaffs_norif1.c,v 1.
1 2008-11-07 00:34
:47 charles Exp $";
+const char *yaffs_norif1_c_version = "$Id: yaffs_norif1.c,v 1.
2 2008-11-11 01:48
:47 charles Exp $";
#include "yaffs_norif1.h"
#include "yaffs_norif1.h"
@@
-58,7
+58,7
@@
const char *yaffs_norif1_c_version = "$Id: yaffs_norif1.c,v 1.1 2008-11-07 00:34
#define FORMAT_VALUE 0x1234
#define DATA_BYTES_PER_CHUNK 1024
#define FORMAT_VALUE 0x1234
#define DATA_BYTES_PER_CHUNK 1024
-#define BLOCKS_IN_DEVICE (
32
*1024/256)
+#define BLOCKS_IN_DEVICE (
8
*1024/256)
#define YNOR_PREMARKER (0xF6)
#define YNOR_PREMARKER (0xF6)
diff --git
a/direct/yaffscfg2k.c
b/direct/yaffscfg2k.c
index 0a59d9544426e4586fd3968e61d63b2c3b4dc6f0..5100e6d8f7b9ffecb7f17603dbfec5de8b0c7d1b 100644
(file)
--- a/
direct/yaffscfg2k.c
+++ b/
direct/yaffscfg2k.c
@@
-157,7
+157,7
@@
int yaffs_StartUp(void)
m18_1Dev.nChunksPerBlock =248;
m18_1Dev.nReservedBlocks = 2;
m18_1Dev.startBlock = 0; // Can use block 0
m18_1Dev.nChunksPerBlock =248;
m18_1Dev.nReservedBlocks = 2;
m18_1Dev.startBlock = 0; // Can use block 0
- m18_1Dev.endBlock =
127
; // Last block
+ m18_1Dev.endBlock =
31
; // Last block
m18_1Dev.useNANDECC = 0; // use YAFFS's ECC
m18_1Dev.nShortOpCaches = 10; // Use caches
m18_1Dev.genericDevice = (void *) 1; // Used to identify the device in fstat.
m18_1Dev.useNANDECC = 0; // use YAFFS's ECC
m18_1Dev.nShortOpCaches = 10; // Use caches
m18_1Dev.genericDevice = (void *) 1; // Used to identify the device in fstat.
diff --git
a/direct/ynorsim.c
b/direct/ynorsim.c
index 569e0ded1e9e40746de4da50ee2d551e6da2074e..3281a2f374c3b78f05ec82572d974d4f2956e246 100644
(file)
--- a/
direct/ynorsim.c
+++ b/
direct/ynorsim.c
@@
-21,12
+21,21
@@
//#define YNORSIM_BIT_CHANGES 15
#define YNORSIM_BIT_CHANGES 1
//#define YNORSIM_BIT_CHANGES 15
#define YNORSIM_BIT_CHANGES 1
+#if 0
/* Simulate 32MB of flash in 256k byte blocks.
* This stuff is x32.
*/
#define YNORSIM_BLOCK_SIZE_U32 (256*1024/4)
#define YNORSIM_DEV_SIZE_U32 (32*1024 * 1024/4)
/* Simulate 32MB of flash in 256k byte blocks.
* This stuff is x32.
*/
#define YNORSIM_BLOCK_SIZE_U32 (256*1024/4)
#define YNORSIM_DEV_SIZE_U32 (32*1024 * 1024/4)
+#else
+/* Simulate 8MB of flash in 256k byte blocks.
+ * This stuff is x32.
+ */
+
+#define YNORSIM_BLOCK_SIZE_U32 (256*1024/4)
+#define YNORSIM_DEV_SIZE_U32 (8*1024 * 1024/4)
+#endif
static __u32 word[YNORSIM_DEV_SIZE_U32];
static __u32 word[YNORSIM_DEV_SIZE_U32];
@@
-82,7
+91,7
@@
static void ynorsim_Ready(void)
return;
srand(time(NULL));
remaining_ops = 1000000000;
return;
srand(time(NULL));
remaining_ops = 1000000000;
- remaining_ops = (rand() % 10000) *
10000
;
+ remaining_ops = (rand() % 10000) *
3000 * YNORSIM_BIT_CHANGES
;
ynorsim_RestoreImage();
}
ynorsim_RestoreImage();
}