Skip to contentSkip to conversation

JFFS2 on 2.2.18

DISCUSSION Chris AtLee 2 participants 3 messages Jun 10, 2002 – Jun 13, 2002 Memory technology devices (MTD)

lore
Share & tools
lore
#0 lore raw

Hi,

I've had some success getting MTD and JFFS (v1) working on my 2.2.18 system. I've been trying over the past few weeks to get JFFS2 up and running. I've got it to the point where the kernel can read a jffs2 partition, but I really have no idea how to get writing to work. The mechanism for writing seems completely different in 2.2.x than in 2.4.x

Any pointers? Is anyone else working on this?

Cheers,
Chris

#1 lore raw
Quoted 8 lines · [email protected] said:

I've had some success getting MTD and JFFS (v1) working on my 2.2.18 system. I've been trying over the past few weeks to get JFFS2 up and running. I've got it to the point where the kernel can read a jffs2 partition, but I really have no idea how to get writing to work. The mechanism for writing seems completely different in 2.2.x than in 2.4.x

Any pointers? Is anyone else working on this?

I know of nobody else working on a 2.2 backport. Worst case, you should be able to ditch the page-based write code and call jffs2_write_file_range() from a jffs2_file_write() which you provide instead of generic_file_write(), surely?

--
dwmw2

#2 lore raw

Ok cool, I ditched the page-based write and make a jffs2_file_write using jffs2_commit_write as a template and it works!

Now I can go back and try to figure out what's going wrong with reading...The kernel seems able to read files just fine (except device files...), except every time I access a new file to read I get some warnings about page locking / unlocking:

The !PageLocked(pg) test at the top of jffs2_readpage_nolock fails and generates a warning

and

UnlockPage(pg) in jffs2_do_readpage_unlock also generates a warning

This only happens the first time I access a file. Could it have something to do with differences between generic_file_read in the 2.2 and 2.4 kernels?

Thanks,
Chris

Quoted 21 lines · David Woodhouse
Quoted 8 lines · [email protected] said:

I've had some success getting MTD and JFFS (v1) working on my 2.2.18 system. I've been trying over the past few weeks to get JFFS2 up and running. I've got it to the point where the kernel can read a jffs2 partition, but I really have no idea how to get writing to work. The mechanism for writing seems completely different in 2.2.x than in 2.4.x

Any pointers? Is anyone else working on this?

I know of nobody else working on a 2.2 backport. Worst case, you should be able to ditch the page-based write code and call jffs2_write_file_range() from a jffs2_file_write() which you provide instead of generic_file_write(), surely?

--
dwmw2