eCos gc.c BUG_ON(end > JFFS2_F_I_SIZE(f))

David Woodhouse dwmw2 at
Tue Nov 9 17:22:25 EST 2004

On Tue, 2004-11-09 at 21:56 +0100, Per Hedblom wrote:
> The test that fails is BUG_ON(end > JFFS2_F_I_SIZE(f)) in the function
> jffs2_garbage_collect_dnode in gc.c.
> The problem is that the 288(=204+84) bytes latest written are not added to
> the inode->i_size yet but already available in the frag tree.
> I can add code to update the inode->i_size in the jffs2_write_inode_range
> after each successful write but I don't think this is correct to the jffs2
> architecture but it makes the code run.

In Linux, i_size gets updated by the core VFS code, before the call to
commit_write(), and hence before jffs2_write_inode_range() too.

Can we modify jffs2_fo_write() to do likewise?


More information about the linux-mtd mailing list