Dear all,
I am using the yaffs to implement yaffs2 supporting 16Bit,2K page
Even if reading the yaffs2 spec, I can't fully understand it.
And decided to expand yaffs1 with easeness for yaffs2.
Currently, I re-defined
yaffs_tags
__u32 chunkid;
__u32 objectid;
__u32 serialnumber
__u16 pad1;
unsigned ecc:12;
unsigned ecc2:12;
unsinged pad:8;
Total tags size is 20 bytes.
Surely SPARCE size is 64 bytes.
Yaffs_spare structure has
26byte ecc value: 2 byte blockstatus, 2 byte page stuatus, 20 byte tags.
I tried to make litte modificatoin to yaffs original source code and tested as like the followings:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1.MTD Driver -- read/write O.K tested by mtdchar, ext2 file system.
2.yaffs2
A.read : directory, file reading is ok
B.write :, when creating new files ,kernel crashed..
Craching Point
asmlinkage long sys_open --> filp_open(tmp, flags, mode)
--> fd_install(fd, f);
fd_install(unsigned int fd, struct file * file)
{
struct files_struct *files = current->files;
write_lock(&files->file_lock);
if (files->fd[fd]) BUG(); <---- I have the Problems
files->fd[fd] = file;
write_unlock(&files->file_lock);
}
linux-2.4.18-rmk7
I don't think that linux-2.4.18-rmk7 has the problems of sys_open /fd_install.
But yaffs1 works fine in linux-2.4.18-rmk7 and my yaffs2 uses exactly same code to connect between yaffs2 and VFS.(I guess..)
My test example is
Shell> cd yaffs2_dir
Shell> echo "1" > some_file
Sys_open-> filp_open .... yaffs_lookup .. a yaffs_create ( until this, I have no problems)
-->fd_install (crash. Currents->files->fd[fd] has wrong value)
Thanks in advance.
SW.LEE
"¿ì¸® ÀÎÅͳÝ, Daum" http://www.daum.net ¡ºÆò»ý¾²´Â ¹«·á ÇѸÞÀϳݡ» |
ÇÁ¸®¹Ì¾ö ¸ÞÀÏ ½áº¸¼Ì¾î¿ä? ºü¸¥ Àü¼Û,Æí¸®ÇÑ ±â´ÉÀÇ ³ª¸¸ÀÇ °íÇ°°Ý ¸ÂÃã ¸ÞÀÏ! |